azure_mgmt_monitor 0.17.6 → 0.18.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/2015-04-01/generated/azure_mgmt_monitor.rb +11 -8
- data/lib/2015-04-01/generated/azure_mgmt_monitor/activity_logs.rb +24 -19
- data/lib/2015-04-01/generated/azure_mgmt_monitor/models/metric_trigger.rb +35 -1
- data/lib/2015-04-01/generated/azure_mgmt_monitor/models/recurrence.rb +9 -9
- data/lib/2015-04-01/generated/azure_mgmt_monitor/models/recurrence_frequency.rb +22 -0
- data/lib/2015-04-01/generated/azure_mgmt_monitor/models/recurrent_schedule.rb +1 -1
- data/lib/2015-04-01/generated/azure_mgmt_monitor/models/scale_rule_metric_dimension.rb +80 -0
- data/lib/2015-04-01/generated/azure_mgmt_monitor/models/scale_rule_metric_dimension_operation_type.rb +16 -0
- data/lib/2015-04-01/generated/azure_mgmt_monitor/models/time_aggregation_type.rb +1 -0
- data/lib/2015-04-01/generated/azure_mgmt_monitor/models/time_window.rb +1 -1
- data/lib/2015-04-01/generated/azure_mgmt_monitor/monitor_management_client.rb +1 -1
- data/lib/2015-05-01/generated/azure_mgmt_monitor/application_insights_management_client.rb +1 -1
- data/lib/2016-03-01/generated/azure_mgmt_monitor.rb +14 -14
- data/lib/2016-03-01/generated/azure_mgmt_monitor/alert_rules.rb +21 -21
- data/lib/2016-03-01/generated/azure_mgmt_monitor/monitor_management_client.rb +5 -5
- data/lib/2016-09-01/generated/azure_mgmt_monitor/monitor_client.rb +1 -1
- data/lib/2017-04-01/generated/azure_mgmt_monitor/monitor_management_client.rb +1 -1
- data/lib/2017-05-01-preview/generated/azure_mgmt_monitor.rb +16 -11
- data/lib/2017-05-01-preview/generated/azure_mgmt_monitor/models/diagnostic_settings_resource.rb +19 -5
- data/lib/2017-05-01-preview/generated/azure_mgmt_monitor/models/response.rb +1 -1
- data/lib/2017-05-01-preview/generated/azure_mgmt_monitor/models/subscription_diagnostic_settings_resource.rb +150 -0
- data/lib/2017-05-01-preview/generated/azure_mgmt_monitor/models/subscription_diagnostic_settings_resource_collection.rb +57 -0
- data/lib/2017-05-01-preview/generated/azure_mgmt_monitor/models/subscription_log_settings.rb +59 -0
- data/lib/2017-05-01-preview/generated/azure_mgmt_monitor/models/subscription_proxy_only_resource.rb +82 -0
- data/lib/2017-05-01-preview/generated/azure_mgmt_monitor/monitor_management_client.rb +10 -5
- data/lib/2017-05-01-preview/generated/azure_mgmt_monitor/subscription_diagnostic_settings_operations.rb +405 -0
- data/lib/2017-10-01-preview/generated/azure_mgmt_monitor/application_insights_management_client.rb +1 -1
- data/lib/2017-11-01-preview/generated/azure_mgmt_monitor/models/baseline_response.rb +1 -1
- data/lib/2017-11-01-preview/generated/azure_mgmt_monitor/models/calculate_baseline_response.rb +1 -1
- data/lib/2017-11-01-preview/generated/azure_mgmt_monitor/monitor_management_client.rb +1 -1
- data/lib/2017-12-01-preview/generated/azure_mgmt_monitor/metric_namespaces.rb +1 -1
- data/lib/2017-12-01-preview/generated/azure_mgmt_monitor/monitor_management_client.rb +1 -1
- data/lib/2018-01-01/generated/azure_mgmt_monitor/models/metric.rb +2 -1
- data/lib/2018-01-01/generated/azure_mgmt_monitor/models/metric_definition.rb +3 -2
- data/lib/2018-01-01/generated/azure_mgmt_monitor/models/metric_value.rb +3 -4
- data/lib/2018-01-01/generated/azure_mgmt_monitor/models/response.rb +1 -1
- data/lib/2018-01-01/generated/azure_mgmt_monitor/models/unit.rb +4 -0
- data/lib/2018-01-01/generated/azure_mgmt_monitor/monitor_management_client.rb +1 -1
- data/lib/2018-03-01/generated/azure_mgmt_monitor.rb +25 -17
- data/lib/2018-03-01/generated/azure_mgmt_monitor/metric_alerts.rb +10 -10
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/dynamic_metric_criteria.rb +175 -0
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/dynamic_threshold_failing_periods.rb +61 -0
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/dynamic_threshold_operator.rb +17 -0
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/dynamic_threshold_sensitivity.rb +17 -0
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/metric_alert_action.rb +3 -3
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/metric_alert_criteria.rb +2 -0
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/metric_alert_multiple_resource_multiple_metric_criteria.rb +90 -0
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/metric_alert_resource.rb +27 -1
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/metric_alert_resource_patch.rb +27 -1
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/metric_criteria.rb +56 -31
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/metric_dimension.rb +2 -1
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/multi_metric_criteria.rb +142 -0
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/operator.rb +20 -0
- data/lib/2018-03-01/generated/azure_mgmt_monitor/models/webtest_location_availability_criteria.rb +98 -0
- data/lib/2018-03-01/generated/azure_mgmt_monitor/monitor_management_client.rb +5 -5
- data/lib/2018-04-16/generated/azure_mgmt_monitor.rb +8 -5
- data/lib/2018-04-16/generated/azure_mgmt_monitor/models/action.rb +1 -0
- data/lib/2018-04-16/generated/azure_mgmt_monitor/models/alerting_action.rb +2 -2
- data/lib/2018-04-16/generated/azure_mgmt_monitor/models/az_ns_action_group.rb +1 -1
- data/lib/2018-04-16/generated/azure_mgmt_monitor/models/criteria.rb +66 -0
- data/lib/2018-04-16/generated/azure_mgmt_monitor/models/dimension.rb +79 -0
- data/lib/2018-04-16/generated/azure_mgmt_monitor/models/log_search_rule_resource.rb +4 -3
- data/lib/2018-04-16/generated/azure_mgmt_monitor/models/log_to_metric_action.rb +71 -0
- data/lib/2018-04-16/generated/azure_mgmt_monitor/models/source.rb +3 -2
- data/lib/2018-04-16/generated/azure_mgmt_monitor/monitor_client.rb +1 -1
- data/lib/2018-06-01-preview/generated/azure_mgmt_monitor/monitor_management_client.rb +1 -1
- data/lib/2018-06-17-preview/generated/azure_mgmt_monitor/application_insights_management_client.rb +1 -1
- data/lib/2018-09-01/generated/azure_mgmt_monitor/monitor_management_client.rb +1 -1
- data/lib/2018-11-27-preview/generated/azure_mgmt_monitor/monitor_management_client.rb +1 -1
- data/lib/2018-11-27-preview/generated/azure_mgmt_monitor/vminsights.rb +1 -1
- data/lib/2019-03-01/generated/azure_mgmt_monitor.rb +18 -9
- data/lib/2019-03-01/generated/azure_mgmt_monitor/action_groups.rb +1 -1
- data/lib/2019-03-01/generated/azure_mgmt_monitor/baselines.rb +186 -0
- data/lib/2019-03-01/generated/azure_mgmt_monitor/models/baseline_metadata.rb +57 -0
- data/lib/2019-03-01/generated/azure_mgmt_monitor/models/baseline_sensitivity.rb +17 -0
- data/lib/2019-03-01/generated/azure_mgmt_monitor/models/metric_baselines_response.rb +55 -0
- data/lib/2019-03-01/generated/azure_mgmt_monitor/models/metric_single_dimension.rb +57 -0
- data/lib/2019-03-01/generated/azure_mgmt_monitor/models/result_type.rb +16 -0
- data/lib/2019-03-01/generated/azure_mgmt_monitor/models/single_baseline.rb +85 -0
- data/lib/2019-03-01/generated/azure_mgmt_monitor/models/single_metric_baseline.rb +129 -0
- data/lib/2019-03-01/generated/azure_mgmt_monitor/models/time_series_baseline.rb +127 -0
- data/lib/2019-03-01/generated/azure_mgmt_monitor/monitor_management_client.rb +5 -1
- data/lib/2019-06-01/generated/azure_mgmt_monitor.rb +45 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/action_groups.rb +707 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/action_group_list.rb +67 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/action_group_patch_body.rb +68 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/action_group_resource.rb +326 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/arm_role_receiver.rb +69 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/automation_runbook_receiver.rb +113 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/azure_app_push_receiver.rb +58 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/azure_function_receiver.rb +91 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/email_receiver.rb +83 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/enable_request.rb +46 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/error_response.rb +57 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/itsm_receiver.rb +94 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/logic_app_receiver.rb +80 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/receiver_status.rb +17 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/resource.rb +110 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/sms_receiver.rb +83 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/voice_receiver.rb +69 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/models/webhook_receiver.rb +115 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/module_definition.rb +9 -0
- data/lib/2019-06-01/generated/azure_mgmt_monitor/monitor_management_client.rb +131 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor.rb +49 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/azure_monitor_private_link_scope.rb +123 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/azure_monitor_private_link_scope_list_result.rb +102 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/error_additional_info.rb +59 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/error_response.rb +57 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/error_response_common.rb +93 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/operation_status.rb +102 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/private_endpoint_connection.rb +100 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/private_endpoint_connection_list_result.rb +100 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/private_endpoint_property.rb +46 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/private_link_resource.rb +95 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/private_link_resource_list_result.rb +100 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/private_link_scopes_resource.rb +101 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/private_link_service_connection_state_property.rb +71 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/proxy_resource.rb +71 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/scoped_resource.rb +85 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/scoped_resource_list_result.rb +100 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/tags_resource.rb +55 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/module_definition.rb +9 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/monitor_management_client.rb +148 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/private_endpoint_connections.rb +641 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/private_link_resources.rb +346 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/private_link_scope_operation_status.rb +122 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/private_link_scoped_resources.rb +638 -0
- data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/private_link_scopes.rb +889 -0
- data/lib/azure_mgmt_monitor.rb +13 -11
- data/lib/profiles/latest/modules/monitor_profile_module.rb +322 -132
- data/lib/profiles/v2019_03_01_hybrid/modules/monitor_profile_module.rb +65 -35
- data/lib/version.rb +1 -1
- metadata +77 -3
@@ -0,0 +1,115 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator.
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::Monitor::Mgmt::V2019_06_01
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# A webhook receiver.
|
10
|
+
#
|
11
|
+
class WebhookReceiver
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
# @return [String] The name of the webhook receiver. Names must be unique
|
16
|
+
# across all receivers within an action group.
|
17
|
+
attr_accessor :name
|
18
|
+
|
19
|
+
# @return [String] The URI where webhooks should be sent.
|
20
|
+
attr_accessor :service_uri
|
21
|
+
|
22
|
+
# @return [Boolean] Indicates whether to use common alert schema.
|
23
|
+
attr_accessor :use_common_alert_schema
|
24
|
+
|
25
|
+
# @return [Boolean] Indicates whether or not use AAD authentication.
|
26
|
+
# Default value: false .
|
27
|
+
attr_accessor :use_aad_auth
|
28
|
+
|
29
|
+
# @return [String] Indicates the webhook app object Id for aad auth.
|
30
|
+
attr_accessor :object_id
|
31
|
+
|
32
|
+
# @return [String] Indicates the identifier uri for aad auth.
|
33
|
+
attr_accessor :identifier_uri
|
34
|
+
|
35
|
+
# @return [String] Indicates the tenant id for aad auth.
|
36
|
+
attr_accessor :tenant_id
|
37
|
+
|
38
|
+
|
39
|
+
#
|
40
|
+
# Mapper for WebhookReceiver class as Ruby Hash.
|
41
|
+
# This will be used for serialization/deserialization.
|
42
|
+
#
|
43
|
+
def self.mapper()
|
44
|
+
{
|
45
|
+
client_side_validation: true,
|
46
|
+
required: false,
|
47
|
+
serialized_name: 'WebhookReceiver',
|
48
|
+
type: {
|
49
|
+
name: 'Composite',
|
50
|
+
class_name: 'WebhookReceiver',
|
51
|
+
model_properties: {
|
52
|
+
name: {
|
53
|
+
client_side_validation: true,
|
54
|
+
required: true,
|
55
|
+
serialized_name: 'name',
|
56
|
+
type: {
|
57
|
+
name: 'String'
|
58
|
+
}
|
59
|
+
},
|
60
|
+
service_uri: {
|
61
|
+
client_side_validation: true,
|
62
|
+
required: true,
|
63
|
+
serialized_name: 'serviceUri',
|
64
|
+
type: {
|
65
|
+
name: 'String'
|
66
|
+
}
|
67
|
+
},
|
68
|
+
use_common_alert_schema: {
|
69
|
+
client_side_validation: true,
|
70
|
+
required: true,
|
71
|
+
serialized_name: 'useCommonAlertSchema',
|
72
|
+
type: {
|
73
|
+
name: 'Boolean'
|
74
|
+
}
|
75
|
+
},
|
76
|
+
use_aad_auth: {
|
77
|
+
client_side_validation: true,
|
78
|
+
required: false,
|
79
|
+
serialized_name: 'useAadAuth',
|
80
|
+
default_value: false,
|
81
|
+
type: {
|
82
|
+
name: 'Boolean'
|
83
|
+
}
|
84
|
+
},
|
85
|
+
object_id: {
|
86
|
+
client_side_validation: true,
|
87
|
+
required: false,
|
88
|
+
serialized_name: 'objectId',
|
89
|
+
type: {
|
90
|
+
name: 'String'
|
91
|
+
}
|
92
|
+
},
|
93
|
+
identifier_uri: {
|
94
|
+
client_side_validation: true,
|
95
|
+
required: false,
|
96
|
+
serialized_name: 'identifierUri',
|
97
|
+
type: {
|
98
|
+
name: 'String'
|
99
|
+
}
|
100
|
+
},
|
101
|
+
tenant_id: {
|
102
|
+
client_side_validation: true,
|
103
|
+
required: false,
|
104
|
+
serialized_name: 'tenantId',
|
105
|
+
type: {
|
106
|
+
name: 'String'
|
107
|
+
}
|
108
|
+
}
|
109
|
+
}
|
110
|
+
}
|
111
|
+
}
|
112
|
+
end
|
113
|
+
end
|
114
|
+
end
|
115
|
+
end
|
@@ -0,0 +1,9 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator.
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure end
|
7
|
+
module Azure::Monitor end
|
8
|
+
module Azure::Monitor::Mgmt end
|
9
|
+
module Azure::Monitor::Mgmt::V2019_06_01 end
|
@@ -0,0 +1,131 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator.
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::Monitor::Mgmt::V2019_06_01
|
7
|
+
#
|
8
|
+
# A service client - single point of access to the REST API.
|
9
|
+
#
|
10
|
+
class MonitorManagementClient < MsRestAzure::AzureServiceClient
|
11
|
+
include MsRestAzure
|
12
|
+
include MsRestAzure::Serialization
|
13
|
+
|
14
|
+
# @return [String] the base URI of the service.
|
15
|
+
attr_accessor :base_url
|
16
|
+
|
17
|
+
# @return Credentials needed for the client to connect to Azure.
|
18
|
+
attr_reader :credentials
|
19
|
+
|
20
|
+
# @return [String] The Azure subscription Id.
|
21
|
+
attr_accessor :subscription_id
|
22
|
+
|
23
|
+
# @return [String] Client Api Version.
|
24
|
+
attr_reader :api_version
|
25
|
+
|
26
|
+
# @return [String] The preferred language for the response.
|
27
|
+
attr_accessor :accept_language
|
28
|
+
|
29
|
+
# @return [Integer] The retry timeout in seconds for Long Running
|
30
|
+
# Operations. Default value is 30.
|
31
|
+
attr_accessor :long_running_operation_retry_timeout
|
32
|
+
|
33
|
+
# @return [Boolean] Whether a unique x-ms-client-request-id should be
|
34
|
+
# generated. When set to true a unique x-ms-client-request-id value is
|
35
|
+
# generated and included in each request. Default is true.
|
36
|
+
attr_accessor :generate_client_request_id
|
37
|
+
|
38
|
+
# @return [ActionGroups] action_groups
|
39
|
+
attr_reader :action_groups
|
40
|
+
|
41
|
+
#
|
42
|
+
# Creates initializes a new instance of the MonitorManagementClient class.
|
43
|
+
# @param credentials [MsRest::ServiceClientCredentials] credentials to authorize HTTP requests made by the service client.
|
44
|
+
# @param base_url [String] the base URI of the service.
|
45
|
+
# @param options [Array] filters to be applied to the HTTP requests.
|
46
|
+
#
|
47
|
+
def initialize(credentials = nil, base_url = nil, options = nil)
|
48
|
+
super(credentials, options)
|
49
|
+
@base_url = base_url || 'https://management.azure.com'
|
50
|
+
|
51
|
+
fail ArgumentError, 'invalid type of credentials input parameter' unless credentials.is_a?(MsRest::ServiceClientCredentials) unless credentials.nil?
|
52
|
+
@credentials = credentials
|
53
|
+
|
54
|
+
@action_groups = ActionGroups.new(self)
|
55
|
+
@api_version = '2019-06-01'
|
56
|
+
@accept_language = 'en-US'
|
57
|
+
@long_running_operation_retry_timeout = 30
|
58
|
+
@generate_client_request_id = true
|
59
|
+
add_telemetry
|
60
|
+
end
|
61
|
+
|
62
|
+
#
|
63
|
+
# Makes a request and returns the body of the response.
|
64
|
+
# @param method [Symbol] with any of the following values :get, :put, :post, :patch, :delete.
|
65
|
+
# @param path [String] the path, relative to {base_url}.
|
66
|
+
# @param options [Hash{String=>String}] specifying any request options like :body.
|
67
|
+
# @return [Hash{String=>String}] containing the body of the response.
|
68
|
+
# Example:
|
69
|
+
#
|
70
|
+
# request_content = "{'location':'westus','tags':{'tag1':'val1','tag2':'val2'}}"
|
71
|
+
# path = "/path"
|
72
|
+
# options = {
|
73
|
+
# body: request_content,
|
74
|
+
# query_params: {'api-version' => '2016-02-01'}
|
75
|
+
# }
|
76
|
+
# result = @client.make_request(:put, path, options)
|
77
|
+
#
|
78
|
+
def make_request(method, path, options = {})
|
79
|
+
result = make_request_with_http_info(method, path, options)
|
80
|
+
result.body unless result.nil?
|
81
|
+
end
|
82
|
+
|
83
|
+
#
|
84
|
+
# Makes a request and returns the operation response.
|
85
|
+
# @param method [Symbol] with any of the following values :get, :put, :post, :patch, :delete.
|
86
|
+
# @param path [String] the path, relative to {base_url}.
|
87
|
+
# @param options [Hash{String=>String}] specifying any request options like :body.
|
88
|
+
# @return [MsRestAzure::AzureOperationResponse] Operation response containing the request, response and status.
|
89
|
+
#
|
90
|
+
def make_request_with_http_info(method, path, options = {})
|
91
|
+
result = make_request_async(method, path, options).value!
|
92
|
+
result.body = result.response.body.to_s.empty? ? nil : JSON.load(result.response.body)
|
93
|
+
result
|
94
|
+
end
|
95
|
+
|
96
|
+
#
|
97
|
+
# Makes a request asynchronously.
|
98
|
+
# @param method [Symbol] with any of the following values :get, :put, :post, :patch, :delete.
|
99
|
+
# @param path [String] the path, relative to {base_url}.
|
100
|
+
# @param options [Hash{String=>String}] specifying any request options like :body.
|
101
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
102
|
+
#
|
103
|
+
def make_request_async(method, path, options = {})
|
104
|
+
fail ArgumentError, 'method is nil' if method.nil?
|
105
|
+
fail ArgumentError, 'path is nil' if path.nil?
|
106
|
+
|
107
|
+
request_url = options[:base_url] || @base_url
|
108
|
+
if(!options[:headers].nil? && !options[:headers]['Content-Type'].nil?)
|
109
|
+
@request_headers['Content-Type'] = options[:headers]['Content-Type']
|
110
|
+
end
|
111
|
+
|
112
|
+
request_headers = @request_headers
|
113
|
+
request_headers.merge!({'accept-language' => @accept_language}) unless @accept_language.nil?
|
114
|
+
options.merge!({headers: request_headers.merge(options[:headers] || {})})
|
115
|
+
options.merge!({credentials: @credentials}) unless @credentials.nil?
|
116
|
+
|
117
|
+
super(request_url, method, path, options)
|
118
|
+
end
|
119
|
+
|
120
|
+
|
121
|
+
private
|
122
|
+
#
|
123
|
+
# Adds telemetry information.
|
124
|
+
#
|
125
|
+
def add_telemetry
|
126
|
+
sdk_information = 'azure_mgmt_monitor'
|
127
|
+
sdk_information = "#{sdk_information}/0.18.0"
|
128
|
+
add_user_agent_information(sdk_information)
|
129
|
+
end
|
130
|
+
end
|
131
|
+
end
|
@@ -0,0 +1,49 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator.
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
require 'uri'
|
7
|
+
require 'cgi'
|
8
|
+
require 'date'
|
9
|
+
require 'json'
|
10
|
+
require 'base64'
|
11
|
+
require 'erb'
|
12
|
+
require 'securerandom'
|
13
|
+
require 'time'
|
14
|
+
require 'timeliness'
|
15
|
+
require 'faraday'
|
16
|
+
require 'faraday-cookie_jar'
|
17
|
+
require 'concurrent'
|
18
|
+
require 'ms_rest'
|
19
|
+
require '2019-10-17-preview/generated/azure_mgmt_monitor/module_definition'
|
20
|
+
require 'ms_rest_azure'
|
21
|
+
|
22
|
+
module Azure::Monitor::Mgmt::V2019_10_17_preview
|
23
|
+
autoload :PrivateLinkScopes, '2019-10-17-preview/generated/azure_mgmt_monitor/private_link_scopes.rb'
|
24
|
+
autoload :PrivateLinkScopeOperationStatus, '2019-10-17-preview/generated/azure_mgmt_monitor/private_link_scope_operation_status.rb'
|
25
|
+
autoload :PrivateLinkResources, '2019-10-17-preview/generated/azure_mgmt_monitor/private_link_resources.rb'
|
26
|
+
autoload :PrivateEndpointConnections, '2019-10-17-preview/generated/azure_mgmt_monitor/private_endpoint_connections.rb'
|
27
|
+
autoload :PrivateLinkScopedResources, '2019-10-17-preview/generated/azure_mgmt_monitor/private_link_scoped_resources.rb'
|
28
|
+
autoload :MonitorManagementClient, '2019-10-17-preview/generated/azure_mgmt_monitor/monitor_management_client.rb'
|
29
|
+
|
30
|
+
module Models
|
31
|
+
autoload :PrivateLinkServiceConnectionStateProperty, '2019-10-17-preview/generated/azure_mgmt_monitor/models/private_link_service_connection_state_property.rb'
|
32
|
+
autoload :ScopedResourceListResult, '2019-10-17-preview/generated/azure_mgmt_monitor/models/scoped_resource_list_result.rb'
|
33
|
+
autoload :ProxyResource, '2019-10-17-preview/generated/azure_mgmt_monitor/models/proxy_resource.rb'
|
34
|
+
autoload :OperationStatus, '2019-10-17-preview/generated/azure_mgmt_monitor/models/operation_status.rb'
|
35
|
+
autoload :TagsResource, '2019-10-17-preview/generated/azure_mgmt_monitor/models/tags_resource.rb'
|
36
|
+
autoload :AzureMonitorPrivateLinkScopeListResult, '2019-10-17-preview/generated/azure_mgmt_monitor/models/azure_monitor_private_link_scope_list_result.rb'
|
37
|
+
autoload :ErrorAdditionalInfo, '2019-10-17-preview/generated/azure_mgmt_monitor/models/error_additional_info.rb'
|
38
|
+
autoload :ErrorResponse, '2019-10-17-preview/generated/azure_mgmt_monitor/models/error_response.rb'
|
39
|
+
autoload :PrivateEndpointProperty, '2019-10-17-preview/generated/azure_mgmt_monitor/models/private_endpoint_property.rb'
|
40
|
+
autoload :PrivateLinkResourceListResult, '2019-10-17-preview/generated/azure_mgmt_monitor/models/private_link_resource_list_result.rb'
|
41
|
+
autoload :PrivateLinkScopesResource, '2019-10-17-preview/generated/azure_mgmt_monitor/models/private_link_scopes_resource.rb'
|
42
|
+
autoload :PrivateEndpointConnectionListResult, '2019-10-17-preview/generated/azure_mgmt_monitor/models/private_endpoint_connection_list_result.rb'
|
43
|
+
autoload :ErrorResponseCommon, '2019-10-17-preview/generated/azure_mgmt_monitor/models/error_response_common.rb'
|
44
|
+
autoload :PrivateEndpointConnection, '2019-10-17-preview/generated/azure_mgmt_monitor/models/private_endpoint_connection.rb'
|
45
|
+
autoload :AzureMonitorPrivateLinkScope, '2019-10-17-preview/generated/azure_mgmt_monitor/models/azure_monitor_private_link_scope.rb'
|
46
|
+
autoload :PrivateLinkResource, '2019-10-17-preview/generated/azure_mgmt_monitor/models/private_link_resource.rb'
|
47
|
+
autoload :ScopedResource, '2019-10-17-preview/generated/azure_mgmt_monitor/models/scoped_resource.rb'
|
48
|
+
end
|
49
|
+
end
|
data/lib/2019-10-17-preview/generated/azure_mgmt_monitor/models/azure_monitor_private_link_scope.rb
ADDED
@@ -0,0 +1,123 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator.
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::Monitor::Mgmt::V2019_10_17_preview
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# An Azure Monitor PrivateLinkScope definition.
|
10
|
+
#
|
11
|
+
class AzureMonitorPrivateLinkScope < PrivateLinkScopesResource
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
# @return [String] Current state of this PrivateLinkScope: whether or not
|
16
|
+
# is has been provisioned within the resource group it is defined. Users
|
17
|
+
# cannot change this value but are able to read from it. Values will
|
18
|
+
# include Provisioning ,Succeeded, Canceled and Failed.
|
19
|
+
attr_accessor :provisioning_state
|
20
|
+
|
21
|
+
# @return [Array<PrivateEndpointConnection>] List of private endpoint
|
22
|
+
# connections.
|
23
|
+
attr_accessor :private_endpoint_connections
|
24
|
+
|
25
|
+
|
26
|
+
#
|
27
|
+
# Mapper for AzureMonitorPrivateLinkScope class as Ruby Hash.
|
28
|
+
# This will be used for serialization/deserialization.
|
29
|
+
#
|
30
|
+
def self.mapper()
|
31
|
+
{
|
32
|
+
client_side_validation: true,
|
33
|
+
required: false,
|
34
|
+
serialized_name: 'AzureMonitorPrivateLinkScope',
|
35
|
+
type: {
|
36
|
+
name: 'Composite',
|
37
|
+
class_name: 'AzureMonitorPrivateLinkScope',
|
38
|
+
model_properties: {
|
39
|
+
id: {
|
40
|
+
client_side_validation: true,
|
41
|
+
required: false,
|
42
|
+
read_only: true,
|
43
|
+
serialized_name: 'id',
|
44
|
+
type: {
|
45
|
+
name: 'String'
|
46
|
+
}
|
47
|
+
},
|
48
|
+
name: {
|
49
|
+
client_side_validation: true,
|
50
|
+
required: false,
|
51
|
+
read_only: true,
|
52
|
+
serialized_name: 'name',
|
53
|
+
type: {
|
54
|
+
name: 'String'
|
55
|
+
}
|
56
|
+
},
|
57
|
+
type: {
|
58
|
+
client_side_validation: true,
|
59
|
+
required: false,
|
60
|
+
read_only: true,
|
61
|
+
serialized_name: 'type',
|
62
|
+
type: {
|
63
|
+
name: 'String'
|
64
|
+
}
|
65
|
+
},
|
66
|
+
location: {
|
67
|
+
client_side_validation: true,
|
68
|
+
required: true,
|
69
|
+
serialized_name: 'location',
|
70
|
+
type: {
|
71
|
+
name: 'String'
|
72
|
+
}
|
73
|
+
},
|
74
|
+
tags: {
|
75
|
+
client_side_validation: true,
|
76
|
+
required: false,
|
77
|
+
serialized_name: 'tags',
|
78
|
+
type: {
|
79
|
+
name: 'Dictionary',
|
80
|
+
value: {
|
81
|
+
client_side_validation: true,
|
82
|
+
required: false,
|
83
|
+
serialized_name: 'StringElementType',
|
84
|
+
type: {
|
85
|
+
name: 'String'
|
86
|
+
}
|
87
|
+
}
|
88
|
+
}
|
89
|
+
},
|
90
|
+
provisioning_state: {
|
91
|
+
client_side_validation: true,
|
92
|
+
required: false,
|
93
|
+
read_only: true,
|
94
|
+
serialized_name: 'properties.provisioningState',
|
95
|
+
type: {
|
96
|
+
name: 'String'
|
97
|
+
}
|
98
|
+
},
|
99
|
+
private_endpoint_connections: {
|
100
|
+
client_side_validation: true,
|
101
|
+
required: false,
|
102
|
+
read_only: true,
|
103
|
+
serialized_name: 'properties.privateEndpointConnections',
|
104
|
+
type: {
|
105
|
+
name: 'Sequence',
|
106
|
+
element: {
|
107
|
+
client_side_validation: true,
|
108
|
+
required: false,
|
109
|
+
serialized_name: 'PrivateEndpointConnectionElementType',
|
110
|
+
type: {
|
111
|
+
name: 'Composite',
|
112
|
+
class_name: 'PrivateEndpointConnection'
|
113
|
+
}
|
114
|
+
}
|
115
|
+
}
|
116
|
+
}
|
117
|
+
}
|
118
|
+
}
|
119
|
+
}
|
120
|
+
end
|
121
|
+
end
|
122
|
+
end
|
123
|
+
end
|
@@ -0,0 +1,102 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator.
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::Monitor::Mgmt::V2019_10_17_preview
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# Describes the list of Azure Monitor PrivateLinkScope resources.
|
10
|
+
#
|
11
|
+
class AzureMonitorPrivateLinkScopeListResult
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
include MsRest::JSONable
|
16
|
+
# @return [Array<AzureMonitorPrivateLinkScope>] List of Azure Monitor
|
17
|
+
# PrivateLinkScope definitions.
|
18
|
+
attr_accessor :value
|
19
|
+
|
20
|
+
# @return [String] The URI to get the next set of Azure Monitor
|
21
|
+
# PrivateLinkScope definitions if too many PrivateLinkScopes where
|
22
|
+
# returned in the result set.
|
23
|
+
attr_accessor :next_link
|
24
|
+
|
25
|
+
# return [Proc] with next page method call.
|
26
|
+
attr_accessor :next_method
|
27
|
+
|
28
|
+
#
|
29
|
+
# Gets the rest of the items for the request, enabling auto-pagination.
|
30
|
+
#
|
31
|
+
# @return [Array<AzureMonitorPrivateLinkScope>] operation results.
|
32
|
+
#
|
33
|
+
def get_all_items
|
34
|
+
items = @value
|
35
|
+
page = self
|
36
|
+
while page.next_link != nil && !page.next_link.strip.empty? do
|
37
|
+
page = page.get_next_page
|
38
|
+
items.concat(page.value)
|
39
|
+
end
|
40
|
+
items
|
41
|
+
end
|
42
|
+
|
43
|
+
#
|
44
|
+
# Gets the next page of results.
|
45
|
+
#
|
46
|
+
# @return [AzureMonitorPrivateLinkScopeListResult] with next page
|
47
|
+
# content.
|
48
|
+
#
|
49
|
+
def get_next_page
|
50
|
+
response = @next_method.call(@next_link).value! unless @next_method.nil?
|
51
|
+
unless response.nil?
|
52
|
+
@next_link = response.body.next_link
|
53
|
+
@value = response.body.value
|
54
|
+
self
|
55
|
+
end
|
56
|
+
end
|
57
|
+
|
58
|
+
#
|
59
|
+
# Mapper for AzureMonitorPrivateLinkScopeListResult class as Ruby Hash.
|
60
|
+
# This will be used for serialization/deserialization.
|
61
|
+
#
|
62
|
+
def self.mapper()
|
63
|
+
{
|
64
|
+
client_side_validation: true,
|
65
|
+
required: false,
|
66
|
+
serialized_name: 'AzureMonitorPrivateLinkScopeListResult',
|
67
|
+
type: {
|
68
|
+
name: 'Composite',
|
69
|
+
class_name: 'AzureMonitorPrivateLinkScopeListResult',
|
70
|
+
model_properties: {
|
71
|
+
value: {
|
72
|
+
client_side_validation: true,
|
73
|
+
required: true,
|
74
|
+
serialized_name: 'value',
|
75
|
+
type: {
|
76
|
+
name: 'Sequence',
|
77
|
+
element: {
|
78
|
+
client_side_validation: true,
|
79
|
+
required: false,
|
80
|
+
serialized_name: 'AzureMonitorPrivateLinkScopeElementType',
|
81
|
+
type: {
|
82
|
+
name: 'Composite',
|
83
|
+
class_name: 'AzureMonitorPrivateLinkScope'
|
84
|
+
}
|
85
|
+
}
|
86
|
+
}
|
87
|
+
},
|
88
|
+
next_link: {
|
89
|
+
client_side_validation: true,
|
90
|
+
required: false,
|
91
|
+
serialized_name: 'nextLink',
|
92
|
+
type: {
|
93
|
+
name: 'String'
|
94
|
+
}
|
95
|
+
}
|
96
|
+
}
|
97
|
+
}
|
98
|
+
}
|
99
|
+
end
|
100
|
+
end
|
101
|
+
end
|
102
|
+
end
|