oci 2.1.0 → 2.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +11 -3
- data/lib/oci.rb +6 -0
- data/lib/oci/api_client.rb +159 -134
- data/lib/oci/audit/audit.rb +3 -0
- data/lib/oci/audit/audit_client.rb +88 -40
- data/lib/oci/audit/audit_client_composite_operations.rb +64 -0
- data/lib/oci/audit/models/audit_event.rb +151 -200
- data/lib/oci/audit/models/configuration.rb +61 -38
- data/lib/oci/audit/models/update_configuration_details.rb +61 -38
- data/lib/oci/auth/util.rb +1 -1
- data/lib/oci/base_signer.rb +20 -29
- data/lib/oci/config.rb +9 -3
- data/lib/oci/core/blockstorage_client.rb +512 -269
- data/lib/oci/core/blockstorage_client_composite_operations.rb +342 -0
- data/lib/oci/core/compute_client.rb +959 -536
- data/lib/oci/core/compute_client_composite_operations.rb +738 -0
- data/lib/oci/core/core.rb +5 -0
- data/lib/oci/core/models/attach_boot_volume_details.rb +72 -57
- data/lib/oci/core/models/attach_i_scsi_volume_details.rb +76 -53
- data/lib/oci/core/models/attach_paravirtualized_volume_details.rb +69 -45
- data/lib/oci/core/models/attach_vnic_details.rb +79 -68
- data/lib/oci/core/models/attach_volume_details.rb +83 -74
- data/lib/oci/core/models/boot_volume.rb +119 -120
- data/lib/oci/core/models/boot_volume_attachment.rb +114 -111
- data/lib/oci/core/models/bulk_add_virtual_circuit_public_prefixes_details.rb +61 -38
- data/lib/oci/core/models/bulk_delete_virtual_circuit_public_prefixes_details.rb +61 -38
- data/lib/oci/core/models/capture_console_history_details.rb +81 -70
- data/lib/oci/core/models/connect_local_peering_gateways_details.rb +60 -38
- data/lib/oci/core/models/connect_remote_peering_connections_details.rb +67 -49
- data/lib/oci/core/models/console_history.rb +122 -123
- data/lib/oci/core/models/cpe.rb +82 -74
- data/lib/oci/core/models/create_cpe_details.rb +73 -58
- data/lib/oci/core/models/create_cross_connect_details.rb +98 -99
- data/lib/oci/core/models/create_cross_connect_group_details.rb +67 -48
- data/lib/oci/core/models/create_dhcp_details.rb +89 -84
- data/lib/oci/core/models/create_drg_attachment_details.rb +71 -56
- data/lib/oci/core/models/create_drg_details.rb +66 -47
- data/lib/oci/core/models/create_image_details.rb +108 -110
- data/lib/oci/core/models/create_instance_console_connection_details.rb +79 -69
- data/lib/oci/core/models/create_internet_gateway_details.rb +76 -65
- data/lib/oci/core/models/create_ip_sec_connection_details.rb +83 -76
- data/lib/oci/core/models/create_local_peering_gateway_details.rb +72 -57
- data/lib/oci/core/models/create_private_ip_details.rb +97 -94
- data/lib/oci/core/models/create_public_ip_details.rb +90 -77
- data/lib/oci/core/models/create_remote_peering_connection_details.rb +72 -57
- data/lib/oci/core/models/create_route_table_details.rb +90 -87
- data/lib/oci/core/models/create_security_list_details.rb +95 -96
- data/lib/oci/core/models/create_subnet_details.rb +133 -154
- data/lib/oci/core/models/create_vcn_details.rb +96 -93
- data/lib/oci/core/models/create_virtual_circuit_details.rb +136 -153
- data/lib/oci/core/models/create_virtual_circuit_public_prefix_details.rb +62 -39
- data/lib/oci/core/models/create_vnic_details.rb +99 -97
- data/lib/oci/core/models/create_volume_backup_details.rb +94 -85
- data/lib/oci/core/models/create_volume_backup_policy_assignment_details.rb +66 -47
- data/lib/oci/core/models/create_volume_details.rb +117 -130
- data/lib/oci/core/models/cross_connect.rb +120 -121
- data/lib/oci/core/models/cross_connect_group.rb +97 -82
- data/lib/oci/core/models/cross_connect_location.rb +65 -43
- data/lib/oci/core/models/cross_connect_mapping.rb +89 -81
- data/lib/oci/core/models/cross_connect_port_speed_shape.rb +68 -48
- data/lib/oci/core/models/cross_connect_status.rb +110 -87
- data/lib/oci/core/models/delete_virtual_circuit_public_prefix_details.rb +61 -38
- data/lib/oci/core/models/dhcp_dns_option.rb +85 -60
- data/lib/oci/core/models/dhcp_option.rb +62 -38
- data/lib/oci/core/models/dhcp_options.rb +119 -118
- data/lib/oci/core/models/dhcp_search_domain_option.rb +66 -44
- data/lib/oci/core/models/drg.rb +96 -81
- data/lib/oci/core/models/drg_attachment.rb +106 -99
- data/lib/oci/core/models/egress_security_rule.rb +89 -83
- data/lib/oci/core/models/export_image_details.rb +63 -41
- data/lib/oci/core/models/export_image_via_object_storage_tuple_details.rb +74 -59
- data/lib/oci/core/models/export_image_via_object_storage_uri_details.rb +65 -42
- data/lib/oci/core/models/fast_connect_provider_service.rb +155 -126
- data/lib/oci/core/models/get_public_ip_by_ip_address_details.rb +61 -39
- data/lib/oci/core/models/get_public_ip_by_private_ip_id_details.rb +61 -39
- data/lib/oci/core/models/i_scsi_volume_attachment.rb +117 -105
- data/lib/oci/core/models/icmp_options.rb +63 -41
- data/lib/oci/core/models/image.rb +170 -185
- data/lib/oci/core/models/image_source_details.rb +79 -60
- data/lib/oci/core/models/image_source_via_object_storage_tuple_details.rb +77 -62
- data/lib/oci/core/models/image_source_via_object_storage_uri_details.rb +67 -44
- data/lib/oci/core/models/ingress_security_rule.rb +89 -83
- data/lib/oci/core/models/instance.rb +190 -211
- data/lib/oci/core/models/instance_console_connection.rb +118 -117
- data/lib/oci/core/models/instance_credentials.rb +63 -41
- data/lib/oci/core/models/instance_source_details.rb +64 -41
- data/lib/oci/core/models/instance_source_via_boot_volume_details.rb +64 -41
- data/lib/oci/core/models/instance_source_via_image_details.rb +70 -51
- data/lib/oci/core/models/internet_gateway.rb +107 -100
- data/lib/oci/core/models/ip_sec_connection.rb +113 -110
- data/lib/oci/core/models/ip_sec_connection_device_config.rb +73 -59
- data/lib/oci/core/models/ip_sec_connection_device_status.rb +75 -61
- data/lib/oci/core/models/launch_instance_details.rb +163 -189
- data/lib/oci/core/models/launch_options.rb +130 -93
- data/lib/oci/core/models/letter_of_authority.rb +105 -100
- data/lib/oci/core/models/local_peering_gateway.rb +141 -140
- data/lib/oci/core/models/paravirtualized_volume_attachment.rb +83 -60
- data/lib/oci/core/models/peer_region_for_remote_peering.rb +61 -37
- data/lib/oci/core/models/port_range.rb +65 -42
- data/lib/oci/core/models/private_ip.rb +131 -151
- data/lib/oci/core/models/public_ip.rb +160 -149
- data/lib/oci/core/models/remote_peering_connection.rb +148 -151
- data/lib/oci/core/models/route_rule.rb +68 -50
- data/lib/oci/core/models/route_table.rb +120 -121
- data/lib/oci/core/models/security_list.rb +125 -130
- data/lib/oci/core/models/shape.rb +60 -36
- data/lib/oci/core/models/subnet.rb +183 -220
- data/lib/oci/core/models/tcp_options.rb +67 -49
- data/lib/oci/core/models/tunnel_config.rb +76 -62
- data/lib/oci/core/models/tunnel_status.rb +94 -77
- data/lib/oci/core/models/udp_options.rb +67 -49
- data/lib/oci/core/models/update_boot_volume_details.rb +62 -39
- data/lib/oci/core/models/update_console_history_details.rb +76 -61
- data/lib/oci/core/models/update_cpe_details.rb +62 -39
- data/lib/oci/core/models/update_cross_connect_details.rb +68 -50
- data/lib/oci/core/models/update_cross_connect_group_details.rb +62 -39
- data/lib/oci/core/models/update_dhcp_details.rb +80 -67
- data/lib/oci/core/models/update_drg_attachment_details.rb +62 -39
- data/lib/oci/core/models/update_drg_details.rb +62 -39
- data/lib/oci/core/models/update_image_details.rb +77 -62
- data/lib/oci/core/models/update_instance_details.rb +77 -62
- data/lib/oci/core/models/update_internet_gateway_details.rb +67 -48
- data/lib/oci/core/models/update_ip_sec_connection_details.rb +62 -39
- data/lib/oci/core/models/update_local_peering_gateway_details.rb +62 -39
- data/lib/oci/core/models/update_private_ip_details.rb +90 -83
- data/lib/oci/core/models/update_public_ip_details.rb +68 -49
- data/lib/oci/core/models/update_remote_peering_connection_details.rb +62 -39
- data/lib/oci/core/models/update_route_table_details.rb +81 -70
- data/lib/oci/core/models/update_security_list_details.rb +86 -79
- data/lib/oci/core/models/update_subnet_details.rb +76 -61
- data/lib/oci/core/models/update_vcn_details.rb +76 -61
- data/lib/oci/core/models/update_virtual_circuit_details.rb +114 -115
- data/lib/oci/core/models/update_vnic_details.rb +75 -60
- data/lib/oci/core/models/update_volume_backup_details.rb +76 -61
- data/lib/oci/core/models/update_volume_details.rb +76 -61
- data/lib/oci/core/models/vcn.rb +150 -167
- data/lib/oci/core/models/virtual_circuit.rb +254 -269
- data/lib/oci/core/models/virtual_circuit_bandwidth_shape.rb +68 -48
- data/lib/oci/core/models/virtual_circuit_public_prefix.rb +79 -54
- data/lib/oci/core/models/vnic.rb +149 -166
- data/lib/oci/core/models/vnic_attachment.rb +132 -141
- data/lib/oci/core/models/volume.rb +138 -151
- data/lib/oci/core/models/volume_attachment.rb +126 -131
- data/lib/oci/core/models/volume_backup.rb +185 -200
- data/lib/oci/core/models/volume_backup_policy.rb +75 -61
- data/lib/oci/core/models/volume_backup_policy_assignment.rb +75 -63
- data/lib/oci/core/models/volume_backup_schedule.rb +101 -76
- data/lib/oci/core/models/volume_source_details.rb +62 -37
- data/lib/oci/core/models/volume_source_from_volume_backup_details.rb +62 -38
- data/lib/oci/core/models/volume_source_from_volume_details.rb +62 -38
- data/lib/oci/core/virtual_network_client.rb +2683 -1457
- data/lib/oci/core/virtual_network_client_composite_operations.rb +1849 -0
- data/lib/oci/database/database.rb +3 -0
- data/lib/oci/database/database_client.rb +894 -454
- data/lib/oci/database/database_client_composite_operations.rb +462 -0
- data/lib/oci/database/models/backup.rb +131 -128
- data/lib/oci/database/models/backup_summary.rb +131 -128
- data/lib/oci/database/models/create_backup_details.rb +66 -47
- data/lib/oci/database/models/create_data_guard_association_details.rb +112 -102
- data/lib/oci/database/models/create_data_guard_association_to_existing_db_system_details.rb +73 -51
- data/lib/oci/database/models/create_database_details.rb +140 -105
- data/lib/oci/database/models/create_database_from_backup_details.rb +71 -56
- data/lib/oci/database/models/create_db_home_details.rb +70 -53
- data/lib/oci/database/models/create_db_home_with_db_system_id_base.rb +83 -67
- data/lib/oci/database/models/create_db_home_with_db_system_id_details.rb +74 -53
- data/lib/oci/database/models/create_db_home_with_db_system_id_from_backup_details.rb +69 -44
- data/lib/oci/database/models/data_guard_association.rb +205 -204
- data/lib/oci/database/models/data_guard_association_summary.rb +205 -204
- data/lib/oci/database/models/database.rb +175 -156
- data/lib/oci/database/models/database_summary.rb +175 -156
- data/lib/oci/database/models/db_backup_config.rb +60 -38
- data/lib/oci/database/models/db_home.rb +110 -107
- data/lib/oci/database/models/db_home_summary.rb +110 -107
- data/lib/oci/database/models/db_node.rb +113 -108
- data/lib/oci/database/models/db_node_summary.rb +113 -108
- data/lib/oci/database/models/db_system.rb +299 -314
- data/lib/oci/database/models/db_system_shape_summary.rb +88 -86
- data/lib/oci/database/models/db_system_summary.rb +299 -314
- data/lib/oci/database/models/db_version_summary.rb +64 -44
- data/lib/oci/database/models/failover_data_guard_association_details.rb +60 -38
- data/lib/oci/database/models/launch_db_system_details.rb +231 -234
- data/lib/oci/database/models/patch.rb +136 -113
- data/lib/oci/database/models/patch_details.rb +73 -53
- data/lib/oci/database/models/patch_history_entry.rb +114 -99
- data/lib/oci/database/models/patch_history_entry_summary.rb +114 -99
- data/lib/oci/database/models/patch_summary.rb +136 -113
- data/lib/oci/database/models/reinstate_data_guard_association_details.rb +60 -38
- data/lib/oci/database/models/restore_database_details.rb +72 -53
- data/lib/oci/database/models/switchover_data_guard_association_details.rb +60 -38
- data/lib/oci/database/models/update_database_details.rb +97 -38
- data/lib/oci/database/models/update_db_home_details.rb +60 -38
- data/lib/oci/database/models/update_db_system_details.rb +112 -64
- data/lib/oci/dns/dns.rb +3 -0
- data/lib/oci/dns/dns_client.rb +489 -302
- data/lib/oci/dns/dns_client_composite_operations.rb +143 -0
- data/lib/oci/dns/models/create_zone_details.rb +84 -72
- data/lib/oci/dns/models/external_master.rb +67 -47
- data/lib/oci/dns/models/patch_domain_records_details.rb +60 -35
- data/lib/oci/dns/models/patch_rr_set_details.rb +60 -35
- data/lib/oci/dns/models/patch_zone_records_details.rb +60 -35
- data/lib/oci/dns/models/record.rb +92 -86
- data/lib/oci/dns/models/record_collection.rb +59 -35
- data/lib/oci/dns/models/record_details.rb +92 -86
- data/lib/oci/dns/models/record_operation.rb +113 -110
- data/lib/oci/dns/models/rr_set.rb +59 -35
- data/lib/oci/dns/models/sort_order.rb +0 -2
- data/lib/oci/dns/models/tsig.rb +68 -48
- data/lib/oci/dns/models/update_domain_records_details.rb +60 -35
- data/lib/oci/dns/models/update_rr_set_details.rb +60 -35
- data/lib/oci/dns/models/update_zone_details.rb +60 -38
- data/lib/oci/dns/models/update_zone_records_details.rb +60 -35
- data/lib/oci/dns/models/zone.rb +133 -126
- data/lib/oci/dns/models/zone_summary.rb +108 -99
- data/lib/oci/email/email.rb +3 -0
- data/lib/oci/email/email_client.rb +223 -112
- data/lib/oci/email/email_client_composite_operations.rb +103 -0
- data/lib/oci/email/models/create_sender_details.rb +65 -47
- data/lib/oci/email/models/create_suppression_details.rb +66 -48
- data/lib/oci/email/models/sender.rb +97 -84
- data/lib/oci/email/models/sender_summary.rb +89 -70
- data/lib/oci/email/models/suppression.rb +90 -69
- data/lib/oci/email/models/suppression_summary.rb +90 -69
- data/lib/oci/errors.rb +16 -0
- data/lib/oci/file_storage/file_storage.rb +3 -0
- data/lib/oci/file_storage/file_storage_client.rb +587 -333
- data/lib/oci/file_storage/file_storage_client_composite_operations.rb +460 -0
- data/lib/oci/file_storage/models/create_export_details.rb +73 -56
- data/lib/oci/file_storage/models/create_file_system_details.rb +75 -60
- data/lib/oci/file_storage/models/create_mount_target_details.rb +96 -93
- data/lib/oci/file_storage/models/create_snapshot_details.rb +68 -47
- data/lib/oci/file_storage/models/export.rb +102 -89
- data/lib/oci/file_storage/models/export_set.rb +121 -122
- data/lib/oci/file_storage/models/export_set_summary.rb +109 -102
- data/lib/oci/file_storage/models/export_summary.rb +102 -89
- data/lib/oci/file_storage/models/file_system.rb +110 -103
- data/lib/oci/file_storage/models/file_system_summary.rb +110 -103
- data/lib/oci/file_storage/models/mount_target.rb +126 -131
- data/lib/oci/file_storage/models/mount_target_summary.rb +121 -122
- data/lib/oci/file_storage/models/snapshot.rb +98 -81
- data/lib/oci/file_storage/models/snapshot_summary.rb +98 -81
- data/lib/oci/file_storage/models/update_export_set_details.rb +75 -60
- data/lib/oci/file_storage/models/update_file_system_details.rb +63 -40
- data/lib/oci/file_storage/models/update_mount_target_details.rb +63 -40
- data/lib/oci/identity/identity.rb +3 -0
- data/lib/oci/identity/identity_client.rb +1671 -872
- data/lib/oci/identity/identity_client_composite_operations.rb +818 -0
- data/lib/oci/identity/models/add_user_to_group_details.rb +66 -47
- data/lib/oci/identity/models/api_key.rb +108 -101
- data/lib/oci/identity/models/availability_domain.rb +64 -44
- data/lib/oci/identity/models/compartment.rb +118 -115
- data/lib/oci/identity/models/create_api_key_details.rb +60 -35
- data/lib/oci/identity/models/create_compartment_details.rb +83 -72
- data/lib/oci/identity/models/create_customer_secret_key_details.rb +62 -39
- data/lib/oci/identity/models/create_dynamic_group_details.rb +75 -61
- data/lib/oci/identity/models/create_group_details.rb +82 -71
- data/lib/oci/identity/models/create_identity_provider_details.rb +115 -110
- data/lib/oci/identity/models/create_idp_group_mapping_details.rb +67 -48
- data/lib/oci/identity/models/create_policy_details.rb +94 -89
- data/lib/oci/identity/models/create_region_subscription_details.rb +64 -41
- data/lib/oci/identity/models/create_saml2_identity_provider_details.rb +88 -67
- data/lib/oci/identity/models/create_smtp_credential_details.rb +61 -36
- data/lib/oci/identity/models/create_swift_password_details.rb +61 -36
- data/lib/oci/identity/models/create_tag_details.rb +77 -62
- data/lib/oci/identity/models/create_tag_namespace_details.rb +82 -71
- data/lib/oci/identity/models/create_user_details.rb +82 -71
- data/lib/oci/identity/models/customer_secret_key.rb +114 -109
- data/lib/oci/identity/models/customer_secret_key_summary.rb +109 -102
- data/lib/oci/identity/models/dynamic_group.rb +112 -105
- data/lib/oci/identity/models/group.rb +118 -115
- data/lib/oci/identity/models/identity_provider.rb +135 -138
- data/lib/oci/identity/models/idp_group_mapping.rb +112 -109
- data/lib/oci/identity/models/policy.rb +129 -132
- data/lib/oci/identity/models/region.rb +67 -45
- data/lib/oci/identity/models/region_subscription.rb +90 -71
- data/lib/oci/identity/models/saml2_identity_provider.rb +106 -92
- data/lib/oci/identity/models/smtp_credential.rb +118 -113
- data/lib/oci/identity/models/smtp_credential_summary.rb +113 -106
- data/lib/oci/identity/models/swift_password.rb +113 -106
- data/lib/oci/identity/models/tag.rb +108 -116
- data/lib/oci/identity/models/tag_namespace.rb +97 -97
- data/lib/oci/identity/models/tag_namespace_summary.rb +97 -97
- data/lib/oci/identity/models/tag_summary.rb +97 -97
- data/lib/oci/identity/models/tenancy.rb +86 -78
- data/lib/oci/identity/models/ui_password.rb +97 -82
- data/lib/oci/identity/models/update_compartment_details.rb +77 -62
- data/lib/oci/identity/models/update_customer_secret_key_details.rb +61 -38
- data/lib/oci/identity/models/update_dynamic_group_details.rb +65 -45
- data/lib/oci/identity/models/update_group_details.rb +72 -55
- data/lib/oci/identity/models/update_identity_provider_details.rb +89 -74
- data/lib/oci/identity/models/update_idp_group_mapping_details.rb +66 -47
- data/lib/oci/identity/models/update_policy_details.rb +83 -72
- data/lib/oci/identity/models/update_saml2_identity_provider_details.rb +79 -58
- data/lib/oci/identity/models/update_smtp_credential_details.rb +60 -35
- data/lib/oci/identity/models/update_state_details.rb +61 -36
- data/lib/oci/identity/models/update_swift_password_details.rb +60 -35
- data/lib/oci/identity/models/update_tag_details.rb +78 -65
- data/lib/oci/identity/models/update_tag_namespace_details.rb +78 -65
- data/lib/oci/identity/models/update_user_details.rb +72 -55
- data/lib/oci/identity/models/user.rb +120 -117
- data/lib/oci/identity/models/user_group_membership.rb +107 -100
- data/lib/oci/load_balancer/load_balancer.rb +3 -0
- data/lib/oci/load_balancer/load_balancer_client.rb +918 -500
- data/lib/oci/load_balancer/load_balancer_client_composite_operations.rb +795 -0
- data/lib/oci/load_balancer/models/backend.rb +101 -94
- data/lib/oci/load_balancer/models/backend_details.rb +95 -86
- data/lib/oci/load_balancer/models/backend_health.rb +84 -57
- data/lib/oci/load_balancer/models/backend_set.rb +87 -79
- data/lib/oci/load_balancer/models/backend_set_details.rb +80 -70
- data/lib/oci/load_balancer/models/backend_set_health.rb +106 -91
- data/lib/oci/load_balancer/models/certificate.rb +78 -64
- data/lib/oci/load_balancer/models/certificate_details.rb +92 -84
- data/lib/oci/load_balancer/models/connection_configuration.rb +73 -51
- data/lib/oci/load_balancer/models/create_backend_details.rb +95 -86
- data/lib/oci/load_balancer/models/create_backend_set_details.rb +87 -79
- data/lib/oci/load_balancer/models/create_certificate_details.rb +92 -84
- data/lib/oci/load_balancer/models/create_listener_details.rb +97 -93
- data/lib/oci/load_balancer/models/create_load_balancer_details.rb +109 -117
- data/lib/oci/load_balancer/models/create_path_route_set_details.rb +66 -46
- data/lib/oci/load_balancer/models/health_check_result.rb +98 -79
- data/lib/oci/load_balancer/models/health_checker.rb +108 -108
- data/lib/oci/load_balancer/models/health_checker_details.rb +108 -108
- data/lib/oci/load_balancer/models/ip_address.rb +70 -52
- data/lib/oci/load_balancer/models/listener.rb +97 -93
- data/lib/oci/load_balancer/models/listener_details.rb +91 -85
- data/lib/oci/load_balancer/models/load_balancer.rb +144 -157
- data/lib/oci/load_balancer/models/load_balancer_health.rb +110 -95
- data/lib/oci/load_balancer/models/load_balancer_health_summary.rb +88 -61
- data/lib/oci/load_balancer/models/load_balancer_policy.rb +59 -35
- data/lib/oci/load_balancer/models/load_balancer_protocol.rb +59 -35
- data/lib/oci/load_balancer/models/load_balancer_shape.rb +59 -35
- data/lib/oci/load_balancer/models/path_match_type.rb +80 -51
- data/lib/oci/load_balancer/models/path_route.rb +76 -60
- data/lib/oci/load_balancer/models/path_route_set.rb +66 -46
- data/lib/oci/load_balancer/models/path_route_set_details.rb +60 -38
- data/lib/oci/load_balancer/models/session_persistence_configuration_details.rb +71 -55
- data/lib/oci/load_balancer/models/ssl_configuration.rb +78 -66
- data/lib/oci/load_balancer/models/ssl_configuration_details.rb +78 -66
- data/lib/oci/load_balancer/models/update_backend_details.rb +82 -67
- data/lib/oci/load_balancer/models/update_backend_set_details.rb +80 -70
- data/lib/oci/load_balancer/models/update_health_checker_details.rb +108 -108
- data/lib/oci/load_balancer/models/update_listener_details.rb +91 -85
- data/lib/oci/load_balancer/models/update_load_balancer_details.rb +62 -40
- data/lib/oci/load_balancer/models/update_path_route_set_details.rb +60 -38
- data/lib/oci/load_balancer/models/work_request.rb +115 -108
- data/lib/oci/load_balancer/models/work_request_error.rb +76 -49
- data/lib/oci/object_storage/models/bucket.rb +136 -133
- data/lib/oci/object_storage/models/bucket_summary.rb +95 -95
- data/lib/oci/object_storage/models/commit_multipart_upload_details.rb +66 -48
- data/lib/oci/object_storage/models/commit_multipart_upload_part_details.rb +64 -44
- data/lib/oci/object_storage/models/create_bucket_details.rb +113 -111
- data/lib/oci/object_storage/models/create_multipart_upload_details.rb +80 -70
- data/lib/oci/object_storage/models/create_preauthenticated_request_details.rb +87 -74
- data/lib/oci/object_storage/models/list_objects.rb +71 -53
- data/lib/oci/object_storage/models/multipart_upload.rb +77 -65
- data/lib/oci/object_storage/models/multipart_upload_part_summary.rb +72 -56
- data/lib/oci/object_storage/models/namespace_metadata.rb +69 -53
- data/lib/oci/object_storage/models/object_summary.rb +73 -57
- data/lib/oci/object_storage/models/preauthenticated_request.rb +105 -96
- data/lib/oci/object_storage/models/preauthenticated_request_summary.rb +99 -86
- data/lib/oci/object_storage/models/rename_object_details.rb +80 -74
- data/lib/oci/object_storage/models/restore_objects_details.rb +66 -45
- data/lib/oci/object_storage/models/update_bucket_details.rb +101 -97
- data/lib/oci/object_storage/models/update_namespace_metadata_details.rb +65 -47
- data/lib/oci/object_storage/object_storage.rb +2 -0
- data/lib/oci/object_storage/object_storage_client.rb +737 -435
- data/lib/oci/object_storage/object_storage_client_composite_operations.rb +24 -0
- data/lib/oci/signer.rb +20 -7
- data/lib/oci/version.rb +1 -1
- metadata +13 -2
data/lib/oci/audit/audit.rb
CHANGED
@@ -2,6 +2,8 @@
|
|
2
2
|
|
3
3
|
module OCI
|
4
4
|
module Audit
|
5
|
+
# Module containing models for requests made to, and responses received from,
|
6
|
+
# OCI Audit services
|
5
7
|
module Models
|
6
8
|
end
|
7
9
|
end
|
@@ -14,6 +16,7 @@ require 'oci/audit/models/update_configuration_details'
|
|
14
16
|
|
15
17
|
# Require generated clients
|
16
18
|
require 'oci/audit/audit_client'
|
19
|
+
require 'oci/audit/audit_client_composite_operations'
|
17
20
|
|
18
21
|
# Require service utilities
|
19
22
|
require 'oci/audit/util'
|
@@ -1,12 +1,12 @@
|
|
1
1
|
# Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
|
2
2
|
|
3
|
-
require
|
4
|
-
require
|
3
|
+
require 'uri'
|
4
|
+
require 'logger'
|
5
5
|
|
6
|
+
# rubocop:disable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
6
7
|
module OCI
|
7
|
-
|
8
|
+
# API for the Audit Service. You can use this API for queries, but not bulk-export operations.
|
8
9
|
class Audit::AuditClient
|
9
|
-
|
10
10
|
# Client used to make HTTP requests.
|
11
11
|
# @return [OCI::ApiClient]
|
12
12
|
attr_reader :api_client
|
@@ -17,7 +17,10 @@ module OCI
|
|
17
17
|
|
18
18
|
# The region, which will usually correspond to a value in {OCI::Regions::REGION_ENUM}.
|
19
19
|
# @return [String]
|
20
|
-
|
20
|
+
attr_reader :region
|
21
|
+
|
22
|
+
# rubocop:disable Metrics/AbcSize, Metrics/CyclomaticComplexity, Layout/EmptyLines
|
23
|
+
|
21
24
|
|
22
25
|
# Creates a new AuditClient.
|
23
26
|
# If a config is not specified, then the global OCI.config will be used.
|
@@ -46,15 +49,23 @@ module OCI
|
|
46
49
|
config.validate unless signer.is_a?(OCI::Auth::Signers::InstancePrincipalsSecurityTokenSigner)
|
47
50
|
|
48
51
|
if signer.nil?
|
49
|
-
signer = Signer.new(
|
52
|
+
signer = OCI::Signer.new(
|
53
|
+
config.user,
|
54
|
+
config.fingerprint,
|
55
|
+
config.tenancy,
|
56
|
+
config.key_file,
|
57
|
+
pass_phrase: config.pass_phrase,
|
58
|
+
private_key_content: config.key_content
|
59
|
+
)
|
50
60
|
end
|
51
61
|
|
52
|
-
@api_client = ApiClient.new(config, signer, proxy_settings: proxy_settings)
|
62
|
+
@api_client = OCI::ApiClient.new(config, signer, proxy_settings: proxy_settings)
|
53
63
|
|
54
64
|
region ||= config.region
|
55
65
|
region ||= signer.region if signer.respond_to?(:region)
|
56
66
|
self.region = region
|
57
67
|
end
|
68
|
+
# rubocop:enable Metrics/AbcSize, Metrics/CyclomaticComplexity, Layout/EmptyLines
|
58
69
|
|
59
70
|
# Set the region that will be used to determine the service endpoint.
|
60
71
|
# This will usually correspond to a value in {OCI::Regions::REGION_ENUM},
|
@@ -73,21 +84,27 @@ module OCI
|
|
73
84
|
@api_client.config.logger
|
74
85
|
end
|
75
86
|
|
87
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
88
|
+
# rubocop:disable Style/IfUnlessModifier, Metrics/ParameterLists
|
89
|
+
# rubocop:disable Metrics/MethodLength, Layout/EmptyLines
|
90
|
+
# rubocop:disable Lint/UnusedMethodArgument
|
91
|
+
|
76
92
|
|
77
93
|
# Get the configuration
|
78
94
|
# @param [String] compartment_id ID of the root compartment (tenancy)
|
79
95
|
# @param [Hash] opts the optional parameters
|
80
|
-
# @return [Response] A Response object with data of type OCI::Audit::Models::Configuration
|
96
|
+
# @return [Response] A Response object with data of type {OCI::Audit::Models::Configuration Configuration}
|
81
97
|
def get_configuration(compartment_id, opts = {})
|
82
|
-
logger.debug
|
98
|
+
logger.debug 'Calling operation AuditClient#get_configuration.' if logger
|
83
99
|
|
84
100
|
raise "Missing the required parameter 'compartment_id' when calling get_configuration." if compartment_id.nil?
|
85
101
|
|
86
|
-
path =
|
102
|
+
path = '/configuration'
|
103
|
+
operation_signing_strategy = :standard
|
87
104
|
|
88
105
|
# Query Params
|
89
106
|
query_params = {}
|
90
|
-
query_params[:
|
107
|
+
query_params[:compartmentId] = compartment_id
|
91
108
|
|
92
109
|
# Header Params
|
93
110
|
header_params = {}
|
@@ -96,82 +113,106 @@ module OCI
|
|
96
113
|
|
97
114
|
post_body = nil
|
98
115
|
|
99
|
-
|
116
|
+
@api_client.call_api(
|
100
117
|
:GET,
|
101
118
|
path,
|
102
119
|
endpoint,
|
103
|
-
:
|
104
|
-
:
|
105
|
-
:
|
106
|
-
:
|
120
|
+
header_params: header_params,
|
121
|
+
query_params: query_params,
|
122
|
+
operation_signing_strategy: operation_signing_strategy,
|
123
|
+
body: post_body,
|
124
|
+
return_type: 'OCI::Audit::Models::Configuration'
|
125
|
+
)
|
107
126
|
end
|
127
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
128
|
+
# rubocop:enable Style/IfUnlessModifier, Metrics/ParameterLists
|
129
|
+
# rubocop:enable Metrics/MethodLength, Layout/EmptyLines
|
130
|
+
# rubocop:enable Lint/UnusedMethodArgument
|
131
|
+
|
132
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
133
|
+
# rubocop:disable Style/IfUnlessModifier, Metrics/ParameterLists
|
134
|
+
# rubocop:disable Metrics/MethodLength, Layout/EmptyLines
|
135
|
+
|
108
136
|
|
109
137
|
# Returns all audit events for the specified compartment that were processed within the specified time range.
|
110
138
|
# @param [String] compartment_id The OCID of the compartment.
|
111
139
|
# @param [DateTime] start_time Returns events that were processed at or after this start date and time, expressed in [RFC 3339](https://tools.ietf.org/html/rfc3339) timestamp format.
|
112
140
|
# For example, a start value of `2017-01-15T11:30:00Z` will retrieve a list of all events processed since 30 minutes after the 11th hour of January 15, 2017, in Coordinated Universal Time (UTC).
|
113
141
|
# You can specify a value with granularity to the minute. Seconds (and milliseconds, if included) must be set to `0`.
|
114
|
-
#
|
142
|
+
#
|
115
143
|
# @param [DateTime] end_time Returns events that were processed before this end date and time, expressed in [RFC 3339](https://tools.ietf.org/html/rfc3339) timestamp format. For example, a start value of `2017-01-01T00:00:00Z` and an end value of `2017-01-02T00:00:00Z` will retrieve a list of all events processed on January 1, 2017.
|
116
144
|
# Similarly, a start value of `2017-01-01T00:00:00Z` and an end value of `2017-02-01T00:00:00Z` will result in a list of all events processed between January 1, 2017 and January 31, 2017.
|
117
145
|
# You can specify a value with granularity to the minute. Seconds (and milliseconds, if included) must be set to `0`.
|
118
|
-
#
|
146
|
+
#
|
119
147
|
# @param [Hash] opts the optional parameters
|
120
148
|
# @option opts [String] :page The value of the `opc-next-page` response header from the previous list query.
|
121
149
|
# @option opts [String] :opc_request_id Unique Oracle-assigned identifier for the request.
|
122
150
|
# If you need to contact Oracle about a particular request, please provide the request ID.
|
123
|
-
#
|
124
|
-
# @return [Response] A Response object with data of type Array<OCI::Audit::Models::AuditEvent>
|
151
|
+
#
|
152
|
+
# @return [Response] A Response object with data of type Array<{OCI::Audit::Models::AuditEvent AuditEvent}>
|
125
153
|
def list_events(compartment_id, start_time, end_time, opts = {})
|
126
|
-
logger.debug
|
154
|
+
logger.debug 'Calling operation AuditClient#list_events.' if logger
|
127
155
|
|
128
156
|
raise "Missing the required parameter 'compartment_id' when calling list_events." if compartment_id.nil?
|
129
157
|
raise "Missing the required parameter 'start_time' when calling list_events." if start_time.nil?
|
130
158
|
raise "Missing the required parameter 'end_time' when calling list_events." if end_time.nil?
|
131
159
|
|
132
|
-
path =
|
160
|
+
path = '/auditEvents'
|
161
|
+
operation_signing_strategy = :standard
|
133
162
|
|
134
163
|
# Query Params
|
135
164
|
query_params = {}
|
136
|
-
query_params[:
|
137
|
-
query_params[:
|
138
|
-
query_params[:
|
139
|
-
query_params[:
|
165
|
+
query_params[:compartmentId] = compartment_id
|
166
|
+
query_params[:startTime] = start_time
|
167
|
+
query_params[:endTime] = end_time
|
168
|
+
query_params[:page] = opts[:page] if opts[:page]
|
140
169
|
|
141
170
|
# Header Params
|
142
171
|
header_params = {}
|
143
172
|
header_params['accept'] = 'application/json'
|
144
173
|
header_params['content-type'] = 'application/json'
|
145
|
-
header_params[:'opc-request-id'] = opts[:
|
174
|
+
header_params[:'opc-request-id'] = opts[:opc_request_id] if opts[:opc_request_id]
|
146
175
|
|
147
176
|
post_body = nil
|
148
177
|
|
149
|
-
|
178
|
+
@api_client.call_api(
|
150
179
|
:GET,
|
151
180
|
path,
|
152
181
|
endpoint,
|
153
|
-
:
|
154
|
-
:
|
155
|
-
:
|
156
|
-
:
|
182
|
+
header_params: header_params,
|
183
|
+
query_params: query_params,
|
184
|
+
operation_signing_strategy: operation_signing_strategy,
|
185
|
+
body: post_body,
|
186
|
+
return_type: 'Array<OCI::Audit::Models::AuditEvent>'
|
187
|
+
)
|
157
188
|
end
|
189
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
190
|
+
# rubocop:enable Style/IfUnlessModifier, Metrics/ParameterLists
|
191
|
+
# rubocop:enable Metrics/MethodLength, Layout/EmptyLines
|
192
|
+
|
193
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
194
|
+
# rubocop:disable Style/IfUnlessModifier, Metrics/ParameterLists
|
195
|
+
# rubocop:disable Metrics/MethodLength, Layout/EmptyLines
|
196
|
+
# rubocop:disable Lint/UnusedMethodArgument
|
197
|
+
|
158
198
|
|
159
199
|
# Update the configuration
|
160
200
|
# @param [String] compartment_id ID of the root compartment (tenancy)
|
161
|
-
# @param [UpdateConfigurationDetails] update_configuration_details The configuration properties
|
201
|
+
# @param [OCI::Audit::Models::UpdateConfigurationDetails] update_configuration_details The configuration properties
|
162
202
|
# @param [Hash] opts the optional parameters
|
163
203
|
# @return [Response] A Response object with data of type nil
|
164
204
|
def update_configuration(compartment_id, update_configuration_details, opts = {})
|
165
|
-
logger.debug
|
205
|
+
logger.debug 'Calling operation AuditClient#update_configuration.' if logger
|
166
206
|
|
167
207
|
raise "Missing the required parameter 'compartment_id' when calling update_configuration." if compartment_id.nil?
|
168
208
|
raise "Missing the required parameter 'update_configuration_details' when calling update_configuration." if update_configuration_details.nil?
|
169
209
|
|
170
|
-
path =
|
210
|
+
path = '/configuration'
|
211
|
+
operation_signing_strategy = :standard
|
171
212
|
|
172
213
|
# Query Params
|
173
214
|
query_params = {}
|
174
|
-
query_params[:
|
215
|
+
query_params[:compartmentId] = compartment_id
|
175
216
|
|
176
217
|
# Header Params
|
177
218
|
header_params = {}
|
@@ -180,13 +221,20 @@ module OCI
|
|
180
221
|
|
181
222
|
post_body = @api_client.object_to_http_body(update_configuration_details)
|
182
223
|
|
183
|
-
|
224
|
+
@api_client.call_api(
|
184
225
|
:PUT,
|
185
226
|
path,
|
186
227
|
endpoint,
|
187
|
-
:
|
188
|
-
:
|
189
|
-
:
|
228
|
+
header_params: header_params,
|
229
|
+
query_params: query_params,
|
230
|
+
operation_signing_strategy: operation_signing_strategy,
|
231
|
+
body: post_body
|
232
|
+
)
|
190
233
|
end
|
234
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
235
|
+
# rubocop:enable Style/IfUnlessModifier, Metrics/ParameterLists
|
236
|
+
# rubocop:enable Metrics/MethodLength, Layout/EmptyLines
|
237
|
+
# rubocop:enable Lint/UnusedMethodArgument
|
191
238
|
end
|
192
239
|
end
|
240
|
+
# rubocop:enable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
@@ -0,0 +1,64 @@
|
|
1
|
+
# Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved.
|
2
|
+
|
3
|
+
# rubocop:disable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
4
|
+
module OCI
|
5
|
+
# This class provides a wrapper around {OCI::Audit::AuditClient} and offers convenience methods
|
6
|
+
# for operations that would otherwise need to be chained together. For example, instead of performing an action
|
7
|
+
# on a resource (e.g. launching an instance, creating a load balancer) and then using a waiter to wait for the resource
|
8
|
+
# to enter a given state, you can call a single method in this class to accomplish the same functionality
|
9
|
+
class Audit::AuditClientCompositeOperations
|
10
|
+
# The {OCI::Audit::AuditClient} used to communicate with the service_client
|
11
|
+
#
|
12
|
+
# @return [OCI::Audit::AuditClient]
|
13
|
+
attr_reader :service_client
|
14
|
+
|
15
|
+
# Initializes a new AuditClientCompositeOperations
|
16
|
+
#
|
17
|
+
# @param [OCI::Audit::AuditClient] service_client The client used to communicate with the service.
|
18
|
+
# Defaults to a new service client created via {OCI::Audit::AuditClient#initialize} with no arguments
|
19
|
+
def initialize(service_client = OCI::Audit::AuditClient.new)
|
20
|
+
@service_client = service_client
|
21
|
+
end
|
22
|
+
|
23
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/ParameterLists, Metrics/PerceivedComplexity
|
24
|
+
# rubocop:disable Layout/EmptyLines
|
25
|
+
|
26
|
+
|
27
|
+
# Calls {OCI::Audit::AuditClient#update_configuration} and then waits for the {OCI::Audit::Models::WorkRequest}
|
28
|
+
# to enter the given state(s).
|
29
|
+
#
|
30
|
+
# @param [String] compartment_id ID of the root compartment (tenancy)
|
31
|
+
# @param [OCI::Audit::Models::UpdateConfigurationDetails] update_configuration_details The configuration properties
|
32
|
+
# @param [Array<String>] wait_for_states An array of states to wait on. These should be valid values for {OCI::Audit::Models::WorkRequest#status}
|
33
|
+
# @param [Hash] base_operation_opts Any optional arguments accepted by {OCI::Audit::AuditClient#update_configuration}
|
34
|
+
# @param [Hash] waiter_opts Optional arguments for the waiter. Keys should be symbols, and the following keys are supported:
|
35
|
+
# * max_interval_seconds: The maximum interval between queries, in seconds.
|
36
|
+
# * max_wait_seconds The maximum time to wait, in seconds
|
37
|
+
#
|
38
|
+
# @return [OCI::Response] A {OCI::Response} object containing the completed {OCI::Audit::Models::WorkRequest}
|
39
|
+
def update_configuration_and_wait_for_state(compartment_id, update_configuration_details, wait_for_states = [], base_operation_opts = {}, waiter_opts = {})
|
40
|
+
operation_result = @service_client.update_configuration(compartment_id, update_configuration_details, base_operation_opts)
|
41
|
+
|
42
|
+
return operation_result if wait_for_states.empty?
|
43
|
+
|
44
|
+
lowered_wait_for_states = wait_for_states.map(&:downcase)
|
45
|
+
wait_for_resource_id = operation_result.headers['opc-work-request-id']
|
46
|
+
|
47
|
+
begin
|
48
|
+
waiter_result = @service_client.get_work_request(wait_for_resource_id).wait_until(
|
49
|
+
eval_proc: ->(response) { response.data.respond_to?(:status) && lowered_wait_for_states.include?(response.data.status.downcase) },
|
50
|
+
max_interval_seconds: waiter_opts.key?(:max_interval_seconds) ? waiter_opts[:max_interval_seconds] : 30,
|
51
|
+
max_wait_seconds: waiter_opts.key?(:max_wait_seconds) ? waiter_opts[:max_wait_seconds] : 1200
|
52
|
+
)
|
53
|
+
result_to_return = waiter_result
|
54
|
+
|
55
|
+
return result_to_return
|
56
|
+
rescue StandardError
|
57
|
+
raise OCI::Errors::CompositeOperationError.new(partial_results: [operation_result])
|
58
|
+
end
|
59
|
+
end
|
60
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/ParameterLists, Metrics/PerceivedComplexity
|
61
|
+
# rubocop:enable Layout/EmptyLines
|
62
|
+
end
|
63
|
+
end
|
64
|
+
# rubocop:enable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
@@ -2,8 +2,10 @@
|
|
2
2
|
|
3
3
|
require 'date'
|
4
4
|
|
5
|
+
# rubocop:disable Lint/UnneededCopDisableDirective
|
5
6
|
module OCI
|
6
|
-
|
7
|
+
# AuditEvent model.
|
8
|
+
class Audit::Models::AuditEvent # rubocop:disable Metrics/LineLength
|
7
9
|
# The OCID of the tenant.
|
8
10
|
# @return [String]
|
9
11
|
attr_accessor :tenant_id
|
@@ -80,6 +82,63 @@ module OCI
|
|
80
82
|
# @return [Hash<String, Object>]
|
81
83
|
attr_accessor :response_payload
|
82
84
|
|
85
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
86
|
+
def self.attribute_map
|
87
|
+
{
|
88
|
+
# rubocop:disable Style/SymbolLiteral
|
89
|
+
'tenant_id': :'tenantId',
|
90
|
+
'compartment_id': :'compartmentId',
|
91
|
+
'event_id': :'eventId',
|
92
|
+
'event_source': :'eventSource',
|
93
|
+
'event_type': :'eventType',
|
94
|
+
'event_time': :'eventTime',
|
95
|
+
'principal_id': :'principalId',
|
96
|
+
'credential_id': :'credentialId',
|
97
|
+
'request_action': :'requestAction',
|
98
|
+
'request_id': :'requestId',
|
99
|
+
'request_agent': :'requestAgent',
|
100
|
+
'request_headers': :'requestHeaders',
|
101
|
+
'request_origin': :'requestOrigin',
|
102
|
+
'request_parameters': :'requestParameters',
|
103
|
+
'request_resource': :'requestResource',
|
104
|
+
'response_headers': :'responseHeaders',
|
105
|
+
'response_status': :'responseStatus',
|
106
|
+
'response_time': :'responseTime',
|
107
|
+
'response_payload': :'responsePayload'
|
108
|
+
# rubocop:enable Style/SymbolLiteral
|
109
|
+
}
|
110
|
+
end
|
111
|
+
|
112
|
+
# Attribute type mapping.
|
113
|
+
def self.swagger_types
|
114
|
+
{
|
115
|
+
# rubocop:disable Style/SymbolLiteral
|
116
|
+
'tenant_id': :'String',
|
117
|
+
'compartment_id': :'String',
|
118
|
+
'event_id': :'String',
|
119
|
+
'event_source': :'String',
|
120
|
+
'event_type': :'String',
|
121
|
+
'event_time': :'DateTime',
|
122
|
+
'principal_id': :'String',
|
123
|
+
'credential_id': :'String',
|
124
|
+
'request_action': :'String',
|
125
|
+
'request_id': :'String',
|
126
|
+
'request_agent': :'String',
|
127
|
+
'request_headers': :'Hash<String, Array<String>>',
|
128
|
+
'request_origin': :'String',
|
129
|
+
'request_parameters': :'Hash<String, Array<String>>',
|
130
|
+
'request_resource': :'String',
|
131
|
+
'response_headers': :'Hash<String, Array<String>>',
|
132
|
+
'response_status': :'String',
|
133
|
+
'response_time': :'DateTime',
|
134
|
+
'response_payload': :'Hash<String, Object>'
|
135
|
+
# rubocop:enable Style/SymbolLiteral
|
136
|
+
}
|
137
|
+
end
|
138
|
+
|
139
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
140
|
+
# rubocop:disable Metrics/LineLength, Metrics/MethodLength, Layout/EmptyLines, Style/SymbolLiteral
|
141
|
+
|
83
142
|
|
84
143
|
# Initializes the object
|
85
144
|
# @param [Hash] attributes Model attributes in the form of hash
|
@@ -106,237 +165,173 @@ module OCI
|
|
106
165
|
return unless attributes.is_a?(Hash)
|
107
166
|
|
108
167
|
# convert string to symbol for hash key
|
109
|
-
attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
|
168
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
110
169
|
|
111
|
-
if attributes[:'tenantId']
|
112
|
-
self.tenant_id = attributes[:'tenantId']
|
113
|
-
end
|
170
|
+
self.tenant_id = attributes[:'tenantId'] if attributes[:'tenantId']
|
114
171
|
|
115
172
|
raise 'You cannot provide both :tenantId and :tenant_id' if attributes.key?(:'tenantId') && attributes.key?(:'tenant_id')
|
116
173
|
|
117
|
-
if attributes[:'tenant_id']
|
118
|
-
self.tenant_id = attributes[:'tenant_id']
|
119
|
-
end
|
174
|
+
self.tenant_id = attributes[:'tenant_id'] if attributes[:'tenant_id']
|
120
175
|
|
121
|
-
if attributes[:'compartmentId']
|
122
|
-
self.compartment_id = attributes[:'compartmentId']
|
123
|
-
end
|
176
|
+
self.compartment_id = attributes[:'compartmentId'] if attributes[:'compartmentId']
|
124
177
|
|
125
178
|
raise 'You cannot provide both :compartmentId and :compartment_id' if attributes.key?(:'compartmentId') && attributes.key?(:'compartment_id')
|
126
179
|
|
127
|
-
if attributes[:'compartment_id']
|
128
|
-
self.compartment_id = attributes[:'compartment_id']
|
129
|
-
end
|
180
|
+
self.compartment_id = attributes[:'compartment_id'] if attributes[:'compartment_id']
|
130
181
|
|
131
|
-
if attributes[:'eventId']
|
132
|
-
self.event_id = attributes[:'eventId']
|
133
|
-
end
|
182
|
+
self.event_id = attributes[:'eventId'] if attributes[:'eventId']
|
134
183
|
|
135
184
|
raise 'You cannot provide both :eventId and :event_id' if attributes.key?(:'eventId') && attributes.key?(:'event_id')
|
136
185
|
|
137
|
-
if attributes[:'event_id']
|
138
|
-
self.event_id = attributes[:'event_id']
|
139
|
-
end
|
186
|
+
self.event_id = attributes[:'event_id'] if attributes[:'event_id']
|
140
187
|
|
141
|
-
if attributes[:'eventSource']
|
142
|
-
self.event_source = attributes[:'eventSource']
|
143
|
-
end
|
188
|
+
self.event_source = attributes[:'eventSource'] if attributes[:'eventSource']
|
144
189
|
|
145
190
|
raise 'You cannot provide both :eventSource and :event_source' if attributes.key?(:'eventSource') && attributes.key?(:'event_source')
|
146
191
|
|
147
|
-
if attributes[:'event_source']
|
148
|
-
self.event_source = attributes[:'event_source']
|
149
|
-
end
|
192
|
+
self.event_source = attributes[:'event_source'] if attributes[:'event_source']
|
150
193
|
|
151
|
-
if attributes[:'eventType']
|
152
|
-
self.event_type = attributes[:'eventType']
|
153
|
-
end
|
194
|
+
self.event_type = attributes[:'eventType'] if attributes[:'eventType']
|
154
195
|
|
155
196
|
raise 'You cannot provide both :eventType and :event_type' if attributes.key?(:'eventType') && attributes.key?(:'event_type')
|
156
197
|
|
157
|
-
if attributes[:'event_type']
|
158
|
-
self.event_type = attributes[:'event_type']
|
159
|
-
end
|
198
|
+
self.event_type = attributes[:'event_type'] if attributes[:'event_type']
|
160
199
|
|
161
|
-
if attributes[:'eventTime']
|
162
|
-
self.event_time = attributes[:'eventTime']
|
163
|
-
end
|
200
|
+
self.event_time = attributes[:'eventTime'] if attributes[:'eventTime']
|
164
201
|
|
165
202
|
raise 'You cannot provide both :eventTime and :event_time' if attributes.key?(:'eventTime') && attributes.key?(:'event_time')
|
166
203
|
|
167
|
-
if attributes[:'event_time']
|
168
|
-
self.event_time = attributes[:'event_time']
|
169
|
-
end
|
204
|
+
self.event_time = attributes[:'event_time'] if attributes[:'event_time']
|
170
205
|
|
171
|
-
if attributes[:'principalId']
|
172
|
-
self.principal_id = attributes[:'principalId']
|
173
|
-
end
|
206
|
+
self.principal_id = attributes[:'principalId'] if attributes[:'principalId']
|
174
207
|
|
175
208
|
raise 'You cannot provide both :principalId and :principal_id' if attributes.key?(:'principalId') && attributes.key?(:'principal_id')
|
176
209
|
|
177
|
-
if attributes[:'principal_id']
|
178
|
-
self.principal_id = attributes[:'principal_id']
|
179
|
-
end
|
210
|
+
self.principal_id = attributes[:'principal_id'] if attributes[:'principal_id']
|
180
211
|
|
181
|
-
if attributes[:'credentialId']
|
182
|
-
self.credential_id = attributes[:'credentialId']
|
183
|
-
end
|
212
|
+
self.credential_id = attributes[:'credentialId'] if attributes[:'credentialId']
|
184
213
|
|
185
214
|
raise 'You cannot provide both :credentialId and :credential_id' if attributes.key?(:'credentialId') && attributes.key?(:'credential_id')
|
186
215
|
|
187
|
-
if attributes[:'credential_id']
|
188
|
-
self.credential_id = attributes[:'credential_id']
|
189
|
-
end
|
216
|
+
self.credential_id = attributes[:'credential_id'] if attributes[:'credential_id']
|
190
217
|
|
191
|
-
if attributes[:'requestAction']
|
192
|
-
self.request_action = attributes[:'requestAction']
|
193
|
-
end
|
218
|
+
self.request_action = attributes[:'requestAction'] if attributes[:'requestAction']
|
194
219
|
|
195
220
|
raise 'You cannot provide both :requestAction and :request_action' if attributes.key?(:'requestAction') && attributes.key?(:'request_action')
|
196
221
|
|
197
|
-
if attributes[:'request_action']
|
198
|
-
self.request_action = attributes[:'request_action']
|
199
|
-
end
|
222
|
+
self.request_action = attributes[:'request_action'] if attributes[:'request_action']
|
200
223
|
|
201
|
-
if attributes[:'requestId']
|
202
|
-
self.request_id = attributes[:'requestId']
|
203
|
-
end
|
224
|
+
self.request_id = attributes[:'requestId'] if attributes[:'requestId']
|
204
225
|
|
205
226
|
raise 'You cannot provide both :requestId and :request_id' if attributes.key?(:'requestId') && attributes.key?(:'request_id')
|
206
227
|
|
207
|
-
if attributes[:'request_id']
|
208
|
-
self.request_id = attributes[:'request_id']
|
209
|
-
end
|
228
|
+
self.request_id = attributes[:'request_id'] if attributes[:'request_id']
|
210
229
|
|
211
|
-
if attributes[:'requestAgent']
|
212
|
-
self.request_agent = attributes[:'requestAgent']
|
213
|
-
end
|
230
|
+
self.request_agent = attributes[:'requestAgent'] if attributes[:'requestAgent']
|
214
231
|
|
215
232
|
raise 'You cannot provide both :requestAgent and :request_agent' if attributes.key?(:'requestAgent') && attributes.key?(:'request_agent')
|
216
233
|
|
217
|
-
if attributes[:'request_agent']
|
218
|
-
self.request_agent = attributes[:'request_agent']
|
219
|
-
end
|
234
|
+
self.request_agent = attributes[:'request_agent'] if attributes[:'request_agent']
|
220
235
|
|
221
|
-
if attributes[:'requestHeaders']
|
222
|
-
self.request_headers = attributes[:'requestHeaders']
|
223
|
-
end
|
236
|
+
self.request_headers = attributes[:'requestHeaders'] if attributes[:'requestHeaders']
|
224
237
|
|
225
238
|
raise 'You cannot provide both :requestHeaders and :request_headers' if attributes.key?(:'requestHeaders') && attributes.key?(:'request_headers')
|
226
239
|
|
227
|
-
if attributes[:'request_headers']
|
228
|
-
self.request_headers = attributes[:'request_headers']
|
229
|
-
end
|
240
|
+
self.request_headers = attributes[:'request_headers'] if attributes[:'request_headers']
|
230
241
|
|
231
|
-
if attributes[:'requestOrigin']
|
232
|
-
self.request_origin = attributes[:'requestOrigin']
|
233
|
-
end
|
242
|
+
self.request_origin = attributes[:'requestOrigin'] if attributes[:'requestOrigin']
|
234
243
|
|
235
244
|
raise 'You cannot provide both :requestOrigin and :request_origin' if attributes.key?(:'requestOrigin') && attributes.key?(:'request_origin')
|
236
245
|
|
237
|
-
if attributes[:'request_origin']
|
238
|
-
self.request_origin = attributes[:'request_origin']
|
239
|
-
end
|
246
|
+
self.request_origin = attributes[:'request_origin'] if attributes[:'request_origin']
|
240
247
|
|
241
|
-
if attributes[:'requestParameters']
|
242
|
-
self.request_parameters = attributes[:'requestParameters']
|
243
|
-
end
|
248
|
+
self.request_parameters = attributes[:'requestParameters'] if attributes[:'requestParameters']
|
244
249
|
|
245
250
|
raise 'You cannot provide both :requestParameters and :request_parameters' if attributes.key?(:'requestParameters') && attributes.key?(:'request_parameters')
|
246
251
|
|
247
|
-
if attributes[:'request_parameters']
|
248
|
-
self.request_parameters = attributes[:'request_parameters']
|
249
|
-
end
|
252
|
+
self.request_parameters = attributes[:'request_parameters'] if attributes[:'request_parameters']
|
250
253
|
|
251
|
-
if attributes[:'requestResource']
|
252
|
-
self.request_resource = attributes[:'requestResource']
|
253
|
-
end
|
254
|
+
self.request_resource = attributes[:'requestResource'] if attributes[:'requestResource']
|
254
255
|
|
255
256
|
raise 'You cannot provide both :requestResource and :request_resource' if attributes.key?(:'requestResource') && attributes.key?(:'request_resource')
|
256
257
|
|
257
|
-
if attributes[:'request_resource']
|
258
|
-
self.request_resource = attributes[:'request_resource']
|
259
|
-
end
|
258
|
+
self.request_resource = attributes[:'request_resource'] if attributes[:'request_resource']
|
260
259
|
|
261
|
-
if attributes[:'responseHeaders']
|
262
|
-
self.response_headers = attributes[:'responseHeaders']
|
263
|
-
end
|
260
|
+
self.response_headers = attributes[:'responseHeaders'] if attributes[:'responseHeaders']
|
264
261
|
|
265
262
|
raise 'You cannot provide both :responseHeaders and :response_headers' if attributes.key?(:'responseHeaders') && attributes.key?(:'response_headers')
|
266
263
|
|
267
|
-
if attributes[:'response_headers']
|
268
|
-
self.response_headers = attributes[:'response_headers']
|
269
|
-
end
|
264
|
+
self.response_headers = attributes[:'response_headers'] if attributes[:'response_headers']
|
270
265
|
|
271
|
-
if attributes[:'responseStatus']
|
272
|
-
self.response_status = attributes[:'responseStatus']
|
273
|
-
end
|
266
|
+
self.response_status = attributes[:'responseStatus'] if attributes[:'responseStatus']
|
274
267
|
|
275
268
|
raise 'You cannot provide both :responseStatus and :response_status' if attributes.key?(:'responseStatus') && attributes.key?(:'response_status')
|
276
269
|
|
277
|
-
if attributes[:'response_status']
|
278
|
-
self.response_status = attributes[:'response_status']
|
279
|
-
end
|
270
|
+
self.response_status = attributes[:'response_status'] if attributes[:'response_status']
|
280
271
|
|
281
|
-
if attributes[:'responseTime']
|
282
|
-
self.response_time = attributes[:'responseTime']
|
283
|
-
end
|
272
|
+
self.response_time = attributes[:'responseTime'] if attributes[:'responseTime']
|
284
273
|
|
285
274
|
raise 'You cannot provide both :responseTime and :response_time' if attributes.key?(:'responseTime') && attributes.key?(:'response_time')
|
286
275
|
|
287
|
-
if attributes[:'response_time']
|
288
|
-
self.response_time = attributes[:'response_time']
|
289
|
-
end
|
276
|
+
self.response_time = attributes[:'response_time'] if attributes[:'response_time']
|
290
277
|
|
291
|
-
if attributes[:'responsePayload']
|
292
|
-
self.response_payload = attributes[:'responsePayload']
|
293
|
-
end
|
278
|
+
self.response_payload = attributes[:'responsePayload'] if attributes[:'responsePayload']
|
294
279
|
|
295
280
|
raise 'You cannot provide both :responsePayload and :response_payload' if attributes.key?(:'responsePayload') && attributes.key?(:'response_payload')
|
296
281
|
|
297
|
-
if attributes[:'response_payload']
|
298
|
-
self.response_payload = attributes[:'response_payload']
|
299
|
-
end
|
300
|
-
|
282
|
+
self.response_payload = attributes[:'response_payload'] if attributes[:'response_payload']
|
301
283
|
end
|
284
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
285
|
+
# rubocop:enable Metrics/LineLength, Metrics/MethodLength, Layout/EmptyLines, Style/SymbolLiteral
|
286
|
+
|
287
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity, Layout/EmptyLines
|
288
|
+
|
302
289
|
|
303
290
|
# Checks equality by comparing each attribute.
|
304
|
-
# @param [Object]
|
305
|
-
def ==(
|
306
|
-
return true if
|
307
|
-
self.class ==
|
308
|
-
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
|
320
|
-
|
321
|
-
|
322
|
-
|
323
|
-
|
324
|
-
|
325
|
-
|
326
|
-
|
291
|
+
# @param [Object] other the other object to be compared
|
292
|
+
def ==(other)
|
293
|
+
return true if equal?(other)
|
294
|
+
self.class == other.class &&
|
295
|
+
tenant_id == other.tenant_id &&
|
296
|
+
compartment_id == other.compartment_id &&
|
297
|
+
event_id == other.event_id &&
|
298
|
+
event_source == other.event_source &&
|
299
|
+
event_type == other.event_type &&
|
300
|
+
event_time == other.event_time &&
|
301
|
+
principal_id == other.principal_id &&
|
302
|
+
credential_id == other.credential_id &&
|
303
|
+
request_action == other.request_action &&
|
304
|
+
request_id == other.request_id &&
|
305
|
+
request_agent == other.request_agent &&
|
306
|
+
request_headers == other.request_headers &&
|
307
|
+
request_origin == other.request_origin &&
|
308
|
+
request_parameters == other.request_parameters &&
|
309
|
+
request_resource == other.request_resource &&
|
310
|
+
response_headers == other.response_headers &&
|
311
|
+
response_status == other.response_status &&
|
312
|
+
response_time == other.response_time &&
|
313
|
+
response_payload == other.response_payload
|
327
314
|
end
|
315
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity, Layout/EmptyLines
|
328
316
|
|
329
317
|
# @see the `==` method
|
330
|
-
# @param [Object]
|
331
|
-
def eql?(
|
332
|
-
self ==
|
318
|
+
# @param [Object] other the other object to be compared
|
319
|
+
def eql?(other)
|
320
|
+
self == other
|
333
321
|
end
|
334
322
|
|
323
|
+
# rubocop:disable Metrics/AbcSize, Metrics/LineLength, Layout/EmptyLines
|
324
|
+
|
325
|
+
|
335
326
|
# Calculates hash code according to all attributes.
|
336
327
|
# @return [Fixnum] Hash code
|
337
328
|
def hash
|
338
329
|
[tenant_id, compartment_id, event_id, event_source, event_type, event_time, principal_id, credential_id, request_action, request_id, request_agent, request_headers, request_origin, request_parameters, request_resource, response_headers, response_status, response_time, response_payload].hash
|
339
330
|
end
|
331
|
+
# rubocop:enable Metrics/AbcSize, Metrics/LineLength, Layout/EmptyLines
|
332
|
+
|
333
|
+
# rubocop:disable Metrics/AbcSize, Layout/EmptyLines
|
334
|
+
|
340
335
|
|
341
336
|
# Builds the object from hash
|
342
337
|
# @param [Hash] attributes Model attributes in the form of hash
|
@@ -348,15 +343,22 @@ module OCI
|
|
348
343
|
# check to ensure the input is an array given that the the attribute
|
349
344
|
# is documented as an array but the input is not
|
350
345
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
351
|
-
|
346
|
+
public_method("#{key}=").call(
|
347
|
+
attributes[self.class.attribute_map[key]]
|
348
|
+
.map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) }
|
349
|
+
)
|
352
350
|
end
|
353
351
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
354
|
-
|
355
|
-
|
352
|
+
public_method("#{key}=").call(
|
353
|
+
OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]])
|
354
|
+
)
|
355
|
+
end
|
356
|
+
# or else data not found in attributes(hash), not an issue as the data can be optional
|
356
357
|
end
|
357
358
|
|
358
359
|
self
|
359
360
|
end
|
361
|
+
# rubocop:enable Metrics/AbcSize, Layout/EmptyLines
|
360
362
|
|
361
363
|
# Returns the string representation of the object
|
362
364
|
# @return [String] String presentation of the object
|
@@ -380,11 +382,11 @@ module OCI
|
|
380
382
|
|
381
383
|
# Outputs non-array value in the form of hash
|
382
384
|
# For object, use to_hash. Otherwise, just return the value
|
383
|
-
# @param [Object] value Any valid value
|
385
|
+
# @param [Object] value Any valid value
|
384
386
|
# @return [Hash] Returns the value in the form of hash
|
385
387
|
def _to_hash(value)
|
386
388
|
if value.is_a?(Array)
|
387
|
-
value.compact.map{ |v| _to_hash(v) }
|
389
|
+
value.compact.map { |v| _to_hash(v) }
|
388
390
|
elsif value.is_a?(Hash)
|
389
391
|
{}.tap do |hash|
|
390
392
|
value.each { |k, v| hash[k] = _to_hash(v) }
|
@@ -395,57 +397,6 @@ module OCI
|
|
395
397
|
value
|
396
398
|
end
|
397
399
|
end
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
# Attribute mapping from ruby-style variable name to JSON key.
|
402
|
-
def self.attribute_map
|
403
|
-
{
|
404
|
-
:'tenant_id' => :'tenantId',
|
405
|
-
:'compartment_id' => :'compartmentId',
|
406
|
-
:'event_id' => :'eventId',
|
407
|
-
:'event_source' => :'eventSource',
|
408
|
-
:'event_type' => :'eventType',
|
409
|
-
:'event_time' => :'eventTime',
|
410
|
-
:'principal_id' => :'principalId',
|
411
|
-
:'credential_id' => :'credentialId',
|
412
|
-
:'request_action' => :'requestAction',
|
413
|
-
:'request_id' => :'requestId',
|
414
|
-
:'request_agent' => :'requestAgent',
|
415
|
-
:'request_headers' => :'requestHeaders',
|
416
|
-
:'request_origin' => :'requestOrigin',
|
417
|
-
:'request_parameters' => :'requestParameters',
|
418
|
-
:'request_resource' => :'requestResource',
|
419
|
-
:'response_headers' => :'responseHeaders',
|
420
|
-
:'response_status' => :'responseStatus',
|
421
|
-
:'response_time' => :'responseTime',
|
422
|
-
:'response_payload' => :'responsePayload'
|
423
|
-
}
|
424
|
-
end
|
425
|
-
|
426
|
-
# Attribute type mapping.
|
427
|
-
def self.swagger_types
|
428
|
-
{
|
429
|
-
:'tenant_id' => :'String',
|
430
|
-
:'compartment_id' => :'String',
|
431
|
-
:'event_id' => :'String',
|
432
|
-
:'event_source' => :'String',
|
433
|
-
:'event_type' => :'String',
|
434
|
-
:'event_time' => :'DateTime',
|
435
|
-
:'principal_id' => :'String',
|
436
|
-
:'credential_id' => :'String',
|
437
|
-
:'request_action' => :'String',
|
438
|
-
:'request_id' => :'String',
|
439
|
-
:'request_agent' => :'String',
|
440
|
-
:'request_headers' => :'Hash<String, Array<String>>',
|
441
|
-
:'request_origin' => :'String',
|
442
|
-
:'request_parameters' => :'Hash<String, Array<String>>',
|
443
|
-
:'request_resource' => :'String',
|
444
|
-
:'response_headers' => :'Hash<String, Array<String>>',
|
445
|
-
:'response_status' => :'String',
|
446
|
-
:'response_time' => :'DateTime',
|
447
|
-
:'response_payload' => :'Hash<String, Object>'
|
448
|
-
}
|
449
|
-
end
|
450
400
|
end
|
451
401
|
end
|
402
|
+
# rubocop:enable Lint/UnneededCopDisableDirective
|