azure_mgmt_datalake_store 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/2015-10-01-preview/generated/azure_mgmt_datalake_store/account.rb +105 -97
- data/lib/2015-10-01-preview/generated/azure_mgmt_datalake_store/data_lake_store_account_management_client.rb +4 -1
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store.rb +28 -12
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/{account.rb → accounts.rb} +491 -402
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/data_lake_store_account_management_client.rb +15 -4
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/firewall_rules.rb +171 -201
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/locations.rb +116 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/capability_information.rb +100 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/check_name_availability_parameters.rb +61 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/create_data_lake_store_account_parameters.rb +216 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/create_firewall_rule_with_account_parameters.rb +71 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/create_or_update_firewall_rule_parameters.rb +59 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/create_or_update_trusted_id_provider_parameters.rb +47 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/create_trusted_id_provider_with_account_parameters.rb +60 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/data_lake_store_account.rb +82 -70
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/data_lake_store_account_basic.rb +21 -19
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/data_lake_store_account_list_result.rb +3 -3
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/firewall_rule.rb +8 -5
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/{data_lake_store_firewall_rule_list_result.rb → firewall_rule_list_result.rb} +7 -7
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/{error_details.rb → name_availability_information.rb} +21 -20
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/operation.rb +72 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/operation_display.rb +83 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/operation_list_result.rb +68 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/operation_origin.rb +17 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/resource.rb +9 -7
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/sub_resource.rb +5 -4
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/subscription_state.rb +19 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/trusted_id_provider.rb +5 -3
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/{data_lake_store_trusted_id_provider_list_result.rb → trusted_id_provider_list_result.rb} +7 -8
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/{data_lake_store_account_update_parameters.rb → update_data_lake_store_account_parameters.rb} +84 -41
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/update_firewall_rule_parameters.rb +3 -3
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/update_firewall_rule_with_account_parameters.rb +71 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/update_trusted_id_provider_parameters.rb +2 -2
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/models/update_trusted_id_provider_with_account_parameters.rb +60 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/operations.rb +107 -0
- data/lib/2016-11-01/generated/azure_mgmt_datalake_store/trusted_id_providers.rb +171 -201
- data/lib/profiles/latest/datalakestore_latest_profile_client.rb +28 -9
- data/lib/profiles/latest/datalakestore_module_definition.rb +0 -1
- data/lib/profiles/latest/modules/datalakestore_profile_module.rb +184 -105
- data/lib/version.rb +1 -1
- metadata +23 -7
@@ -6,13 +6,13 @@
|
|
6
6
|
module Azure::DataLakeStore::Mgmt::V2016_11_01
|
7
7
|
module Models
|
8
8
|
#
|
9
|
-
#
|
9
|
+
# The parameters used to update a trusted identity provider.
|
10
10
|
#
|
11
11
|
class UpdateTrustedIdProviderParameters
|
12
12
|
|
13
13
|
include MsRestAzure
|
14
14
|
|
15
|
-
# @return [String] The URL of this trusted identity provider
|
15
|
+
# @return [String] The URL of this trusted identity provider.
|
16
16
|
attr_accessor :id_provider
|
17
17
|
|
18
18
|
|
@@ -0,0 +1,60 @@
|
|
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::DataLakeStore::Mgmt::V2016_11_01
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# The parameters used to update a trusted identity provider while updating
|
10
|
+
# a Data Lake Store account.
|
11
|
+
#
|
12
|
+
class UpdateTrustedIdProviderWithAccountParameters
|
13
|
+
|
14
|
+
include MsRestAzure
|
15
|
+
|
16
|
+
# @return [String] The unique name of the trusted identity provider to
|
17
|
+
# update.
|
18
|
+
attr_accessor :name
|
19
|
+
|
20
|
+
# @return [String] The URL of this trusted identity provider.
|
21
|
+
attr_accessor :id_provider
|
22
|
+
|
23
|
+
|
24
|
+
#
|
25
|
+
# Mapper for UpdateTrustedIdProviderWithAccountParameters class as Ruby
|
26
|
+
# Hash.
|
27
|
+
# This will be used for serialization/deserialization.
|
28
|
+
#
|
29
|
+
def self.mapper()
|
30
|
+
{
|
31
|
+
client_side_validation: true,
|
32
|
+
required: false,
|
33
|
+
serialized_name: 'UpdateTrustedIdProviderWithAccountParameters',
|
34
|
+
type: {
|
35
|
+
name: 'Composite',
|
36
|
+
class_name: 'UpdateTrustedIdProviderWithAccountParameters',
|
37
|
+
model_properties: {
|
38
|
+
name: {
|
39
|
+
client_side_validation: true,
|
40
|
+
required: true,
|
41
|
+
serialized_name: 'name',
|
42
|
+
type: {
|
43
|
+
name: 'String'
|
44
|
+
}
|
45
|
+
},
|
46
|
+
id_provider: {
|
47
|
+
client_side_validation: true,
|
48
|
+
required: false,
|
49
|
+
serialized_name: 'properties.idProvider',
|
50
|
+
type: {
|
51
|
+
name: 'String'
|
52
|
+
}
|
53
|
+
}
|
54
|
+
}
|
55
|
+
}
|
56
|
+
}
|
57
|
+
end
|
58
|
+
end
|
59
|
+
end
|
60
|
+
end
|
@@ -0,0 +1,107 @@
|
|
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::DataLakeStore::Mgmt::V2016_11_01
|
7
|
+
#
|
8
|
+
# Creates an Azure Data Lake Store account management client.
|
9
|
+
#
|
10
|
+
class Operations
|
11
|
+
include MsRestAzure
|
12
|
+
|
13
|
+
#
|
14
|
+
# Creates and initializes a new instance of the Operations class.
|
15
|
+
# @param client service class for accessing basic functionality.
|
16
|
+
#
|
17
|
+
def initialize(client)
|
18
|
+
@client = client
|
19
|
+
end
|
20
|
+
|
21
|
+
# @return [DataLakeStoreAccountManagementClient] reference to the DataLakeStoreAccountManagementClient
|
22
|
+
attr_reader :client
|
23
|
+
|
24
|
+
#
|
25
|
+
# Lists all of the available Data Lake Store REST API operations.
|
26
|
+
#
|
27
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
28
|
+
# will be added to the HTTP request.
|
29
|
+
#
|
30
|
+
# @return [OperationListResult] operation results.
|
31
|
+
#
|
32
|
+
def list(custom_headers:nil)
|
33
|
+
response = list_async(custom_headers:custom_headers).value!
|
34
|
+
response.body unless response.nil?
|
35
|
+
end
|
36
|
+
|
37
|
+
#
|
38
|
+
# Lists all of the available Data Lake Store REST API operations.
|
39
|
+
#
|
40
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
41
|
+
# will be added to the HTTP request.
|
42
|
+
#
|
43
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
44
|
+
#
|
45
|
+
def list_with_http_info(custom_headers:nil)
|
46
|
+
list_async(custom_headers:custom_headers).value!
|
47
|
+
end
|
48
|
+
|
49
|
+
#
|
50
|
+
# Lists all of the available Data Lake Store REST API operations.
|
51
|
+
#
|
52
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
53
|
+
# to the HTTP request.
|
54
|
+
#
|
55
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
56
|
+
#
|
57
|
+
def list_async(custom_headers:nil)
|
58
|
+
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
59
|
+
|
60
|
+
|
61
|
+
request_headers = {}
|
62
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
63
|
+
|
64
|
+
# Set Headers
|
65
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
66
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
67
|
+
path_template = 'providers/Microsoft.DataLakeStore/operations'
|
68
|
+
|
69
|
+
request_url = @base_url || @client.base_url
|
70
|
+
|
71
|
+
options = {
|
72
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
73
|
+
query_params: {'api-version' => @client.api_version},
|
74
|
+
headers: request_headers.merge(custom_headers || {}),
|
75
|
+
base_url: request_url
|
76
|
+
}
|
77
|
+
promise = @client.make_request_async(:get, path_template, options)
|
78
|
+
|
79
|
+
promise = promise.then do |result|
|
80
|
+
http_response = result.response
|
81
|
+
status_code = http_response.status
|
82
|
+
response_content = http_response.body
|
83
|
+
unless status_code == 200
|
84
|
+
error_model = JSON.load(response_content)
|
85
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
86
|
+
end
|
87
|
+
|
88
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
89
|
+
# Deserialize Response
|
90
|
+
if status_code == 200
|
91
|
+
begin
|
92
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
93
|
+
result_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::OperationListResult.mapper()
|
94
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
95
|
+
rescue Exception => e
|
96
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
97
|
+
end
|
98
|
+
end
|
99
|
+
|
100
|
+
result
|
101
|
+
end
|
102
|
+
|
103
|
+
promise.execute
|
104
|
+
end
|
105
|
+
|
106
|
+
end
|
107
|
+
end
|
@@ -22,103 +22,72 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
22
22
|
attr_reader :client
|
23
23
|
|
24
24
|
#
|
25
|
-
#
|
26
|
-
#
|
27
|
-
# this new provider
|
25
|
+
# Lists the Data Lake Store trusted identity providers within the specified
|
26
|
+
# Data Lake Store account.
|
28
27
|
#
|
29
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
30
|
-
#
|
31
|
-
# @param account_name [String] The name of the Data Lake Store account to add
|
32
|
-
# or replace the trusted identity provider.
|
33
|
-
# @param trusted_id_provider_name [String] The name of the trusted identity
|
34
|
-
# provider. This is used for differentiation of providers in the account.
|
35
|
-
# @param parameters [TrustedIdProvider] Parameters supplied to create or
|
36
|
-
# replace the trusted identity provider.
|
28
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
29
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
37
30
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
38
31
|
# will be added to the HTTP request.
|
39
32
|
#
|
40
|
-
# @return [TrustedIdProvider] operation results.
|
33
|
+
# @return [Array<TrustedIdProvider>] operation results.
|
41
34
|
#
|
42
|
-
def
|
43
|
-
|
44
|
-
|
35
|
+
def list_by_account(resource_group_name, account_name, custom_headers:nil)
|
36
|
+
first_page = list_by_account_as_lazy(resource_group_name, account_name, custom_headers:custom_headers)
|
37
|
+
first_page.get_all_items
|
45
38
|
end
|
46
39
|
|
47
40
|
#
|
48
|
-
#
|
49
|
-
#
|
50
|
-
# this new provider
|
41
|
+
# Lists the Data Lake Store trusted identity providers within the specified
|
42
|
+
# Data Lake Store account.
|
51
43
|
#
|
52
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
53
|
-
#
|
54
|
-
# @param account_name [String] The name of the Data Lake Store account to add
|
55
|
-
# or replace the trusted identity provider.
|
56
|
-
# @param trusted_id_provider_name [String] The name of the trusted identity
|
57
|
-
# provider. This is used for differentiation of providers in the account.
|
58
|
-
# @param parameters [TrustedIdProvider] Parameters supplied to create or
|
59
|
-
# replace the trusted identity provider.
|
44
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
45
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
60
46
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
61
47
|
# will be added to the HTTP request.
|
62
48
|
#
|
63
49
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
64
50
|
#
|
65
|
-
def
|
66
|
-
|
51
|
+
def list_by_account_with_http_info(resource_group_name, account_name, custom_headers:nil)
|
52
|
+
list_by_account_async(resource_group_name, account_name, custom_headers:custom_headers).value!
|
67
53
|
end
|
68
54
|
|
69
55
|
#
|
70
|
-
#
|
71
|
-
#
|
72
|
-
# this new provider
|
56
|
+
# Lists the Data Lake Store trusted identity providers within the specified
|
57
|
+
# Data Lake Store account.
|
73
58
|
#
|
74
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
75
|
-
#
|
76
|
-
# @param account_name [String] The name of the Data Lake Store account to add
|
77
|
-
# or replace the trusted identity provider.
|
78
|
-
# @param trusted_id_provider_name [String] The name of the trusted identity
|
79
|
-
# provider. This is used for differentiation of providers in the account.
|
80
|
-
# @param parameters [TrustedIdProvider] Parameters supplied to create or
|
81
|
-
# replace the trusted identity provider.
|
59
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
60
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
82
61
|
# @param [Hash{String => String}] A hash of custom headers that will be added
|
83
62
|
# to the HTTP request.
|
84
63
|
#
|
85
64
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
86
65
|
#
|
87
|
-
def
|
66
|
+
def list_by_account_async(resource_group_name, account_name, custom_headers:nil)
|
67
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
88
68
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
89
69
|
fail ArgumentError, 'account_name is nil' if account_name.nil?
|
90
|
-
fail ArgumentError, 'trusted_id_provider_name is nil' if trusted_id_provider_name.nil?
|
91
|
-
fail ArgumentError, 'parameters is nil' if parameters.nil?
|
92
70
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
93
|
-
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
94
71
|
|
95
72
|
|
96
73
|
request_headers = {}
|
74
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
97
75
|
|
98
76
|
# Set Headers
|
99
77
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
100
78
|
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
101
|
-
|
102
|
-
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
103
|
-
|
104
|
-
# Serialize Request
|
105
|
-
request_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::TrustedIdProvider.mapper()
|
106
|
-
request_content = @client.serialize(request_mapper, parameters)
|
107
|
-
request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
|
108
|
-
|
109
|
-
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/trustedIdProviders/{trustedIdProviderName}'
|
79
|
+
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/trustedIdProviders'
|
110
80
|
|
111
81
|
request_url = @base_url || @client.base_url
|
112
82
|
|
113
83
|
options = {
|
114
84
|
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
115
|
-
path_params: {'
|
85
|
+
path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'accountName' => account_name},
|
116
86
|
query_params: {'api-version' => @client.api_version},
|
117
|
-
body: request_content,
|
118
87
|
headers: request_headers.merge(custom_headers || {}),
|
119
88
|
base_url: request_url
|
120
89
|
}
|
121
|
-
promise = @client.make_request_async(:
|
90
|
+
promise = @client.make_request_async(:get, path_template, options)
|
122
91
|
|
123
92
|
promise = promise.then do |result|
|
124
93
|
http_response = result.response
|
@@ -134,7 +103,7 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
134
103
|
if status_code == 200
|
135
104
|
begin
|
136
105
|
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
137
|
-
result_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::
|
106
|
+
result_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::TrustedIdProviderListResult.mapper()
|
138
107
|
result.body = @client.deserialize(result_mapper, parsed_response)
|
139
108
|
rescue Exception => e
|
140
109
|
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
@@ -148,80 +117,80 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
148
117
|
end
|
149
118
|
|
150
119
|
#
|
151
|
-
#
|
120
|
+
# Creates or updates the specified trusted identity provider. During update,
|
121
|
+
# the trusted identity provider with the specified name will be replaced with
|
122
|
+
# this new provider
|
152
123
|
#
|
153
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
154
|
-
#
|
155
|
-
# @param account_name [String] The name of the Data Lake Store account to which
|
156
|
-
# to update the trusted identity provider.
|
124
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
125
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
157
126
|
# @param trusted_id_provider_name [String] The name of the trusted identity
|
158
127
|
# provider. This is used for differentiation of providers in the account.
|
159
|
-
# @param parameters [
|
160
|
-
#
|
128
|
+
# @param parameters [CreateOrUpdateTrustedIdProviderParameters] Parameters
|
129
|
+
# supplied to create or replace the trusted identity provider.
|
161
130
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
162
131
|
# will be added to the HTTP request.
|
163
132
|
#
|
164
133
|
# @return [TrustedIdProvider] operation results.
|
165
134
|
#
|
166
|
-
def
|
167
|
-
response =
|
135
|
+
def create_or_update(resource_group_name, account_name, trusted_id_provider_name, parameters, custom_headers:nil)
|
136
|
+
response = create_or_update_async(resource_group_name, account_name, trusted_id_provider_name, parameters, custom_headers:custom_headers).value!
|
168
137
|
response.body unless response.nil?
|
169
138
|
end
|
170
139
|
|
171
140
|
#
|
172
|
-
#
|
141
|
+
# Creates or updates the specified trusted identity provider. During update,
|
142
|
+
# the trusted identity provider with the specified name will be replaced with
|
143
|
+
# this new provider
|
173
144
|
#
|
174
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
175
|
-
#
|
176
|
-
# @param account_name [String] The name of the Data Lake Store account to which
|
177
|
-
# to update the trusted identity provider.
|
145
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
146
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
178
147
|
# @param trusted_id_provider_name [String] The name of the trusted identity
|
179
148
|
# provider. This is used for differentiation of providers in the account.
|
180
|
-
# @param parameters [
|
181
|
-
#
|
149
|
+
# @param parameters [CreateOrUpdateTrustedIdProviderParameters] Parameters
|
150
|
+
# supplied to create or replace the trusted identity provider.
|
182
151
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
183
152
|
# will be added to the HTTP request.
|
184
153
|
#
|
185
154
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
186
155
|
#
|
187
|
-
def
|
188
|
-
|
156
|
+
def create_or_update_with_http_info(resource_group_name, account_name, trusted_id_provider_name, parameters, custom_headers:nil)
|
157
|
+
create_or_update_async(resource_group_name, account_name, trusted_id_provider_name, parameters, custom_headers:custom_headers).value!
|
189
158
|
end
|
190
159
|
|
191
160
|
#
|
192
|
-
#
|
161
|
+
# Creates or updates the specified trusted identity provider. During update,
|
162
|
+
# the trusted identity provider with the specified name will be replaced with
|
163
|
+
# this new provider
|
193
164
|
#
|
194
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
195
|
-
#
|
196
|
-
# @param account_name [String] The name of the Data Lake Store account to which
|
197
|
-
# to update the trusted identity provider.
|
165
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
166
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
198
167
|
# @param trusted_id_provider_name [String] The name of the trusted identity
|
199
168
|
# provider. This is used for differentiation of providers in the account.
|
200
|
-
# @param parameters [
|
201
|
-
#
|
169
|
+
# @param parameters [CreateOrUpdateTrustedIdProviderParameters] Parameters
|
170
|
+
# supplied to create or replace the trusted identity provider.
|
202
171
|
# @param [Hash{String => String}] A hash of custom headers that will be added
|
203
172
|
# to the HTTP request.
|
204
173
|
#
|
205
174
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
206
175
|
#
|
207
|
-
def
|
176
|
+
def create_or_update_async(resource_group_name, account_name, trusted_id_provider_name, parameters, custom_headers:nil)
|
177
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
208
178
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
209
179
|
fail ArgumentError, 'account_name is nil' if account_name.nil?
|
210
180
|
fail ArgumentError, 'trusted_id_provider_name is nil' if trusted_id_provider_name.nil?
|
181
|
+
fail ArgumentError, 'parameters is nil' if parameters.nil?
|
211
182
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
212
|
-
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
213
183
|
|
214
184
|
|
215
185
|
request_headers = {}
|
186
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
216
187
|
|
217
188
|
# Set Headers
|
218
189
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
219
190
|
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
220
191
|
|
221
|
-
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
222
|
-
|
223
192
|
# Serialize Request
|
224
|
-
request_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::
|
193
|
+
request_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::CreateOrUpdateTrustedIdProviderParameters.mapper()
|
225
194
|
request_content = @client.serialize(request_mapper, parameters)
|
226
195
|
request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
|
227
196
|
|
@@ -231,13 +200,13 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
231
200
|
|
232
201
|
options = {
|
233
202
|
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
234
|
-
path_params: {'resourceGroupName' => resource_group_name,'accountName' => account_name,'trustedIdProviderName' => trusted_id_provider_name
|
203
|
+
path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'accountName' => account_name,'trustedIdProviderName' => trusted_id_provider_name},
|
235
204
|
query_params: {'api-version' => @client.api_version},
|
236
205
|
body: request_content,
|
237
206
|
headers: request_headers.merge(custom_headers || {}),
|
238
207
|
base_url: request_url
|
239
208
|
}
|
240
|
-
promise = @client.make_request_async(:
|
209
|
+
promise = @client.make_request_async(:put, path_template, options)
|
241
210
|
|
242
211
|
promise = promise.then do |result|
|
243
212
|
http_response = result.response
|
@@ -267,67 +236,60 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
267
236
|
end
|
268
237
|
|
269
238
|
#
|
270
|
-
#
|
271
|
-
# Store account
|
239
|
+
# Gets the specified Data Lake Store trusted identity provider.
|
272
240
|
#
|
273
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
274
|
-
#
|
275
|
-
# @param account_name [String] The name of the Data Lake Store account from
|
276
|
-
# which to delete the trusted identity provider.
|
241
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
242
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
277
243
|
# @param trusted_id_provider_name [String] The name of the trusted identity
|
278
|
-
# provider to
|
244
|
+
# provider to retrieve.
|
279
245
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
280
246
|
# will be added to the HTTP request.
|
281
247
|
#
|
248
|
+
# @return [TrustedIdProvider] operation results.
|
282
249
|
#
|
283
|
-
def
|
284
|
-
response =
|
285
|
-
nil
|
250
|
+
def get(resource_group_name, account_name, trusted_id_provider_name, custom_headers:nil)
|
251
|
+
response = get_async(resource_group_name, account_name, trusted_id_provider_name, custom_headers:custom_headers).value!
|
252
|
+
response.body unless response.nil?
|
286
253
|
end
|
287
254
|
|
288
255
|
#
|
289
|
-
#
|
290
|
-
# Store account
|
256
|
+
# Gets the specified Data Lake Store trusted identity provider.
|
291
257
|
#
|
292
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
293
|
-
#
|
294
|
-
# @param account_name [String] The name of the Data Lake Store account from
|
295
|
-
# which to delete the trusted identity provider.
|
258
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
259
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
296
260
|
# @param trusted_id_provider_name [String] The name of the trusted identity
|
297
|
-
# provider to
|
261
|
+
# provider to retrieve.
|
298
262
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
299
263
|
# will be added to the HTTP request.
|
300
264
|
#
|
301
265
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
302
266
|
#
|
303
|
-
def
|
304
|
-
|
267
|
+
def get_with_http_info(resource_group_name, account_name, trusted_id_provider_name, custom_headers:nil)
|
268
|
+
get_async(resource_group_name, account_name, trusted_id_provider_name, custom_headers:custom_headers).value!
|
305
269
|
end
|
306
270
|
|
307
271
|
#
|
308
|
-
#
|
309
|
-
# Store account
|
272
|
+
# Gets the specified Data Lake Store trusted identity provider.
|
310
273
|
#
|
311
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
312
|
-
#
|
313
|
-
# @param account_name [String] The name of the Data Lake Store account from
|
314
|
-
# which to delete the trusted identity provider.
|
274
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
275
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
315
276
|
# @param trusted_id_provider_name [String] The name of the trusted identity
|
316
|
-
# provider to
|
277
|
+
# provider to retrieve.
|
317
278
|
# @param [Hash{String => String}] A hash of custom headers that will be added
|
318
279
|
# to the HTTP request.
|
319
280
|
#
|
320
281
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
321
282
|
#
|
322
|
-
def
|
283
|
+
def get_async(resource_group_name, account_name, trusted_id_provider_name, custom_headers:nil)
|
284
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
323
285
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
324
286
|
fail ArgumentError, 'account_name is nil' if account_name.nil?
|
325
287
|
fail ArgumentError, 'trusted_id_provider_name is nil' if trusted_id_provider_name.nil?
|
326
288
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
327
|
-
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
328
289
|
|
329
290
|
|
330
291
|
request_headers = {}
|
292
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
331
293
|
|
332
294
|
# Set Headers
|
333
295
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -338,23 +300,33 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
338
300
|
|
339
301
|
options = {
|
340
302
|
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
341
|
-
path_params: {'resourceGroupName' => resource_group_name,'accountName' => account_name,'trustedIdProviderName' => trusted_id_provider_name
|
303
|
+
path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'accountName' => account_name,'trustedIdProviderName' => trusted_id_provider_name},
|
342
304
|
query_params: {'api-version' => @client.api_version},
|
343
305
|
headers: request_headers.merge(custom_headers || {}),
|
344
306
|
base_url: request_url
|
345
307
|
}
|
346
|
-
promise = @client.make_request_async(:
|
308
|
+
promise = @client.make_request_async(:get, path_template, options)
|
347
309
|
|
348
310
|
promise = promise.then do |result|
|
349
311
|
http_response = result.response
|
350
312
|
status_code = http_response.status
|
351
313
|
response_content = http_response.body
|
352
|
-
unless status_code == 200
|
314
|
+
unless status_code == 200
|
353
315
|
error_model = JSON.load(response_content)
|
354
316
|
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
355
317
|
end
|
356
318
|
|
357
319
|
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
320
|
+
# Deserialize Response
|
321
|
+
if status_code == 200
|
322
|
+
begin
|
323
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
324
|
+
result_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::TrustedIdProvider.mapper()
|
325
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
326
|
+
rescue Exception => e
|
327
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
328
|
+
end
|
329
|
+
end
|
358
330
|
|
359
331
|
result
|
360
332
|
end
|
@@ -363,81 +335,89 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
363
335
|
end
|
364
336
|
|
365
337
|
#
|
366
|
-
#
|
338
|
+
# Updates the specified trusted identity provider.
|
367
339
|
#
|
368
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
369
|
-
#
|
370
|
-
# @param account_name [String] The name of the Data Lake Store account from
|
371
|
-
# which to get the trusted identity provider.
|
340
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
341
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
372
342
|
# @param trusted_id_provider_name [String] The name of the trusted identity
|
373
|
-
# provider
|
343
|
+
# provider. This is used for differentiation of providers in the account.
|
344
|
+
# @param parameters [UpdateTrustedIdProviderParameters] Parameters supplied to
|
345
|
+
# update the trusted identity provider.
|
374
346
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
375
347
|
# will be added to the HTTP request.
|
376
348
|
#
|
377
349
|
# @return [TrustedIdProvider] operation results.
|
378
350
|
#
|
379
|
-
def
|
380
|
-
response =
|
351
|
+
def update(resource_group_name, account_name, trusted_id_provider_name, parameters:nil, custom_headers:nil)
|
352
|
+
response = update_async(resource_group_name, account_name, trusted_id_provider_name, parameters:parameters, custom_headers:custom_headers).value!
|
381
353
|
response.body unless response.nil?
|
382
354
|
end
|
383
355
|
|
384
356
|
#
|
385
|
-
#
|
357
|
+
# Updates the specified trusted identity provider.
|
386
358
|
#
|
387
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
388
|
-
#
|
389
|
-
# @param account_name [String] The name of the Data Lake Store account from
|
390
|
-
# which to get the trusted identity provider.
|
359
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
360
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
391
361
|
# @param trusted_id_provider_name [String] The name of the trusted identity
|
392
|
-
# provider
|
362
|
+
# provider. This is used for differentiation of providers in the account.
|
363
|
+
# @param parameters [UpdateTrustedIdProviderParameters] Parameters supplied to
|
364
|
+
# update the trusted identity provider.
|
393
365
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
394
366
|
# will be added to the HTTP request.
|
395
367
|
#
|
396
368
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
397
369
|
#
|
398
|
-
def
|
399
|
-
|
370
|
+
def update_with_http_info(resource_group_name, account_name, trusted_id_provider_name, parameters:nil, custom_headers:nil)
|
371
|
+
update_async(resource_group_name, account_name, trusted_id_provider_name, parameters:parameters, custom_headers:custom_headers).value!
|
400
372
|
end
|
401
373
|
|
402
374
|
#
|
403
|
-
#
|
375
|
+
# Updates the specified trusted identity provider.
|
404
376
|
#
|
405
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
406
|
-
#
|
407
|
-
# @param account_name [String] The name of the Data Lake Store account from
|
408
|
-
# which to get the trusted identity provider.
|
377
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
378
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
409
379
|
# @param trusted_id_provider_name [String] The name of the trusted identity
|
410
|
-
# provider
|
380
|
+
# provider. This is used for differentiation of providers in the account.
|
381
|
+
# @param parameters [UpdateTrustedIdProviderParameters] Parameters supplied to
|
382
|
+
# update the trusted identity provider.
|
411
383
|
# @param [Hash{String => String}] A hash of custom headers that will be added
|
412
384
|
# to the HTTP request.
|
413
385
|
#
|
414
386
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
415
387
|
#
|
416
|
-
def
|
388
|
+
def update_async(resource_group_name, account_name, trusted_id_provider_name, parameters:nil, custom_headers:nil)
|
389
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
417
390
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
418
391
|
fail ArgumentError, 'account_name is nil' if account_name.nil?
|
419
392
|
fail ArgumentError, 'trusted_id_provider_name is nil' if trusted_id_provider_name.nil?
|
420
393
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
421
|
-
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
422
394
|
|
423
395
|
|
424
396
|
request_headers = {}
|
397
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
425
398
|
|
426
399
|
# Set Headers
|
427
400
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
428
401
|
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
402
|
+
|
403
|
+
# Serialize Request
|
404
|
+
request_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::UpdateTrustedIdProviderParameters.mapper()
|
405
|
+
request_content = @client.serialize(request_mapper, parameters)
|
406
|
+
request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
|
407
|
+
|
429
408
|
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/trustedIdProviders/{trustedIdProviderName}'
|
430
409
|
|
431
410
|
request_url = @base_url || @client.base_url
|
432
411
|
|
433
412
|
options = {
|
434
413
|
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
435
|
-
path_params: {'resourceGroupName' => resource_group_name,'accountName' => account_name,'trustedIdProviderName' => trusted_id_provider_name
|
414
|
+
path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'accountName' => account_name,'trustedIdProviderName' => trusted_id_provider_name},
|
436
415
|
query_params: {'api-version' => @client.api_version},
|
416
|
+
body: request_content,
|
437
417
|
headers: request_headers.merge(custom_headers || {}),
|
438
418
|
base_url: request_url
|
439
419
|
}
|
440
|
-
promise = @client.make_request_async(:
|
420
|
+
promise = @client.make_request_async(:patch, path_template, options)
|
441
421
|
|
442
422
|
promise = promise.then do |result|
|
443
423
|
http_response = result.response
|
@@ -467,98 +447,89 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
467
447
|
end
|
468
448
|
|
469
449
|
#
|
470
|
-
#
|
471
|
-
#
|
450
|
+
# Deletes the specified trusted identity provider from the specified Data Lake
|
451
|
+
# Store account
|
472
452
|
#
|
473
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
474
|
-
#
|
475
|
-
# @param
|
476
|
-
#
|
453
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
454
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
455
|
+
# @param trusted_id_provider_name [String] The name of the trusted identity
|
456
|
+
# provider to delete.
|
477
457
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
478
458
|
# will be added to the HTTP request.
|
479
459
|
#
|
480
|
-
# @return [Array<TrustedIdProvider>] operation results.
|
481
460
|
#
|
482
|
-
def
|
483
|
-
|
484
|
-
|
461
|
+
def delete(resource_group_name, account_name, trusted_id_provider_name, custom_headers:nil)
|
462
|
+
response = delete_async(resource_group_name, account_name, trusted_id_provider_name, custom_headers:custom_headers).value!
|
463
|
+
nil
|
485
464
|
end
|
486
465
|
|
487
466
|
#
|
488
|
-
#
|
489
|
-
#
|
467
|
+
# Deletes the specified trusted identity provider from the specified Data Lake
|
468
|
+
# Store account
|
490
469
|
#
|
491
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
492
|
-
#
|
493
|
-
# @param
|
494
|
-
#
|
470
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
471
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
472
|
+
# @param trusted_id_provider_name [String] The name of the trusted identity
|
473
|
+
# provider to delete.
|
495
474
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
496
475
|
# will be added to the HTTP request.
|
497
476
|
#
|
498
477
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
499
478
|
#
|
500
|
-
def
|
501
|
-
|
479
|
+
def delete_with_http_info(resource_group_name, account_name, trusted_id_provider_name, custom_headers:nil)
|
480
|
+
delete_async(resource_group_name, account_name, trusted_id_provider_name, custom_headers:custom_headers).value!
|
502
481
|
end
|
503
482
|
|
504
483
|
#
|
505
|
-
#
|
506
|
-
#
|
484
|
+
# Deletes the specified trusted identity provider from the specified Data Lake
|
485
|
+
# Store account
|
507
486
|
#
|
508
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
509
|
-
#
|
510
|
-
# @param
|
511
|
-
#
|
487
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
488
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
489
|
+
# @param trusted_id_provider_name [String] The name of the trusted identity
|
490
|
+
# provider to delete.
|
512
491
|
# @param [Hash{String => String}] A hash of custom headers that will be added
|
513
492
|
# to the HTTP request.
|
514
493
|
#
|
515
494
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
516
495
|
#
|
517
|
-
def
|
496
|
+
def delete_async(resource_group_name, account_name, trusted_id_provider_name, custom_headers:nil)
|
497
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
518
498
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
519
499
|
fail ArgumentError, 'account_name is nil' if account_name.nil?
|
500
|
+
fail ArgumentError, 'trusted_id_provider_name is nil' if trusted_id_provider_name.nil?
|
520
501
|
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
521
|
-
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
522
502
|
|
523
503
|
|
524
504
|
request_headers = {}
|
505
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
525
506
|
|
526
507
|
# Set Headers
|
527
508
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
528
509
|
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
529
|
-
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/trustedIdProviders'
|
510
|
+
path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/trustedIdProviders/{trustedIdProviderName}'
|
530
511
|
|
531
512
|
request_url = @base_url || @client.base_url
|
532
513
|
|
533
514
|
options = {
|
534
515
|
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
535
|
-
path_params: {'resourceGroupName' => resource_group_name,'accountName' => account_name,'
|
516
|
+
path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'accountName' => account_name,'trustedIdProviderName' => trusted_id_provider_name},
|
536
517
|
query_params: {'api-version' => @client.api_version},
|
537
518
|
headers: request_headers.merge(custom_headers || {}),
|
538
519
|
base_url: request_url
|
539
520
|
}
|
540
|
-
promise = @client.make_request_async(:
|
521
|
+
promise = @client.make_request_async(:delete, path_template, options)
|
541
522
|
|
542
523
|
promise = promise.then do |result|
|
543
524
|
http_response = result.response
|
544
525
|
status_code = http_response.status
|
545
526
|
response_content = http_response.body
|
546
|
-
unless status_code == 200
|
527
|
+
unless status_code == 200 || status_code == 204
|
547
528
|
error_model = JSON.load(response_content)
|
548
529
|
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
549
530
|
end
|
550
531
|
|
551
532
|
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
552
|
-
# Deserialize Response
|
553
|
-
if status_code == 200
|
554
|
-
begin
|
555
|
-
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
556
|
-
result_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::DataLakeStoreTrustedIdProviderListResult.mapper()
|
557
|
-
result.body = @client.deserialize(result_mapper, parsed_response)
|
558
|
-
rescue Exception => e
|
559
|
-
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
560
|
-
end
|
561
|
-
end
|
562
533
|
|
563
534
|
result
|
564
535
|
end
|
@@ -575,10 +546,10 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
575
546
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
576
547
|
# will be added to the HTTP request.
|
577
548
|
#
|
578
|
-
# @return [
|
549
|
+
# @return [TrustedIdProviderListResult] operation results.
|
579
550
|
#
|
580
|
-
def list_by_account_next(next_page_link, custom_headers
|
581
|
-
response = list_by_account_next_async(next_page_link, custom_headers).value!
|
551
|
+
def list_by_account_next(next_page_link, custom_headers:nil)
|
552
|
+
response = list_by_account_next_async(next_page_link, custom_headers:custom_headers).value!
|
582
553
|
response.body unless response.nil?
|
583
554
|
end
|
584
555
|
|
@@ -593,8 +564,8 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
593
564
|
#
|
594
565
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
595
566
|
#
|
596
|
-
def list_by_account_next_with_http_info(next_page_link, custom_headers
|
597
|
-
list_by_account_next_async(next_page_link, custom_headers).value!
|
567
|
+
def list_by_account_next_with_http_info(next_page_link, custom_headers:nil)
|
568
|
+
list_by_account_next_async(next_page_link, custom_headers:custom_headers).value!
|
598
569
|
end
|
599
570
|
|
600
571
|
#
|
@@ -608,11 +579,12 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
608
579
|
#
|
609
580
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
610
581
|
#
|
611
|
-
def list_by_account_next_async(next_page_link, custom_headers
|
582
|
+
def list_by_account_next_async(next_page_link, custom_headers:nil)
|
612
583
|
fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
|
613
584
|
|
614
585
|
|
615
586
|
request_headers = {}
|
587
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
616
588
|
|
617
589
|
# Set Headers
|
618
590
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -643,7 +615,7 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
643
615
|
if status_code == 200
|
644
616
|
begin
|
645
617
|
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
646
|
-
result_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::
|
618
|
+
result_mapper = Azure::DataLakeStore::Mgmt::V2016_11_01::Models::TrustedIdProviderListResult.mapper()
|
647
619
|
result.body = @client.deserialize(result_mapper, parsed_response)
|
648
620
|
rescue Exception => e
|
649
621
|
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
@@ -660,22 +632,20 @@ module Azure::DataLakeStore::Mgmt::V2016_11_01
|
|
660
632
|
# Lists the Data Lake Store trusted identity providers within the specified
|
661
633
|
# Data Lake Store account.
|
662
634
|
#
|
663
|
-
# @param resource_group_name [String] The name of the Azure resource group
|
664
|
-
#
|
665
|
-
# @param account_name [String] The name of the Data Lake Store account from
|
666
|
-
# which to get the trusted identity providers.
|
635
|
+
# @param resource_group_name [String] The name of the Azure resource group.
|
636
|
+
# @param account_name [String] The name of the Data Lake Store account.
|
667
637
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
668
638
|
# will be added to the HTTP request.
|
669
639
|
#
|
670
|
-
# @return [
|
671
|
-
#
|
640
|
+
# @return [TrustedIdProviderListResult] which provide lazy access to pages of
|
641
|
+
# the response.
|
672
642
|
#
|
673
|
-
def list_by_account_as_lazy(resource_group_name, account_name, custom_headers
|
674
|
-
response = list_by_account_async(resource_group_name, account_name, custom_headers).value!
|
643
|
+
def list_by_account_as_lazy(resource_group_name, account_name, custom_headers:nil)
|
644
|
+
response = list_by_account_async(resource_group_name, account_name, custom_headers:custom_headers).value!
|
675
645
|
unless response.nil?
|
676
646
|
page = response.body
|
677
647
|
page.next_method = Proc.new do |next_page_link|
|
678
|
-
list_by_account_next_async(next_page_link, custom_headers)
|
648
|
+
list_by_account_next_async(next_page_link, custom_headers:custom_headers)
|
679
649
|
end
|
680
650
|
page
|
681
651
|
end
|