oci 2.5.11 → 2.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +3 -1
- data/lib/oci.rb +1 -0
- data/lib/oci/auth/federation_client.rb +2 -1
- data/lib/oci/auth/signers/instance_principals_security_token_signer.rb +6 -1
- data/lib/oci/auth/url_based_certificate_retriever.rb +6 -2
- data/lib/oci/auth/util.rb +18 -0
- data/lib/oci/core/compute_client.rb +730 -48
- data/lib/oci/core/compute_client_composite_operations.rb +119 -0
- data/lib/oci/core/compute_management_client.rb +11 -4
- data/lib/oci/core/core.rb +13 -0
- data/lib/oci/core/models/add_security_rule_details.rb +4 -2
- data/lib/oci/core/models/attach_vnic_details.rb +1 -0
- data/lib/oci/core/models/capture_console_history_details.rb +1 -0
- data/lib/oci/core/models/change_dedicated_vm_host_compartment_details.rb +155 -0
- data/lib/oci/core/models/change_dhcp_options_compartment_details.rb +155 -0
- data/lib/oci/core/models/change_internet_gateway_compartment_details.rb +155 -0
- data/lib/oci/core/models/change_local_peering_gateway_compartment_details.rb +155 -0
- data/lib/oci/core/models/change_network_security_group_compartment_details.rb +155 -0
- data/lib/oci/core/models/change_public_ip_compartment_details.rb +155 -0
- data/lib/oci/core/models/create_dedicated_vm_host_details.rb +262 -0
- data/lib/oci/core/models/create_drg_attachment_details.rb +4 -2
- data/lib/oci/core/models/create_image_details.rb +1 -1
- data/lib/oci/core/models/create_instance_configuration_base.rb +16 -6
- data/lib/oci/core/models/create_instance_configuration_details.rb +1 -1
- data/lib/oci/core/models/create_instance_configuration_from_instance_details.rb +3 -2
- data/lib/oci/core/models/create_instance_pool_details.rb +3 -1
- data/lib/oci/core/models/create_local_peering_gateway_details.rb +1 -1
- data/lib/oci/core/models/create_service_gateway_details.rb +1 -1
- data/lib/oci/core/models/create_volume_group_backup_details.rb +3 -1
- data/lib/oci/core/models/create_volume_group_details.rb +1 -1
- data/lib/oci/core/models/cross_connect_mapping.rb +4 -0
- data/lib/oci/core/models/dedicated_vm_host.rb +359 -0
- data/lib/oci/core/models/dedicated_vm_host_instance_shape_summary.rb +170 -0
- data/lib/oci/core/models/dedicated_vm_host_instance_summary.rb +215 -0
- data/lib/oci/core/models/dedicated_vm_host_shape_summary.rb +171 -0
- data/lib/oci/core/models/dedicated_vm_host_summary.rb +325 -0
- data/lib/oci/core/models/drg_attachment.rb +6 -3
- data/lib/oci/core/models/egress_security_rule.rb +1 -0
- data/lib/oci/core/models/image.rb +2 -0
- data/lib/oci/core/models/ingress_security_rule.rb +2 -1
- data/lib/oci/core/models/instance.rb +16 -1
- data/lib/oci/core/models/instance_configuration.rb +10 -7
- data/lib/oci/core/models/ipv6.rb +2 -0
- data/lib/oci/core/models/launch_instance_details.rb +16 -1
- data/lib/oci/core/models/launch_options.rb +3 -2
- data/lib/oci/core/models/local_peering_gateway.rb +4 -3
- data/lib/oci/core/models/route_rule.rb +2 -1
- data/lib/oci/core/models/security_rule.rb +3 -1
- data/lib/oci/core/models/service_gateway.rb +4 -3
- data/lib/oci/core/models/subnet.rb +2 -1
- data/lib/oci/core/models/update_console_history_details.rb +1 -0
- data/lib/oci/core/models/update_dedicated_vm_host_details.rb +194 -0
- data/lib/oci/core/models/update_drg_attachment_details.rb +6 -3
- data/lib/oci/core/models/update_instance_pool_details.rb +3 -1
- data/lib/oci/core/models/update_local_peering_gateway_details.rb +4 -3
- data/lib/oci/core/models/update_network_security_group_details.rb +2 -0
- data/lib/oci/core/models/update_security_rule_details.rb +4 -2
- data/lib/oci/core/models/update_service_gateway_details.rb +4 -3
- data/lib/oci/core/models/update_vnic_details.rb +2 -0
- data/lib/oci/core/models/update_volume_backup_details.rb +1 -1
- data/lib/oci/core/models/update_volume_group_backup_details.rb +2 -1
- data/lib/oci/core/models/update_volume_group_details.rb +2 -1
- data/lib/oci/core/models/vcn.rb +2 -1
- data/lib/oci/core/models/volume_backup_schedule.rb +1 -1
- data/lib/oci/core/virtual_network_client.rb +396 -59
- data/lib/oci/dts/dts.rb +57 -0
- data/lib/oci/dts/models/attach_devices_details.rb +153 -0
- data/lib/oci/dts/models/change_transfer_job_compartment_details.rb +154 -0
- data/lib/oci/dts/models/create_transfer_appliance_details.rb +152 -0
- data/lib/oci/dts/models/create_transfer_appliance_entitlement_details.rb +178 -0
- data/lib/oci/dts/models/create_transfer_device_details.rb +165 -0
- data/lib/oci/dts/models/create_transfer_job_details.rb +238 -0
- data/lib/oci/dts/models/create_transfer_package_details.rb +178 -0
- data/lib/oci/dts/models/detach_devices_details.rb +153 -0
- data/lib/oci/dts/models/multiple_transfer_appliances.rb +153 -0
- data/lib/oci/dts/models/multiple_transfer_devices.rb +153 -0
- data/lib/oci/dts/models/multiple_transfer_packages.rb +153 -0
- data/lib/oci/dts/models/new_transfer_device.rb +246 -0
- data/lib/oci/dts/models/shipping_address.rb +263 -0
- data/lib/oci/dts/models/shipping_vendors.rb +149 -0
- data/lib/oci/dts/models/transfer_appliance.rb +367 -0
- data/lib/oci/dts/models/transfer_appliance_certificate.rb +148 -0
- data/lib/oci/dts/models/transfer_appliance_encryption_passphrase.rb +152 -0
- data/lib/oci/dts/models/transfer_appliance_entitlement.rb +240 -0
- data/lib/oci/dts/models/transfer_appliance_public_key.rb +152 -0
- data/lib/oci/dts/models/transfer_appliance_summary.rb +223 -0
- data/lib/oci/dts/models/transfer_device.rb +268 -0
- data/lib/oci/dts/models/transfer_device_summary.rb +254 -0
- data/lib/oci/dts/models/transfer_job.rb +356 -0
- data/lib/oci/dts/models/transfer_job_summary.rb +296 -0
- data/lib/oci/dts/models/transfer_package.rb +281 -0
- data/lib/oci/dts/models/transfer_package_summary.rb +201 -0
- data/lib/oci/dts/models/update_transfer_appliance_details.rb +180 -0
- data/lib/oci/dts/models/update_transfer_device_details.rb +166 -0
- data/lib/oci/dts/models/update_transfer_job_details.rb +237 -0
- data/lib/oci/dts/models/update_transfer_package_details.rb +204 -0
- data/lib/oci/dts/shipping_vendors_client.rb +165 -0
- data/lib/oci/dts/shipping_vendors_client_composite_operations.rb +24 -0
- data/lib/oci/dts/transfer_appliance_client.rb +569 -0
- data/lib/oci/dts/transfer_appliance_client_composite_operations.rb +104 -0
- data/lib/oci/dts/transfer_appliance_entitlement_client.rb +223 -0
- data/lib/oci/dts/transfer_appliance_entitlement_client_composite_operations.rb +24 -0
- data/lib/oci/dts/transfer_device_client.rb +402 -0
- data/lib/oci/dts/transfer_device_client_composite_operations.rb +65 -0
- data/lib/oci/dts/transfer_job_client.rb +458 -0
- data/lib/oci/dts/transfer_job_client_composite_operations.rb +143 -0
- data/lib/oci/dts/transfer_package_client.rb +515 -0
- data/lib/oci/dts/transfer_package_client_composite_operations.rb +104 -0
- data/lib/oci/dts/util.rb +2 -0
- data/lib/oci/file_storage/models/create_file_system_details.rb +19 -4
- data/lib/oci/file_storage/models/file_system.rb +19 -4
- data/lib/oci/file_storage/models/file_system_summary.rb +19 -4
- data/lib/oci/file_storage/models/update_file_system_details.rb +22 -4
- data/lib/oci/limits/limits.rb +5 -0
- data/lib/oci/limits/limits_client.rb +444 -0
- data/lib/oci/limits/limits_client_composite_operations.rb +24 -0
- data/lib/oci/limits/models/create_quota_details.rb +1 -1
- data/lib/oci/limits/models/limit_definition_summary.rb +241 -0
- data/lib/oci/limits/models/limit_value_summary.rb +210 -0
- data/lib/oci/limits/models/quota.rb +1 -1
- data/lib/oci/limits/models/resource_availability.rb +163 -0
- data/lib/oci/limits/models/service_summary.rb +159 -0
- data/lib/oci/limits/models/update_quota_details.rb +1 -1
- data/lib/oci/limits/quotas_client.rb +12 -11
- data/lib/oci/monitoring/models/alarm.rb +20 -1
- data/lib/oci/monitoring/models/create_alarm_details.rb +20 -1
- data/lib/oci/monitoring/models/list_metrics_details.rb +23 -3
- data/lib/oci/monitoring/models/metric.rb +20 -1
- data/lib/oci/monitoring/models/metric_data.rb +20 -1
- data/lib/oci/monitoring/models/metric_data_details.rb +20 -1
- data/lib/oci/monitoring/models/summarize_metrics_data_details.rb +20 -1
- data/lib/oci/monitoring/models/update_alarm_details.rb +20 -1
- data/lib/oci/regions.rb +14 -8
- data/lib/oci/streaming/models/archiver.rb +291 -0
- data/lib/oci/streaming/models/archiver_error.rb +159 -0
- data/lib/oci/streaming/models/archiver_lifecycle_state.rb +14 -0
- data/lib/oci/streaming/models/archiver_start_position.rb +10 -0
- data/lib/oci/streaming/models/create_archiver_details.rb +223 -0
- data/lib/oci/streaming/models/update_archiver_details.rb +222 -0
- data/lib/oci/streaming/stream_admin_client.rb +304 -0
- data/lib/oci/streaming/stream_admin_client_composite_operations.rb +162 -0
- data/lib/oci/streaming/streaming.rb +6 -0
- data/lib/oci/version.rb +1 -1
- data/lib/oci/waas/models/access_rule.rb +121 -4
- data/lib/oci/waas/models/access_rule_criteria.rb +12 -0
- data/lib/oci/waas/models/address_list.rb +289 -0
- data/lib/oci/waas/models/address_list_summary.rb +279 -0
- data/lib/oci/waas/models/caching_rule.rb +243 -0
- data/lib/oci/waas/models/caching_rule_criteria.rb +194 -0
- data/lib/oci/waas/models/caching_rule_summary.rb +246 -0
- data/lib/oci/waas/models/certificate.rb +22 -9
- data/lib/oci/waas/models/certificate_extensions.rb +3 -0
- data/lib/oci/waas/models/certificate_issuer_name.rb +225 -0
- data/lib/oci/waas/models/certificate_public_key_info.rb +4 -1
- data/lib/oci/waas/models/certificate_subject_name.rb +8 -1
- data/lib/oci/waas/models/certificate_summary.rb +10 -2
- data/lib/oci/waas/models/change_address_list_compartment_details.rb +154 -0
- data/lib/oci/waas/models/change_custom_protection_rule_compartment_details.rb +154 -0
- data/lib/oci/waas/models/create_address_list_details.rb +213 -0
- data/lib/oci/waas/models/create_certificate_details.rb +22 -3
- data/lib/oci/waas/models/create_custom_protection_rule_details.rb +251 -0
- data/lib/oci/waas/models/create_waas_policy_details.rb +26 -4
- data/lib/oci/waas/models/custom_protection_rule.rb +326 -0
- data/lib/oci/waas/models/custom_protection_rule_setting.rb +180 -0
- data/lib/oci/waas/models/custom_protection_rule_summary.rb +279 -0
- data/lib/oci/waas/models/origin_group.rb +149 -0
- data/lib/oci/waas/models/origin_group_origins.rb +159 -0
- data/lib/oci/waas/models/policy_config.rb +201 -4
- data/lib/oci/waas/models/protection_rule_exclusion.rb +2 -2
- data/lib/oci/waas/models/purge_cache.rb +149 -0
- data/lib/oci/waas/models/update_address_list_details.rb +199 -0
- data/lib/oci/waas/models/update_certificate_details.rb +10 -2
- data/lib/oci/waas/models/update_custom_protection_rule_details.rb +237 -0
- data/lib/oci/waas/models/update_waas_policy_details.rb +26 -4
- data/lib/oci/waas/models/waas_policy.rb +25 -3
- data/lib/oci/waas/models/waas_policy_custom_protection_rule_summary.rb +207 -0
- data/lib/oci/waas/models/waas_policy_summary.rb +10 -2
- data/lib/oci/waas/models/waf_config.rb +43 -1
- data/lib/oci/waas/models/waf_config_details.rb +43 -1
- data/lib/oci/waas/models/waf_log.rb +3 -3
- data/lib/oci/waas/models/work_request.rb +4 -1
- data/lib/oci/waas/models/work_request_operation_types.rb +4 -1
- data/lib/oci/waas/models/work_request_summary.rb +4 -1
- data/lib/oci/waas/waas.rb +19 -0
- data/lib/oci/waas/waas_client.rb +1147 -61
- data/lib/oci/waas/waas_client_composite_operations.rb +386 -0
- metadata +90 -2
|
@@ -33,7 +33,7 @@ module OCI
|
|
|
33
33
|
# @return [String]
|
|
34
34
|
attr_accessor :name
|
|
35
35
|
|
|
36
|
-
# **[Required]** An array of one or more quota statements written in the declarative language.
|
|
36
|
+
# **[Required]** An array of one or more quota statements written in the declarative quota statement language.
|
|
37
37
|
# @return [Array<String>]
|
|
38
38
|
attr_accessor :statements
|
|
39
39
|
|
|
@@ -0,0 +1,163 @@
|
|
|
1
|
+
# Copyright (c) 2016, 2019, Oracle and/or its affiliates. All rights reserved.
|
|
2
|
+
|
|
3
|
+
require 'date'
|
|
4
|
+
|
|
5
|
+
# rubocop:disable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
|
6
|
+
module OCI
|
|
7
|
+
# The availability of a given resource limit, based on the usage, tenant service limits and quotas set for the tenancy.
|
|
8
|
+
# Note: We cannot guarantee this data for all the limits. In those cases, these fields will be empty.
|
|
9
|
+
#
|
|
10
|
+
class Limits::Models::ResourceAvailability
|
|
11
|
+
# The current usage in the given compartment.
|
|
12
|
+
#
|
|
13
|
+
# @return [Integer]
|
|
14
|
+
attr_accessor :used
|
|
15
|
+
|
|
16
|
+
# The count of available resources.
|
|
17
|
+
#
|
|
18
|
+
# @return [Integer]
|
|
19
|
+
attr_accessor :available
|
|
20
|
+
|
|
21
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
22
|
+
def self.attribute_map
|
|
23
|
+
{
|
|
24
|
+
# rubocop:disable Style/SymbolLiteral
|
|
25
|
+
'used': :'used',
|
|
26
|
+
'available': :'available'
|
|
27
|
+
# rubocop:enable Style/SymbolLiteral
|
|
28
|
+
}
|
|
29
|
+
end
|
|
30
|
+
|
|
31
|
+
# Attribute type mapping.
|
|
32
|
+
def self.swagger_types
|
|
33
|
+
{
|
|
34
|
+
# rubocop:disable Style/SymbolLiteral
|
|
35
|
+
'used': :'Integer',
|
|
36
|
+
'available': :'Integer'
|
|
37
|
+
# rubocop:enable Style/SymbolLiteral
|
|
38
|
+
}
|
|
39
|
+
end
|
|
40
|
+
|
|
41
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
|
42
|
+
# rubocop:disable Metrics/MethodLength, Layout/EmptyLines, Style/SymbolLiteral
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
# Initializes the object
|
|
46
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
47
|
+
# @option attributes [Integer] :used The value to assign to the {#used} property
|
|
48
|
+
# @option attributes [Integer] :available The value to assign to the {#available} property
|
|
49
|
+
def initialize(attributes = {})
|
|
50
|
+
return unless attributes.is_a?(Hash)
|
|
51
|
+
|
|
52
|
+
# convert string to symbol for hash key
|
|
53
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
|
54
|
+
|
|
55
|
+
self.used = attributes[:'used'] if attributes[:'used']
|
|
56
|
+
|
|
57
|
+
self.available = attributes[:'available'] if attributes[:'available']
|
|
58
|
+
end
|
|
59
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
|
60
|
+
# rubocop:enable Metrics/MethodLength, Layout/EmptyLines, Style/SymbolLiteral
|
|
61
|
+
|
|
62
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity, Layout/EmptyLines
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
# Checks equality by comparing each attribute.
|
|
66
|
+
# @param [Object] other the other object to be compared
|
|
67
|
+
def ==(other)
|
|
68
|
+
return true if equal?(other)
|
|
69
|
+
|
|
70
|
+
self.class == other.class &&
|
|
71
|
+
used == other.used &&
|
|
72
|
+
available == other.available
|
|
73
|
+
end
|
|
74
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity, Layout/EmptyLines
|
|
75
|
+
|
|
76
|
+
# @see the `==` method
|
|
77
|
+
# @param [Object] other the other object to be compared
|
|
78
|
+
def eql?(other)
|
|
79
|
+
self == other
|
|
80
|
+
end
|
|
81
|
+
|
|
82
|
+
# rubocop:disable Metrics/AbcSize, Layout/EmptyLines
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
# Calculates hash code according to all attributes.
|
|
86
|
+
# @return [Fixnum] Hash code
|
|
87
|
+
def hash
|
|
88
|
+
[used, available].hash
|
|
89
|
+
end
|
|
90
|
+
# rubocop:enable Metrics/AbcSize, Layout/EmptyLines
|
|
91
|
+
|
|
92
|
+
# rubocop:disable Metrics/AbcSize, Layout/EmptyLines
|
|
93
|
+
|
|
94
|
+
|
|
95
|
+
# Builds the object from hash
|
|
96
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
97
|
+
# @return [Object] Returns the model itself
|
|
98
|
+
def build_from_hash(attributes)
|
|
99
|
+
return nil unless attributes.is_a?(Hash)
|
|
100
|
+
|
|
101
|
+
self.class.swagger_types.each_pair do |key, type|
|
|
102
|
+
if type =~ /^Array<(.*)>/i
|
|
103
|
+
# check to ensure the input is an array given that the the attribute
|
|
104
|
+
# is documented as an array but the input is not
|
|
105
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
106
|
+
public_method("#{key}=").call(
|
|
107
|
+
attributes[self.class.attribute_map[key]]
|
|
108
|
+
.map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) }
|
|
109
|
+
)
|
|
110
|
+
end
|
|
111
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
112
|
+
public_method("#{key}=").call(
|
|
113
|
+
OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]])
|
|
114
|
+
)
|
|
115
|
+
end
|
|
116
|
+
# or else data not found in attributes(hash), not an issue as the data can be optional
|
|
117
|
+
end
|
|
118
|
+
|
|
119
|
+
self
|
|
120
|
+
end
|
|
121
|
+
# rubocop:enable Metrics/AbcSize, Layout/EmptyLines
|
|
122
|
+
|
|
123
|
+
# Returns the string representation of the object
|
|
124
|
+
# @return [String] String presentation of the object
|
|
125
|
+
def to_s
|
|
126
|
+
to_hash.to_s
|
|
127
|
+
end
|
|
128
|
+
|
|
129
|
+
# Returns the object in the form of hash
|
|
130
|
+
# @return [Hash] Returns the object in the form of hash
|
|
131
|
+
def to_hash
|
|
132
|
+
hash = {}
|
|
133
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
134
|
+
value = public_method(attr).call
|
|
135
|
+
next if value.nil? && !instance_variable_defined?("@#{attr}")
|
|
136
|
+
|
|
137
|
+
hash[param] = _to_hash(value)
|
|
138
|
+
end
|
|
139
|
+
hash
|
|
140
|
+
end
|
|
141
|
+
|
|
142
|
+
private
|
|
143
|
+
|
|
144
|
+
# Outputs non-array value in the form of hash
|
|
145
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
146
|
+
# @param [Object] value Any valid value
|
|
147
|
+
# @return [Hash] Returns the value in the form of hash
|
|
148
|
+
def _to_hash(value)
|
|
149
|
+
if value.is_a?(Array)
|
|
150
|
+
value.compact.map { |v| _to_hash(v) }
|
|
151
|
+
elsif value.is_a?(Hash)
|
|
152
|
+
{}.tap do |hash|
|
|
153
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
154
|
+
end
|
|
155
|
+
elsif value.respond_to? :to_hash
|
|
156
|
+
value.to_hash
|
|
157
|
+
else
|
|
158
|
+
value
|
|
159
|
+
end
|
|
160
|
+
end
|
|
161
|
+
end
|
|
162
|
+
end
|
|
163
|
+
# rubocop:enable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
# Copyright (c) 2016, 2019, Oracle and/or its affiliates. All rights reserved.
|
|
2
|
+
|
|
3
|
+
require 'date'
|
|
4
|
+
|
|
5
|
+
# rubocop:disable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
|
6
|
+
module OCI
|
|
7
|
+
# A specific OCI service supported by resource limits.
|
|
8
|
+
class Limits::Models::ServiceSummary
|
|
9
|
+
# The service name. Use this when calling the other APIs.
|
|
10
|
+
# @return [String]
|
|
11
|
+
attr_accessor :name
|
|
12
|
+
|
|
13
|
+
# The friendly service name.
|
|
14
|
+
# @return [String]
|
|
15
|
+
attr_accessor :description
|
|
16
|
+
|
|
17
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
18
|
+
def self.attribute_map
|
|
19
|
+
{
|
|
20
|
+
# rubocop:disable Style/SymbolLiteral
|
|
21
|
+
'name': :'name',
|
|
22
|
+
'description': :'description'
|
|
23
|
+
# rubocop:enable Style/SymbolLiteral
|
|
24
|
+
}
|
|
25
|
+
end
|
|
26
|
+
|
|
27
|
+
# Attribute type mapping.
|
|
28
|
+
def self.swagger_types
|
|
29
|
+
{
|
|
30
|
+
# rubocop:disable Style/SymbolLiteral
|
|
31
|
+
'name': :'String',
|
|
32
|
+
'description': :'String'
|
|
33
|
+
# rubocop:enable Style/SymbolLiteral
|
|
34
|
+
}
|
|
35
|
+
end
|
|
36
|
+
|
|
37
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
|
38
|
+
# rubocop:disable Metrics/MethodLength, Layout/EmptyLines, Style/SymbolLiteral
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
# Initializes the object
|
|
42
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
43
|
+
# @option attributes [String] :name The value to assign to the {#name} property
|
|
44
|
+
# @option attributes [String] :description The value to assign to the {#description} property
|
|
45
|
+
def initialize(attributes = {})
|
|
46
|
+
return unless attributes.is_a?(Hash)
|
|
47
|
+
|
|
48
|
+
# convert string to symbol for hash key
|
|
49
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
|
50
|
+
|
|
51
|
+
self.name = attributes[:'name'] if attributes[:'name']
|
|
52
|
+
|
|
53
|
+
self.description = attributes[:'description'] if attributes[:'description']
|
|
54
|
+
end
|
|
55
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity
|
|
56
|
+
# rubocop:enable Metrics/MethodLength, Layout/EmptyLines, Style/SymbolLiteral
|
|
57
|
+
|
|
58
|
+
# rubocop:disable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity, Layout/EmptyLines
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
# Checks equality by comparing each attribute.
|
|
62
|
+
# @param [Object] other the other object to be compared
|
|
63
|
+
def ==(other)
|
|
64
|
+
return true if equal?(other)
|
|
65
|
+
|
|
66
|
+
self.class == other.class &&
|
|
67
|
+
name == other.name &&
|
|
68
|
+
description == other.description
|
|
69
|
+
end
|
|
70
|
+
# rubocop:enable Metrics/CyclomaticComplexity, Metrics/AbcSize, Metrics/PerceivedComplexity, Layout/EmptyLines
|
|
71
|
+
|
|
72
|
+
# @see the `==` method
|
|
73
|
+
# @param [Object] other the other object to be compared
|
|
74
|
+
def eql?(other)
|
|
75
|
+
self == other
|
|
76
|
+
end
|
|
77
|
+
|
|
78
|
+
# rubocop:disable Metrics/AbcSize, Layout/EmptyLines
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
# Calculates hash code according to all attributes.
|
|
82
|
+
# @return [Fixnum] Hash code
|
|
83
|
+
def hash
|
|
84
|
+
[name, description].hash
|
|
85
|
+
end
|
|
86
|
+
# rubocop:enable Metrics/AbcSize, Layout/EmptyLines
|
|
87
|
+
|
|
88
|
+
# rubocop:disable Metrics/AbcSize, Layout/EmptyLines
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
# Builds the object from hash
|
|
92
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
93
|
+
# @return [Object] Returns the model itself
|
|
94
|
+
def build_from_hash(attributes)
|
|
95
|
+
return nil unless attributes.is_a?(Hash)
|
|
96
|
+
|
|
97
|
+
self.class.swagger_types.each_pair do |key, type|
|
|
98
|
+
if type =~ /^Array<(.*)>/i
|
|
99
|
+
# check to ensure the input is an array given that the the attribute
|
|
100
|
+
# is documented as an array but the input is not
|
|
101
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
102
|
+
public_method("#{key}=").call(
|
|
103
|
+
attributes[self.class.attribute_map[key]]
|
|
104
|
+
.map { |v| OCI::Internal::Util.convert_to_type(Regexp.last_match(1), v) }
|
|
105
|
+
)
|
|
106
|
+
end
|
|
107
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
108
|
+
public_method("#{key}=").call(
|
|
109
|
+
OCI::Internal::Util.convert_to_type(type, attributes[self.class.attribute_map[key]])
|
|
110
|
+
)
|
|
111
|
+
end
|
|
112
|
+
# or else data not found in attributes(hash), not an issue as the data can be optional
|
|
113
|
+
end
|
|
114
|
+
|
|
115
|
+
self
|
|
116
|
+
end
|
|
117
|
+
# rubocop:enable Metrics/AbcSize, Layout/EmptyLines
|
|
118
|
+
|
|
119
|
+
# Returns the string representation of the object
|
|
120
|
+
# @return [String] String presentation of the object
|
|
121
|
+
def to_s
|
|
122
|
+
to_hash.to_s
|
|
123
|
+
end
|
|
124
|
+
|
|
125
|
+
# Returns the object in the form of hash
|
|
126
|
+
# @return [Hash] Returns the object in the form of hash
|
|
127
|
+
def to_hash
|
|
128
|
+
hash = {}
|
|
129
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
130
|
+
value = public_method(attr).call
|
|
131
|
+
next if value.nil? && !instance_variable_defined?("@#{attr}")
|
|
132
|
+
|
|
133
|
+
hash[param] = _to_hash(value)
|
|
134
|
+
end
|
|
135
|
+
hash
|
|
136
|
+
end
|
|
137
|
+
|
|
138
|
+
private
|
|
139
|
+
|
|
140
|
+
# Outputs non-array value in the form of hash
|
|
141
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
142
|
+
# @param [Object] value Any valid value
|
|
143
|
+
# @return [Hash] Returns the value in the form of hash
|
|
144
|
+
def _to_hash(value)
|
|
145
|
+
if value.is_a?(Array)
|
|
146
|
+
value.compact.map { |v| _to_hash(v) }
|
|
147
|
+
elsif value.is_a?(Hash)
|
|
148
|
+
{}.tap do |hash|
|
|
149
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
150
|
+
end
|
|
151
|
+
elsif value.respond_to? :to_hash
|
|
152
|
+
value.to_hash
|
|
153
|
+
else
|
|
154
|
+
value
|
|
155
|
+
end
|
|
156
|
+
end
|
|
157
|
+
end
|
|
158
|
+
end
|
|
159
|
+
# rubocop:enable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
|
@@ -10,7 +10,7 @@ module OCI
|
|
|
10
10
|
# @return [String]
|
|
11
11
|
attr_accessor :description
|
|
12
12
|
|
|
13
|
-
# An array of quota statements written in the declarative language.
|
|
13
|
+
# An array of quota statements written in the declarative quota statement language.
|
|
14
14
|
#
|
|
15
15
|
# @return [Array<String>]
|
|
16
16
|
attr_accessor :statements
|
|
@@ -5,7 +5,7 @@ require 'logger'
|
|
|
5
5
|
|
|
6
6
|
# rubocop:disable Lint/UnneededCopDisableDirective, Metrics/LineLength
|
|
7
7
|
module OCI
|
|
8
|
-
# APIs
|
|
8
|
+
# APIs that interact with the resource limits of a specific resource type
|
|
9
9
|
class Limits::QuotasClient
|
|
10
10
|
# Client used to make HTTP requests.
|
|
11
11
|
# @return [OCI::ApiClient]
|
|
@@ -76,7 +76,7 @@ module OCI
|
|
|
76
76
|
@retry_config = retry_config
|
|
77
77
|
|
|
78
78
|
if endpoint
|
|
79
|
-
@endpoint = endpoint + '/
|
|
79
|
+
@endpoint = endpoint + '/'
|
|
80
80
|
else
|
|
81
81
|
region ||= config.region
|
|
82
82
|
region ||= signer.region if signer.respond_to?(:region)
|
|
@@ -94,7 +94,7 @@ module OCI
|
|
|
94
94
|
|
|
95
95
|
raise 'A region must be specified.' unless @region
|
|
96
96
|
|
|
97
|
-
@endpoint = OCI::Regions.get_service_endpoint_for_template(@region, 'https://limits.{region}.oci.{secondLevelDomain}') + '/
|
|
97
|
+
@endpoint = OCI::Regions.get_service_endpoint_for_template(@region, 'https://limits.{region}.oci.{secondLevelDomain}') + '/'
|
|
98
98
|
logger.info "QuotasClient endpoint set to '#{@endpoint} from region #{@region}'." if logger
|
|
99
99
|
end
|
|
100
100
|
|
|
@@ -128,7 +128,7 @@ module OCI
|
|
|
128
128
|
|
|
129
129
|
raise "Missing the required parameter 'create_quota_details' when calling create_quota." if create_quota_details.nil?
|
|
130
130
|
|
|
131
|
-
path = '/quotas/'
|
|
131
|
+
path = '/20181025/quotas/'
|
|
132
132
|
operation_signing_strategy = :standard
|
|
133
133
|
|
|
134
134
|
# rubocop:disable Style/NegatedIf
|
|
@@ -189,7 +189,7 @@ module OCI
|
|
|
189
189
|
raise "Missing the required parameter 'quota_id' when calling delete_quota." if quota_id.nil?
|
|
190
190
|
raise "Parameter value for 'quota_id' must not be blank" if OCI::Internal::Util.blank_string?(quota_id)
|
|
191
191
|
|
|
192
|
-
path = '/quotas/{quotaId}'.sub('{quotaId}', quota_id.to_s)
|
|
192
|
+
path = '/20181025/quotas/{quotaId}'.sub('{quotaId}', quota_id.to_s)
|
|
193
193
|
operation_signing_strategy = :standard
|
|
194
194
|
|
|
195
195
|
# rubocop:disable Style/NegatedIf
|
|
@@ -244,7 +244,7 @@ module OCI
|
|
|
244
244
|
raise "Missing the required parameter 'quota_id' when calling get_quota." if quota_id.nil?
|
|
245
245
|
raise "Parameter value for 'quota_id' must not be blank" if OCI::Internal::Util.blank_string?(quota_id)
|
|
246
246
|
|
|
247
|
-
path = '/quotas/{quotaId}'.sub('{quotaId}', quota_id.to_s)
|
|
247
|
+
path = '/20181025/quotas/{quotaId}'.sub('{quotaId}', quota_id.to_s)
|
|
248
248
|
operation_signing_strategy = :standard
|
|
249
249
|
|
|
250
250
|
# rubocop:disable Style/NegatedIf
|
|
@@ -293,14 +293,15 @@ module OCI
|
|
|
293
293
|
# @option opts [String] :page The value of the `opc-next-page` response header from the previous \"List\" call.
|
|
294
294
|
#
|
|
295
295
|
# @option opts [Integer] :limit The maximum number of items to return in a paginated \"List\" call.
|
|
296
|
-
#
|
|
296
|
+
# (default to 25)
|
|
297
297
|
# @option opts [String] :name name
|
|
298
298
|
# @option opts [String] :lifecycle_state Filters returned quotas based on whether the given state.
|
|
299
299
|
# Allowed values are: ACTIVE
|
|
300
|
-
# @option opts [String] :sort_order The sort order to use, either 'asc' or 'desc'.
|
|
300
|
+
# @option opts [String] :sort_order The sort order to use, either 'asc' or 'desc'. By default it will be ascending.
|
|
301
|
+
# (default to ASC)
|
|
301
302
|
# Allowed values are: ASC, DESC
|
|
302
303
|
# @option opts [String] :sort_by The field to sort by. Only one sort order may be provided. Time created is default ordered as descending. Display name is default ordered as ascending.
|
|
303
|
-
#
|
|
304
|
+
# (default to NAME)
|
|
304
305
|
# Allowed values are: NAME, TIMECREATED
|
|
305
306
|
# @option opts [String] :opc_request_id Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a
|
|
306
307
|
# particular request, please provide the request ID.
|
|
@@ -323,7 +324,7 @@ module OCI
|
|
|
323
324
|
raise 'Invalid value for "sort_by", must be one of NAME, TIMECREATED.'
|
|
324
325
|
end
|
|
325
326
|
|
|
326
|
-
path = '/quotas/'
|
|
327
|
+
path = '/20181025/quotas/'
|
|
327
328
|
operation_signing_strategy = :standard
|
|
328
329
|
|
|
329
330
|
# rubocop:disable Style/NegatedIf
|
|
@@ -391,7 +392,7 @@ module OCI
|
|
|
391
392
|
raise "Missing the required parameter 'update_quota_details' when calling update_quota." if update_quota_details.nil?
|
|
392
393
|
raise "Parameter value for 'quota_id' must not be blank" if OCI::Internal::Util.blank_string?(quota_id)
|
|
393
394
|
|
|
394
|
-
path = '/quotas/{quotaId}'.sub('{quotaId}', quota_id.to_s)
|
|
395
|
+
path = '/20181025/quotas/{quotaId}'.sub('{quotaId}', quota_id.to_s)
|
|
395
396
|
operation_signing_strategy = :standard
|
|
396
397
|
|
|
397
398
|
# rubocop:disable Style/NegatedIf
|
|
@@ -76,6 +76,15 @@ module OCI
|
|
|
76
76
|
# @return [String]
|
|
77
77
|
attr_accessor :namespace
|
|
78
78
|
|
|
79
|
+
# Resource group specified as a filter for metric data retrieved by the alarm. A resource group is a custom string that can be used as a filter. Only one resource group can be applied per metric.
|
|
80
|
+
# A valid resourceGroup value starts with an alphabetical character and includes only alphanumeric characters, periods (.), underscores (_), hyphens (-), and dollar signs ($).
|
|
81
|
+
# Avoid entering confidential information.
|
|
82
|
+
#
|
|
83
|
+
# Example: `frontend-fleet`
|
|
84
|
+
#
|
|
85
|
+
# @return [String]
|
|
86
|
+
attr_accessor :resource_group
|
|
87
|
+
|
|
79
88
|
# **[Required]** The Monitoring Query Language (MQL) expression to evaluate for the alarm. The Alarms feature of
|
|
80
89
|
# the Monitoring service interprets results for each returned time series as Boolean values,
|
|
81
90
|
# where zero represents false and a non-zero value represents true. A true value means that the trigger
|
|
@@ -218,6 +227,7 @@ module OCI
|
|
|
218
227
|
'metric_compartment_id': :'metricCompartmentId',
|
|
219
228
|
'metric_compartment_id_in_subtree': :'metricCompartmentIdInSubtree',
|
|
220
229
|
'namespace': :'namespace',
|
|
230
|
+
'resource_group': :'resourceGroup',
|
|
221
231
|
'query': :'query',
|
|
222
232
|
'resolution': :'resolution',
|
|
223
233
|
'pending_duration': :'pendingDuration',
|
|
@@ -246,6 +256,7 @@ module OCI
|
|
|
246
256
|
'metric_compartment_id': :'String',
|
|
247
257
|
'metric_compartment_id_in_subtree': :'BOOLEAN',
|
|
248
258
|
'namespace': :'String',
|
|
259
|
+
'resource_group': :'String',
|
|
249
260
|
'query': :'String',
|
|
250
261
|
'resolution': :'String',
|
|
251
262
|
'pending_duration': :'String',
|
|
@@ -276,6 +287,7 @@ module OCI
|
|
|
276
287
|
# @option attributes [String] :metric_compartment_id The value to assign to the {#metric_compartment_id} property
|
|
277
288
|
# @option attributes [BOOLEAN] :metric_compartment_id_in_subtree The value to assign to the {#metric_compartment_id_in_subtree} property
|
|
278
289
|
# @option attributes [String] :namespace The value to assign to the {#namespace} property
|
|
290
|
+
# @option attributes [String] :resource_group The value to assign to the {#resource_group} property
|
|
279
291
|
# @option attributes [String] :query The value to assign to the {#query} property
|
|
280
292
|
# @option attributes [String] :resolution The value to assign to the {#resolution} property
|
|
281
293
|
# @option attributes [String] :pending_duration The value to assign to the {#pending_duration} property
|
|
@@ -324,6 +336,12 @@ module OCI
|
|
|
324
336
|
|
|
325
337
|
self.namespace = attributes[:'namespace'] if attributes[:'namespace']
|
|
326
338
|
|
|
339
|
+
self.resource_group = attributes[:'resourceGroup'] if attributes[:'resourceGroup']
|
|
340
|
+
|
|
341
|
+
raise 'You cannot provide both :resourceGroup and :resource_group' if attributes.key?(:'resourceGroup') && attributes.key?(:'resource_group')
|
|
342
|
+
|
|
343
|
+
self.resource_group = attributes[:'resource_group'] if attributes[:'resource_group']
|
|
344
|
+
|
|
327
345
|
self.query = attributes[:'query'] if attributes[:'query']
|
|
328
346
|
|
|
329
347
|
self.resolution = attributes[:'resolution'] if attributes[:'resolution']
|
|
@@ -428,6 +446,7 @@ module OCI
|
|
|
428
446
|
metric_compartment_id == other.metric_compartment_id &&
|
|
429
447
|
metric_compartment_id_in_subtree == other.metric_compartment_id_in_subtree &&
|
|
430
448
|
namespace == other.namespace &&
|
|
449
|
+
resource_group == other.resource_group &&
|
|
431
450
|
query == other.query &&
|
|
432
451
|
resolution == other.resolution &&
|
|
433
452
|
pending_duration == other.pending_duration &&
|
|
@@ -457,7 +476,7 @@ module OCI
|
|
|
457
476
|
# Calculates hash code according to all attributes.
|
|
458
477
|
# @return [Fixnum] Hash code
|
|
459
478
|
def hash
|
|
460
|
-
[id, display_name, compartment_id, metric_compartment_id, metric_compartment_id_in_subtree, namespace, query, resolution, pending_duration, severity, body, destinations, repeat_notification_duration, suppression, is_enabled, freeform_tags, defined_tags, lifecycle_state, time_created, time_updated].hash
|
|
479
|
+
[id, display_name, compartment_id, metric_compartment_id, metric_compartment_id_in_subtree, namespace, resource_group, query, resolution, pending_duration, severity, body, destinations, repeat_notification_duration, suppression, is_enabled, freeform_tags, defined_tags, lifecycle_state, time_created, time_updated].hash
|
|
461
480
|
end
|
|
462
481
|
# rubocop:enable Metrics/AbcSize, Layout/EmptyLines
|
|
463
482
|
|