azure_mgmt_sql 0.15.2 → 0.16.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/2014-04-01/generated/azure_mgmt_sql.rb +77 -63
- data/lib/2014-04-01/generated/azure_mgmt_sql/backup_long_term_retention_policies.rb +118 -16
- data/lib/2014-04-01/generated/azure_mgmt_sql/backup_long_term_retention_vaults.rb +114 -16
- data/lib/2014-04-01/generated/azure_mgmt_sql/capabilities.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/data_masking_policies.rb +12 -12
- data/lib/2014-04-01/generated/azure_mgmt_sql/data_masking_rules.rb +12 -12
- data/lib/2014-04-01/generated/azure_mgmt_sql/database_advisors.rb +18 -17
- data/lib/2014-04-01/generated/azure_mgmt_sql/database_connection_policies.rb +12 -12
- data/lib/2014-04-01/generated/azure_mgmt_sql/database_table_auditing_policies.rb +18 -17
- data/lib/2014-04-01/generated/azure_mgmt_sql/database_threat_detection_policies.rb +12 -12
- data/lib/2014-04-01/generated/azure_mgmt_sql/database_usages.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/databases.rb +649 -643
- data/lib/2014-04-01/generated/azure_mgmt_sql/disaster_recovery_configurations.rb +830 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/elastic_pool_activities.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/elastic_pool_database_activities.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/elastic_pools.rb +216 -213
- data/lib/2014-04-01/generated/azure_mgmt_sql/extensions.rb +130 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/firewall_rules.rb +24 -22
- data/lib/2014-04-01/generated/azure_mgmt_sql/geo_backup_policies.rb +18 -17
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/backup_long_term_retention_policy_list_result.rb +56 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/backup_long_term_retention_vault_list_result.rb +56 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/database.rb +43 -10
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/database_edition.rb +1 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/database_update.rb +43 -10
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/disaster_recovery_configuration.rb +164 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/disaster_recovery_configuration_auto_failover.rb +16 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/disaster_recovery_configuration_failover_policy.rb +16 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/disaster_recovery_configuration_list_result.rb +57 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/disaster_recovery_configuration_role.rb +17 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/disaster_recovery_configuration_status.rb +18 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/edition_capability.rb +13 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/elastic_pool.rb +13 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/elastic_pool_edition_capability.rb +13 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/elastic_pool_update.rb +13 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/extension_list_result.rb +54 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/import_request.rb +12 -4
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/query_text.rb +72 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/query_text_list_result.rb +55 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/service_objective_name.rb +52 -2
- data/lib/2014-04-01/generated/azure_mgmt_sql/models/slo_usage_metric.rb +10 -3
- data/lib/2014-04-01/generated/azure_mgmt_sql/operations.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/queries.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/query_statistics.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/query_texts.rb +134 -0
- data/lib/2014-04-01/generated/azure_mgmt_sql/recommended_elastic_pools.rb +18 -15
- data/lib/2014-04-01/generated/azure_mgmt_sql/recoverable_databases.rb +12 -10
- data/lib/2014-04-01/generated/azure_mgmt_sql/replication_links.rb +38 -33
- data/lib/2014-04-01/generated/azure_mgmt_sql/restorable_dropped_databases.rb +12 -10
- data/lib/2014-04-01/generated/azure_mgmt_sql/restore_points.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/server_azure_adadministrators.rb +32 -30
- data/lib/2014-04-01/generated/azure_mgmt_sql/server_communication_links.rb +28 -26
- data/lib/2014-04-01/generated/azure_mgmt_sql/server_connection_policies.rb +12 -12
- data/lib/2014-04-01/generated/azure_mgmt_sql/server_table_auditing_policies.rb +18 -17
- data/lib/2014-04-01/generated/azure_mgmt_sql/server_usages.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/servers.rb +134 -133
- data/lib/2014-04-01/generated/azure_mgmt_sql/service_objectives.rb +12 -10
- data/lib/2014-04-01/generated/azure_mgmt_sql/service_tier_advisors.rb +12 -10
- data/lib/2014-04-01/generated/azure_mgmt_sql/sql_management_client.rb +32 -17
- data/lib/2014-04-01/generated/azure_mgmt_sql/transparent_data_encryption_activities.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/transparent_data_encryption_configurations.rb +6 -5
- data/lib/2014-04-01/generated/azure_mgmt_sql/transparent_data_encryptions.rb +12 -12
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql.rb +22 -19
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/database_advisors.rb +18 -17
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/database_blob_auditing_policies.rb +12 -12
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/database_recommended_actions.rb +18 -17
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/encryption_protectors.rb +31 -29
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/failover_groups.rb +71 -67
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/models/subscription_usage.rb +110 -0
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/models/subscription_usage_list_result.rb +100 -0
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/operations.rb +15 -13
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/server_advisors.rb +18 -17
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/server_keys.rb +41 -38
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/servers.rb +66 -62
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/sql_management_client.rb +8 -1
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/subscription_usages.rb +324 -0
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/sync_agents.rb +62 -56
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/sync_groups.rb +118 -107
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/sync_members.rb +76 -71
- data/lib/2015-05-01-preview/generated/azure_mgmt_sql/virtual_network_rules.rb +41 -38
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql.rb +30 -1
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/database_operations.rb +21 -18
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/database_restore_points.rb +527 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/databases.rb +1599 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/arm_sku.rb +92 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/automatic_tuning_option_mode_actual.rb +16 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/automatic_tuning_option_mode_desired.rb +17 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/automatic_tuning_server_mode.rb +17 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/automatic_tuning_server_options.rb +90 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/automatic_tuning_server_reason.rb +17 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/catalog_collation_type.rb +16 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/create_database_restore_point_definition.rb +47 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/create_mode.rb +23 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/database.rb +393 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/database_list_result.rb +100 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/database_restore_point.rb +124 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/database_restore_point_list_result.rb +100 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/database_update.rb +348 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/import_export_database_definition.rb +145 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/import_export_operation_result.rb +170 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/resource_move_definition.rb +46 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/restore_point_type.rb +16 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/sample_name.rb +17 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/server_automatic_tuning.rb +110 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/server_dns_alias.rb +74 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/server_dns_alias_acquisition.rb +47 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/server_dns_alias_list_result.rb +100 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/status.rb +32 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/models/tracked_resource.rb +92 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/server_automatic_tuning_operations.rb +238 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/server_dns_aliases.rb +805 -0
- data/lib/2017-03-01-preview/generated/azure_mgmt_sql/sql_management_client.rb +21 -1
- data/lib/profiles/latest/modules/sql_profile_module.rb +912 -749
- data/lib/profiles/latest/sql_latest_profile_client.rb +28 -9
- data/lib/profiles/latest/sql_module_definition.rb +0 -1
- data/lib/version.rb +1 -1
- metadata +49 -3
@@ -0,0 +1,130 @@
|
|
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::SQL::Mgmt::V2014_04_01
|
7
|
+
#
|
8
|
+
# The Azure SQL Database management API provides a RESTful set of web
|
9
|
+
# services that interact with Azure SQL Database services to manage your
|
10
|
+
# databases. The API enables you to create, retrieve, update, and delete
|
11
|
+
# databases.
|
12
|
+
#
|
13
|
+
class Extensions
|
14
|
+
include MsRestAzure
|
15
|
+
|
16
|
+
#
|
17
|
+
# Creates and initializes a new instance of the Extensions class.
|
18
|
+
# @param client service class for accessing basic functionality.
|
19
|
+
#
|
20
|
+
def initialize(client)
|
21
|
+
@client = client
|
22
|
+
end
|
23
|
+
|
24
|
+
# @return [SqlManagementClient] reference to the SqlManagementClient
|
25
|
+
attr_reader :client
|
26
|
+
|
27
|
+
#
|
28
|
+
# Gets database extensions.
|
29
|
+
#
|
30
|
+
# @param resource_group_name [String] The name of the resource group that
|
31
|
+
# contains the resource. You can obtain this value from the Azure Resource
|
32
|
+
# Manager API or the portal.
|
33
|
+
# @param server_name [String] The name of the server.
|
34
|
+
# @param database_name [String] The name of the database to import into
|
35
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
36
|
+
# will be added to the HTTP request.
|
37
|
+
#
|
38
|
+
# @return [ExtensionListResult] operation results.
|
39
|
+
#
|
40
|
+
def list_by_database(resource_group_name, server_name, database_name, custom_headers:nil)
|
41
|
+
response = list_by_database_async(resource_group_name, server_name, database_name, custom_headers:custom_headers).value!
|
42
|
+
response.body unless response.nil?
|
43
|
+
end
|
44
|
+
|
45
|
+
#
|
46
|
+
# Gets database extensions.
|
47
|
+
#
|
48
|
+
# @param resource_group_name [String] The name of the resource group that
|
49
|
+
# contains the resource. You can obtain this value from the Azure Resource
|
50
|
+
# Manager API or the portal.
|
51
|
+
# @param server_name [String] The name of the server.
|
52
|
+
# @param database_name [String] The name of the database to import into
|
53
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
54
|
+
# will be added to the HTTP request.
|
55
|
+
#
|
56
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
57
|
+
#
|
58
|
+
def list_by_database_with_http_info(resource_group_name, server_name, database_name, custom_headers:nil)
|
59
|
+
list_by_database_async(resource_group_name, server_name, database_name, custom_headers:custom_headers).value!
|
60
|
+
end
|
61
|
+
|
62
|
+
#
|
63
|
+
# Gets database extensions.
|
64
|
+
#
|
65
|
+
# @param resource_group_name [String] The name of the resource group that
|
66
|
+
# contains the resource. You can obtain this value from the Azure Resource
|
67
|
+
# Manager API or the portal.
|
68
|
+
# @param server_name [String] The name of the server.
|
69
|
+
# @param database_name [String] The name of the database to import into
|
70
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
71
|
+
# to the HTTP request.
|
72
|
+
#
|
73
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
74
|
+
#
|
75
|
+
def list_by_database_async(resource_group_name, server_name, database_name, custom_headers:nil)
|
76
|
+
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
77
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
78
|
+
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
79
|
+
fail ArgumentError, 'server_name is nil' if server_name.nil?
|
80
|
+
fail ArgumentError, 'database_name is nil' if database_name.nil?
|
81
|
+
|
82
|
+
|
83
|
+
request_headers = {}
|
84
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
85
|
+
|
86
|
+
# Set Headers
|
87
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
88
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
89
|
+
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/servers/{serverName}/databases/{databaseName}/extensions'
|
90
|
+
|
91
|
+
request_url = @base_url || @client.base_url
|
92
|
+
|
93
|
+
options = {
|
94
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
95
|
+
path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'serverName' => server_name,'databaseName' => database_name},
|
96
|
+
query_params: {'api-version' => @client.api_version},
|
97
|
+
headers: request_headers.merge(custom_headers || {}),
|
98
|
+
base_url: request_url
|
99
|
+
}
|
100
|
+
promise = @client.make_request_async(:get, path_template, options)
|
101
|
+
|
102
|
+
promise = promise.then do |result|
|
103
|
+
http_response = result.response
|
104
|
+
status_code = http_response.status
|
105
|
+
response_content = http_response.body
|
106
|
+
unless status_code == 200
|
107
|
+
error_model = JSON.load(response_content)
|
108
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
109
|
+
end
|
110
|
+
|
111
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
112
|
+
# Deserialize Response
|
113
|
+
if status_code == 200
|
114
|
+
begin
|
115
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
116
|
+
result_mapper = Azure::SQL::Mgmt::V2014_04_01::Models::ExtensionListResult.mapper()
|
117
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
118
|
+
rescue Exception => e
|
119
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
120
|
+
end
|
121
|
+
end
|
122
|
+
|
123
|
+
result
|
124
|
+
end
|
125
|
+
|
126
|
+
promise.execute
|
127
|
+
end
|
128
|
+
|
129
|
+
end
|
130
|
+
end
|
@@ -39,8 +39,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
39
39
|
#
|
40
40
|
# @return [FirewallRule] operation results.
|
41
41
|
#
|
42
|
-
def create_or_update(resource_group_name, server_name, firewall_rule_name, parameters, custom_headers
|
43
|
-
response = create_or_update_async(resource_group_name, server_name, firewall_rule_name, parameters, custom_headers).value!
|
42
|
+
def create_or_update(resource_group_name, server_name, firewall_rule_name, parameters, custom_headers:nil)
|
43
|
+
response = create_or_update_async(resource_group_name, server_name, firewall_rule_name, parameters, custom_headers:custom_headers).value!
|
44
44
|
response.body unless response.nil?
|
45
45
|
end
|
46
46
|
|
@@ -59,8 +59,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
59
59
|
#
|
60
60
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
61
61
|
#
|
62
|
-
def create_or_update_with_http_info(resource_group_name, server_name, firewall_rule_name, parameters, custom_headers
|
63
|
-
create_or_update_async(resource_group_name, server_name, firewall_rule_name, parameters, custom_headers).value!
|
62
|
+
def create_or_update_with_http_info(resource_group_name, server_name, firewall_rule_name, parameters, custom_headers:nil)
|
63
|
+
create_or_update_async(resource_group_name, server_name, firewall_rule_name, parameters, custom_headers:custom_headers).value!
|
64
64
|
end
|
65
65
|
|
66
66
|
#
|
@@ -78,7 +78,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
78
78
|
#
|
79
79
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
80
80
|
#
|
81
|
-
def create_or_update_async(resource_group_name, server_name, firewall_rule_name, parameters, custom_headers
|
81
|
+
def create_or_update_async(resource_group_name, server_name, firewall_rule_name, parameters, custom_headers:nil)
|
82
82
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
83
83
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
84
84
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
@@ -88,13 +88,12 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
88
88
|
|
89
89
|
|
90
90
|
request_headers = {}
|
91
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
91
92
|
|
92
93
|
# Set Headers
|
93
94
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
94
95
|
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
95
96
|
|
96
|
-
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
97
|
-
|
98
97
|
# Serialize Request
|
99
98
|
request_mapper = Azure::SQL::Mgmt::V2014_04_01::Models::FirewallRule.mapper()
|
100
99
|
request_content = @client.serialize(request_mapper, parameters)
|
@@ -163,8 +162,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
163
162
|
# will be added to the HTTP request.
|
164
163
|
#
|
165
164
|
#
|
166
|
-
def delete(resource_group_name, server_name, firewall_rule_name, custom_headers
|
167
|
-
response = delete_async(resource_group_name, server_name, firewall_rule_name, custom_headers).value!
|
165
|
+
def delete(resource_group_name, server_name, firewall_rule_name, custom_headers:nil)
|
166
|
+
response = delete_async(resource_group_name, server_name, firewall_rule_name, custom_headers:custom_headers).value!
|
168
167
|
nil
|
169
168
|
end
|
170
169
|
|
@@ -181,8 +180,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
181
180
|
#
|
182
181
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
183
182
|
#
|
184
|
-
def delete_with_http_info(resource_group_name, server_name, firewall_rule_name, custom_headers
|
185
|
-
delete_async(resource_group_name, server_name, firewall_rule_name, custom_headers).value!
|
183
|
+
def delete_with_http_info(resource_group_name, server_name, firewall_rule_name, custom_headers:nil)
|
184
|
+
delete_async(resource_group_name, server_name, firewall_rule_name, custom_headers:custom_headers).value!
|
186
185
|
end
|
187
186
|
|
188
187
|
#
|
@@ -198,7 +197,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
198
197
|
#
|
199
198
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
200
199
|
#
|
201
|
-
def delete_async(resource_group_name, server_name, firewall_rule_name, custom_headers
|
200
|
+
def delete_async(resource_group_name, server_name, firewall_rule_name, custom_headers:nil)
|
202
201
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
203
202
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
204
203
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
@@ -207,6 +206,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
207
206
|
|
208
207
|
|
209
208
|
request_headers = {}
|
209
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
210
210
|
|
211
211
|
# Set Headers
|
212
212
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -254,8 +254,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
254
254
|
#
|
255
255
|
# @return [FirewallRule] operation results.
|
256
256
|
#
|
257
|
-
def get(resource_group_name, server_name, firewall_rule_name, custom_headers
|
258
|
-
response = get_async(resource_group_name, server_name, firewall_rule_name, custom_headers).value!
|
257
|
+
def get(resource_group_name, server_name, firewall_rule_name, custom_headers:nil)
|
258
|
+
response = get_async(resource_group_name, server_name, firewall_rule_name, custom_headers:custom_headers).value!
|
259
259
|
response.body unless response.nil?
|
260
260
|
end
|
261
261
|
|
@@ -272,8 +272,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
272
272
|
#
|
273
273
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
274
274
|
#
|
275
|
-
def get_with_http_info(resource_group_name, server_name, firewall_rule_name, custom_headers
|
276
|
-
get_async(resource_group_name, server_name, firewall_rule_name, custom_headers).value!
|
275
|
+
def get_with_http_info(resource_group_name, server_name, firewall_rule_name, custom_headers:nil)
|
276
|
+
get_async(resource_group_name, server_name, firewall_rule_name, custom_headers:custom_headers).value!
|
277
277
|
end
|
278
278
|
|
279
279
|
#
|
@@ -289,7 +289,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
289
289
|
#
|
290
290
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
291
291
|
#
|
292
|
-
def get_async(resource_group_name, server_name, firewall_rule_name, custom_headers
|
292
|
+
def get_async(resource_group_name, server_name, firewall_rule_name, custom_headers:nil)
|
293
293
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
294
294
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
295
295
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
@@ -298,6 +298,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
298
298
|
|
299
299
|
|
300
300
|
request_headers = {}
|
301
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
301
302
|
|
302
303
|
# Set Headers
|
303
304
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -354,8 +355,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
354
355
|
#
|
355
356
|
# @return [FirewallRuleListResult] operation results.
|
356
357
|
#
|
357
|
-
def list_by_server(resource_group_name, server_name, custom_headers
|
358
|
-
response = list_by_server_async(resource_group_name, server_name, custom_headers).value!
|
358
|
+
def list_by_server(resource_group_name, server_name, custom_headers:nil)
|
359
|
+
response = list_by_server_async(resource_group_name, server_name, custom_headers:custom_headers).value!
|
359
360
|
response.body unless response.nil?
|
360
361
|
end
|
361
362
|
|
@@ -371,8 +372,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
371
372
|
#
|
372
373
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
373
374
|
#
|
374
|
-
def list_by_server_with_http_info(resource_group_name, server_name, custom_headers
|
375
|
-
list_by_server_async(resource_group_name, server_name, custom_headers).value!
|
375
|
+
def list_by_server_with_http_info(resource_group_name, server_name, custom_headers:nil)
|
376
|
+
list_by_server_async(resource_group_name, server_name, custom_headers:custom_headers).value!
|
376
377
|
end
|
377
378
|
|
378
379
|
#
|
@@ -387,7 +388,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
387
388
|
#
|
388
389
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
389
390
|
#
|
390
|
-
def list_by_server_async(resource_group_name, server_name, custom_headers
|
391
|
+
def list_by_server_async(resource_group_name, server_name, custom_headers:nil)
|
391
392
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
392
393
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
393
394
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
@@ -395,6 +396,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
395
396
|
|
396
397
|
|
397
398
|
request_headers = {}
|
399
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
398
400
|
|
399
401
|
# Set Headers
|
400
402
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -39,8 +39,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
39
39
|
#
|
40
40
|
# @return [GeoBackupPolicy] operation results.
|
41
41
|
#
|
42
|
-
def create_or_update(resource_group_name, server_name, database_name, parameters, custom_headers
|
43
|
-
response = create_or_update_async(resource_group_name, server_name, database_name, parameters, custom_headers).value!
|
42
|
+
def create_or_update(resource_group_name, server_name, database_name, parameters, custom_headers:nil)
|
43
|
+
response = create_or_update_async(resource_group_name, server_name, database_name, parameters, custom_headers:custom_headers).value!
|
44
44
|
response.body unless response.nil?
|
45
45
|
end
|
46
46
|
|
@@ -59,8 +59,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
59
59
|
#
|
60
60
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
61
61
|
#
|
62
|
-
def create_or_update_with_http_info(resource_group_name, server_name, database_name, parameters, custom_headers
|
63
|
-
create_or_update_async(resource_group_name, server_name, database_name, parameters, custom_headers).value!
|
62
|
+
def create_or_update_with_http_info(resource_group_name, server_name, database_name, parameters, custom_headers:nil)
|
63
|
+
create_or_update_async(resource_group_name, server_name, database_name, parameters, custom_headers:custom_headers).value!
|
64
64
|
end
|
65
65
|
|
66
66
|
#
|
@@ -78,7 +78,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
78
78
|
#
|
79
79
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
80
80
|
#
|
81
|
-
def create_or_update_async(resource_group_name, server_name, database_name, parameters, custom_headers
|
81
|
+
def create_or_update_async(resource_group_name, server_name, database_name, parameters, custom_headers:nil)
|
82
82
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
83
83
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
84
84
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
@@ -89,13 +89,12 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
89
89
|
|
90
90
|
|
91
91
|
request_headers = {}
|
92
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
92
93
|
|
93
94
|
# Set Headers
|
94
95
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
95
96
|
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
96
97
|
|
97
|
-
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
98
|
-
|
99
98
|
# Serialize Request
|
100
99
|
request_mapper = Azure::SQL::Mgmt::V2014_04_01::Models::GeoBackupPolicy.mapper()
|
101
100
|
request_content = @client.serialize(request_mapper, parameters)
|
@@ -165,8 +164,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
165
164
|
#
|
166
165
|
# @return [GeoBackupPolicy] operation results.
|
167
166
|
#
|
168
|
-
def get(resource_group_name, server_name, database_name, custom_headers
|
169
|
-
response = get_async(resource_group_name, server_name, database_name, custom_headers).value!
|
167
|
+
def get(resource_group_name, server_name, database_name, custom_headers:nil)
|
168
|
+
response = get_async(resource_group_name, server_name, database_name, custom_headers:custom_headers).value!
|
170
169
|
response.body unless response.nil?
|
171
170
|
end
|
172
171
|
|
@@ -183,8 +182,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
183
182
|
#
|
184
183
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
185
184
|
#
|
186
|
-
def get_with_http_info(resource_group_name, server_name, database_name, custom_headers
|
187
|
-
get_async(resource_group_name, server_name, database_name, custom_headers).value!
|
185
|
+
def get_with_http_info(resource_group_name, server_name, database_name, custom_headers:nil)
|
186
|
+
get_async(resource_group_name, server_name, database_name, custom_headers:custom_headers).value!
|
188
187
|
end
|
189
188
|
|
190
189
|
#
|
@@ -200,7 +199,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
200
199
|
#
|
201
200
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
202
201
|
#
|
203
|
-
def get_async(resource_group_name, server_name, database_name, custom_headers
|
202
|
+
def get_async(resource_group_name, server_name, database_name, custom_headers:nil)
|
204
203
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
205
204
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
206
205
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
@@ -210,6 +209,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
210
209
|
|
211
210
|
|
212
211
|
request_headers = {}
|
212
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
213
213
|
|
214
214
|
# Set Headers
|
215
215
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -267,8 +267,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
267
267
|
#
|
268
268
|
# @return [GeoBackupPolicyListResult] operation results.
|
269
269
|
#
|
270
|
-
def list_by_database(resource_group_name, server_name, database_name, custom_headers
|
271
|
-
response = list_by_database_async(resource_group_name, server_name, database_name, custom_headers).value!
|
270
|
+
def list_by_database(resource_group_name, server_name, database_name, custom_headers:nil)
|
271
|
+
response = list_by_database_async(resource_group_name, server_name, database_name, custom_headers:custom_headers).value!
|
272
272
|
response.body unless response.nil?
|
273
273
|
end
|
274
274
|
|
@@ -285,8 +285,8 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
285
285
|
#
|
286
286
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
287
287
|
#
|
288
|
-
def list_by_database_with_http_info(resource_group_name, server_name, database_name, custom_headers
|
289
|
-
list_by_database_async(resource_group_name, server_name, database_name, custom_headers).value!
|
288
|
+
def list_by_database_with_http_info(resource_group_name, server_name, database_name, custom_headers:nil)
|
289
|
+
list_by_database_async(resource_group_name, server_name, database_name, custom_headers:custom_headers).value!
|
290
290
|
end
|
291
291
|
|
292
292
|
#
|
@@ -302,7 +302,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
302
302
|
#
|
303
303
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
304
304
|
#
|
305
|
-
def list_by_database_async(resource_group_name, server_name, database_name, custom_headers
|
305
|
+
def list_by_database_async(resource_group_name, server_name, database_name, custom_headers:nil)
|
306
306
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
307
307
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
308
308
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
@@ -311,6 +311,7 @@ module Azure::SQL::Mgmt::V2014_04_01
|
|
311
311
|
|
312
312
|
|
313
313
|
request_headers = {}
|
314
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
314
315
|
|
315
316
|
# Set Headers
|
316
317
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
data/lib/2014-04-01/generated/azure_mgmt_sql/models/backup_long_term_retention_policy_list_result.rb
ADDED
@@ -0,0 +1,56 @@
|
|
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::SQL::Mgmt::V2014_04_01
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# Represents the response to a list long-term retention policies request.
|
10
|
+
#
|
11
|
+
class BackupLongTermRetentionPolicyListResult
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
# @return [Array<BackupLongTermRetentionPolicy>] The list of long-term
|
16
|
+
# retention policies in the database.
|
17
|
+
attr_accessor :value
|
18
|
+
|
19
|
+
|
20
|
+
#
|
21
|
+
# Mapper for BackupLongTermRetentionPolicyListResult class as Ruby Hash.
|
22
|
+
# This will be used for serialization/deserialization.
|
23
|
+
#
|
24
|
+
def self.mapper()
|
25
|
+
{
|
26
|
+
client_side_validation: true,
|
27
|
+
required: false,
|
28
|
+
serialized_name: 'BackupLongTermRetentionPolicyListResult',
|
29
|
+
type: {
|
30
|
+
name: 'Composite',
|
31
|
+
class_name: 'BackupLongTermRetentionPolicyListResult',
|
32
|
+
model_properties: {
|
33
|
+
value: {
|
34
|
+
client_side_validation: true,
|
35
|
+
required: true,
|
36
|
+
serialized_name: 'value',
|
37
|
+
type: {
|
38
|
+
name: 'Sequence',
|
39
|
+
element: {
|
40
|
+
client_side_validation: true,
|
41
|
+
required: false,
|
42
|
+
serialized_name: 'BackupLongTermRetentionPolicyElementType',
|
43
|
+
type: {
|
44
|
+
name: 'Composite',
|
45
|
+
class_name: 'BackupLongTermRetentionPolicy'
|
46
|
+
}
|
47
|
+
}
|
48
|
+
}
|
49
|
+
}
|
50
|
+
}
|
51
|
+
}
|
52
|
+
}
|
53
|
+
end
|
54
|
+
end
|
55
|
+
end
|
56
|
+
end
|