azure_mgmt_operational_insights 0.15.2 → 0.18.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (150) hide show
  1. checksums.yaml +5 -5
  2. data/lib/2015-03-20/generated/azure_mgmt_operational_insights.rb +18 -10
  3. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/available_service_tier.rb +124 -0
  4. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/core_summary.rb +2 -2
  5. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/operation.rb +59 -0
  6. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/operation_display.rb +68 -0
  7. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/operation_list_result.rb +56 -0
  8. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/purge_state.rb +16 -0
  9. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/resource.rb +9 -0
  10. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/saved_search.rb +37 -13
  11. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/saved_searches_list_result.rb +3 -2
  12. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/search_get_schema_response.rb +1 -1
  13. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/search_metadata.rb +8 -8
  14. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/{search_highlight.rb → shared_keys.rb} +13 -13
  15. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/sku_name_enum.rb +21 -0
  16. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/storage_insight_list_result.rb +2 -3
  17. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/tag.rb +2 -2
  18. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/workspace_purge_body.rb +67 -0
  19. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/workspace_purge_body_filters.rb +85 -0
  20. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/workspace_purge_response.rb +47 -0
  21. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/workspace_purge_status_response.rb +47 -0
  22. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/operational_insights_management_client.rb +24 -10
  23. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/operations.rb +109 -0
  24. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/saved_searches.rb +78 -181
  25. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/storage_insights.rb +69 -82
  26. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/workspaces.rb +476 -119
  27. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights.rb +14 -8
  28. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/data_sources.rb +45 -32
  29. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/linked_services.rb +34 -24
  30. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/data_source_list_result.rb +1 -1
  31. data/lib/{2015-03-20/generated/azure_mgmt_operational_insights/models/search_error.rb → 2015-11-01-preview/generated/azure_mgmt_operational_insights/models/error_response.rb} +11 -11
  32. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/intelligence_pack.rb +11 -0
  33. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/operation.rb +59 -0
  34. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/operation_display.rb +68 -0
  35. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/operation_list_result.rb +101 -0
  36. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/operation_status.rb +102 -0
  37. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/resource.rb +10 -1
  38. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/sku.rb +2 -1
  39. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/sku_name_enum.rb +2 -1
  40. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/workspace.rb +10 -11
  41. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/workspace_list_management_groups_result.rb +1 -1
  42. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/operational_insights_management_client.rb +239 -0
  43. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/operations.rb +219 -0
  44. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/workspaces.rb +202 -63
  45. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights.rb +123 -0
  46. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/available_service_tiers.rb +146 -0
  47. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/clusters.rb +959 -0
  48. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/data_exports.rb +523 -0
  49. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/data_sources.rb +603 -0
  50. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/deleted_workspaces.rb +211 -0
  51. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/gateways.rb +123 -0
  52. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/intelligence_packs.rb +351 -0
  53. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/linked_services.rb +577 -0
  54. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/linked_storage_accounts.rb +481 -0
  55. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/management_groups.rb +130 -0
  56. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/available_service_tier.rb +124 -0
  57. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/azure_entity_resource.rb +75 -0
  58. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster.rb +159 -0
  59. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_entity_status.rb +21 -0
  60. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_error_response.rb +48 -0
  61. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_list_result.rb +98 -0
  62. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_patch.rb +78 -0
  63. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_sku.rb +58 -0
  64. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_sku_name_enum.rb +15 -0
  65. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/core_summary.rb +57 -0
  66. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_export.rb +174 -0
  67. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_export_error_response.rb +48 -0
  68. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_export_list_result.rb +56 -0
  69. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_ingestion_status.rb +20 -0
  70. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_source.rb +130 -0
  71. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_source_filter.rb +61 -0
  72. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_source_kind.rb +47 -0
  73. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_source_list_result.rb +98 -0
  74. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_source_type.rb +16 -0
  75. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/error_additional_info.rb +59 -0
  76. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/error_contract.rb +49 -0
  77. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/error_response.rb +113 -0
  78. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/identity.rb +72 -0
  79. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/identity_type.rb +16 -0
  80. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/intelligence_pack.rb +69 -0
  81. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/key_vault_properties.rb +71 -0
  82. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/linked_service.rb +120 -0
  83. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/linked_service_entity_status.rb +18 -0
  84. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/linked_service_list_result.rb +55 -0
  85. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/linked_storage_accounts_list_result.rb +56 -0
  86. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/linked_storage_accounts_resource.rb +95 -0
  87. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/management_group.rb +128 -0
  88. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/metric_name.rb +57 -0
  89. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/operation.rb +59 -0
  90. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/operation_display.rb +79 -0
  91. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/operation_list_result.rb +101 -0
  92. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/operation_status.rb +102 -0
  93. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/private_link_scoped_resource.rb +58 -0
  94. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/proxy_resource.rb +63 -0
  95. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/public_network_access_type.rb +16 -0
  96. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/purge_state.rb +16 -0
  97. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/resource.rb +83 -0
  98. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/saved_search.rb +165 -0
  99. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/saved_searches_list_result.rb +55 -0
  100. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_get_schema_response.rb +67 -0
  101. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_metadata.rb +241 -0
  102. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_metadata_schema.rb +57 -0
  103. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_schema_value.rb +123 -0
  104. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_sort.rb +58 -0
  105. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_sort_enum.rb +16 -0
  106. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/shared_keys.rb +57 -0
  107. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/sku_name_enum.rb +21 -0
  108. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/storage_account.rb +58 -0
  109. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/storage_insight.rb +157 -0
  110. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/storage_insight_list_result.rb +98 -0
  111. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/storage_insight_state.rb +16 -0
  112. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/storage_insight_status.rb +58 -0
  113. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/table.rb +79 -0
  114. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/tables_list_result.rb +55 -0
  115. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/tag.rb +57 -0
  116. data/lib/{2015-03-20/generated/azure_mgmt_operational_insights/models/search_results_response.rb → 2020-03-01-preview/generated/azure_mgmt_operational_insights/models/tracked_resource.rb} +33 -31
  117. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/type.rb +16 -0
  118. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/usage_metric.rb +103 -0
  119. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace.rb +214 -0
  120. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_capping.rb +73 -0
  121. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_entity_status.rb +21 -0
  122. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_list_management_groups_result.rb +56 -0
  123. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_list_result.rb +55 -0
  124. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_list_usages_result.rb +56 -0
  125. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_patch.rb +207 -0
  126. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_purge_body.rb +67 -0
  127. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_purge_body_filters.rb +85 -0
  128. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_purge_response.rb +47 -0
  129. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_purge_status_response.rb +47 -0
  130. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_sku.rb +85 -0
  131. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_sku_name_enum.rb +21 -0
  132. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/module_definition.rb +9 -0
  133. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/operation_statuses.rb +121 -0
  134. data/lib/{2015-11-01-preview/generated/azure_mgmt_operational_insights/azure_log_analytics.rb → 2020-03-01-preview/generated/azure_mgmt_operational_insights/operational_insights_management_client.rb} +89 -19
  135. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/operations.rb +220 -0
  136. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/saved_searches.rb +457 -0
  137. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/schema.rb +130 -0
  138. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/shared_keys_operations.rb +238 -0
  139. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/storage_insight_configs.rb +592 -0
  140. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/tables.rb +359 -0
  141. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/usages.rb +130 -0
  142. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/workspace_purge.rb +277 -0
  143. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/workspaces.rb +768 -0
  144. data/lib/azure_mgmt_operational_insights.rb +1 -0
  145. data/lib/profiles/latest/modules/operationalinsights_profile_module.rb +382 -180
  146. data/lib/profiles/latest/operationalinsights_latest_profile_client.rb +28 -9
  147. data/lib/profiles/latest/operationalinsights_module_definition.rb +0 -1
  148. data/lib/version.rb +1 -1
  149. metadata +123 -10
  150. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/search_parameters.rb +0 -94
@@ -5,7 +5,7 @@
5
5
 
6
6
  module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
7
7
  #
8
- # Azure Log Analytics API reference
8
+ # Operational Insights Client
9
9
  #
10
10
  class Workspaces
11
11
  include MsRestAzure
@@ -18,7 +18,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
18
18
  @client = client
19
19
  end
20
20
 
21
- # @return [AzureLogAnalytics] reference to the AzureLogAnalytics
21
+ # @return [OperationalInsightsManagementClient] reference to the OperationalInsightsManagementClient
22
22
  attr_reader :client
23
23
 
24
24
  #
@@ -33,8 +33,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
33
33
  # will be added to the HTTP request.
34
34
  #
35
35
  #
36
- def disable_intelligence_pack(resource_group_name, workspace_name, intelligence_pack_name, custom_headers = nil)
37
- response = disable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers).value!
36
+ def disable_intelligence_pack(resource_group_name, workspace_name, intelligence_pack_name, custom_headers:nil)
37
+ response = disable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers:custom_headers).value!
38
38
  nil
39
39
  end
40
40
 
@@ -51,8 +51,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
51
51
  #
52
52
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
53
53
  #
54
- def disable_intelligence_pack_with_http_info(resource_group_name, workspace_name, intelligence_pack_name, custom_headers = nil)
55
- disable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers).value!
54
+ def disable_intelligence_pack_with_http_info(resource_group_name, workspace_name, intelligence_pack_name, custom_headers:nil)
55
+ disable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers:custom_headers).value!
56
56
  end
57
57
 
58
58
  #
@@ -68,7 +68,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
68
68
  #
69
69
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
70
70
  #
71
- def disable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers = nil)
71
+ def disable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers:nil)
72
72
  fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
73
73
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
74
74
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
@@ -80,6 +80,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
80
80
 
81
81
 
82
82
  request_headers = {}
83
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
83
84
 
84
85
  # Set Headers
85
86
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -107,6 +108,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
107
108
  end
108
109
 
109
110
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
111
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
112
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
110
113
 
111
114
  result
112
115
  end
@@ -126,8 +129,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
126
129
  # will be added to the HTTP request.
127
130
  #
128
131
  #
129
- def enable_intelligence_pack(resource_group_name, workspace_name, intelligence_pack_name, custom_headers = nil)
130
- response = enable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers).value!
132
+ def enable_intelligence_pack(resource_group_name, workspace_name, intelligence_pack_name, custom_headers:nil)
133
+ response = enable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers:custom_headers).value!
131
134
  nil
132
135
  end
133
136
 
@@ -144,8 +147,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
144
147
  #
145
148
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
146
149
  #
147
- def enable_intelligence_pack_with_http_info(resource_group_name, workspace_name, intelligence_pack_name, custom_headers = nil)
148
- enable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers).value!
150
+ def enable_intelligence_pack_with_http_info(resource_group_name, workspace_name, intelligence_pack_name, custom_headers:nil)
151
+ enable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers:custom_headers).value!
149
152
  end
150
153
 
151
154
  #
@@ -161,7 +164,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
161
164
  #
162
165
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
163
166
  #
164
- def enable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers = nil)
167
+ def enable_intelligence_pack_async(resource_group_name, workspace_name, intelligence_pack_name, custom_headers:nil)
165
168
  fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
166
169
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
167
170
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
@@ -173,6 +176,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
173
176
 
174
177
 
175
178
  request_headers = {}
179
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
176
180
 
177
181
  # Set Headers
178
182
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -200,6 +204,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
200
204
  end
201
205
 
202
206
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
207
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
208
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
203
209
 
204
210
  result
205
211
  end
@@ -219,8 +225,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
219
225
  #
220
226
  # @return [Array] operation results.
221
227
  #
222
- def list_intelligence_packs(resource_group_name, workspace_name, custom_headers = nil)
223
- response = list_intelligence_packs_async(resource_group_name, workspace_name, custom_headers).value!
228
+ def list_intelligence_packs(resource_group_name, workspace_name, custom_headers:nil)
229
+ response = list_intelligence_packs_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
224
230
  response.body unless response.nil?
225
231
  end
226
232
 
@@ -236,8 +242,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
236
242
  #
237
243
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
238
244
  #
239
- def list_intelligence_packs_with_http_info(resource_group_name, workspace_name, custom_headers = nil)
240
- list_intelligence_packs_async(resource_group_name, workspace_name, custom_headers).value!
245
+ def list_intelligence_packs_with_http_info(resource_group_name, workspace_name, custom_headers:nil)
246
+ list_intelligence_packs_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
241
247
  end
242
248
 
243
249
  #
@@ -252,7 +258,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
252
258
  #
253
259
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
254
260
  #
255
- def list_intelligence_packs_async(resource_group_name, workspace_name, custom_headers = nil)
261
+ def list_intelligence_packs_async(resource_group_name, workspace_name, custom_headers:nil)
256
262
  fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
257
263
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
258
264
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
@@ -263,6 +269,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
263
269
 
264
270
 
265
271
  request_headers = {}
272
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
266
273
 
267
274
  # Set Headers
268
275
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -290,6 +297,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
290
297
  end
291
298
 
292
299
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
300
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
301
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
293
302
  # Deserialize Response
294
303
  if status_code == 200
295
304
  begin
@@ -334,8 +343,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
334
343
  #
335
344
  # @return [SharedKeys] operation results.
336
345
  #
337
- def get_shared_keys(resource_group_name, workspace_name, custom_headers = nil)
338
- response = get_shared_keys_async(resource_group_name, workspace_name, custom_headers).value!
346
+ def get_shared_keys(resource_group_name, workspace_name, custom_headers:nil)
347
+ response = get_shared_keys_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
339
348
  response.body unless response.nil?
340
349
  end
341
350
 
@@ -350,8 +359,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
350
359
  #
351
360
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
352
361
  #
353
- def get_shared_keys_with_http_info(resource_group_name, workspace_name, custom_headers = nil)
354
- get_shared_keys_async(resource_group_name, workspace_name, custom_headers).value!
362
+ def get_shared_keys_with_http_info(resource_group_name, workspace_name, custom_headers:nil)
363
+ get_shared_keys_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
355
364
  end
356
365
 
357
366
  #
@@ -365,7 +374,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
365
374
  #
366
375
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
367
376
  #
368
- def get_shared_keys_async(resource_group_name, workspace_name, custom_headers = nil)
377
+ def get_shared_keys_async(resource_group_name, workspace_name, custom_headers:nil)
369
378
  fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
370
379
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
371
380
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
@@ -376,6 +385,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
376
385
 
377
386
 
378
387
  request_headers = {}
388
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
379
389
 
380
390
  # Set Headers
381
391
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -403,6 +413,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
403
413
  end
404
414
 
405
415
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
416
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
417
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
406
418
  # Deserialize Response
407
419
  if status_code == 200
408
420
  begin
@@ -431,8 +443,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
431
443
  #
432
444
  # @return [WorkspaceListUsagesResult] operation results.
433
445
  #
434
- def list_usages(resource_group_name, workspace_name, custom_headers = nil)
435
- response = list_usages_async(resource_group_name, workspace_name, custom_headers).value!
446
+ def list_usages(resource_group_name, workspace_name, custom_headers:nil)
447
+ response = list_usages_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
436
448
  response.body unless response.nil?
437
449
  end
438
450
 
@@ -447,8 +459,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
447
459
  #
448
460
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
449
461
  #
450
- def list_usages_with_http_info(resource_group_name, workspace_name, custom_headers = nil)
451
- list_usages_async(resource_group_name, workspace_name, custom_headers).value!
462
+ def list_usages_with_http_info(resource_group_name, workspace_name, custom_headers:nil)
463
+ list_usages_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
452
464
  end
453
465
 
454
466
  #
@@ -462,7 +474,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
462
474
  #
463
475
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
464
476
  #
465
- def list_usages_async(resource_group_name, workspace_name, custom_headers = nil)
477
+ def list_usages_async(resource_group_name, workspace_name, custom_headers:nil)
466
478
  fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
467
479
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
468
480
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
@@ -473,6 +485,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
473
485
 
474
486
 
475
487
  request_headers = {}
488
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
476
489
 
477
490
  # Set Headers
478
491
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -500,6 +513,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
500
513
  end
501
514
 
502
515
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
516
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
517
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
503
518
  # Deserialize Response
504
519
  if status_code == 200
505
520
  begin
@@ -528,8 +543,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
528
543
  #
529
544
  # @return [WorkspaceListManagementGroupsResult] operation results.
530
545
  #
531
- def list_management_groups(resource_group_name, workspace_name, custom_headers = nil)
532
- response = list_management_groups_async(resource_group_name, workspace_name, custom_headers).value!
546
+ def list_management_groups(resource_group_name, workspace_name, custom_headers:nil)
547
+ response = list_management_groups_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
533
548
  response.body unless response.nil?
534
549
  end
535
550
 
@@ -544,8 +559,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
544
559
  #
545
560
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
546
561
  #
547
- def list_management_groups_with_http_info(resource_group_name, workspace_name, custom_headers = nil)
548
- list_management_groups_async(resource_group_name, workspace_name, custom_headers).value!
562
+ def list_management_groups_with_http_info(resource_group_name, workspace_name, custom_headers:nil)
563
+ list_management_groups_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
549
564
  end
550
565
 
551
566
  #
@@ -559,7 +574,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
559
574
  #
560
575
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
561
576
  #
562
- def list_management_groups_async(resource_group_name, workspace_name, custom_headers = nil)
577
+ def list_management_groups_async(resource_group_name, workspace_name, custom_headers:nil)
563
578
  fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
564
579
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
565
580
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
@@ -570,6 +585,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
570
585
 
571
586
 
572
587
  request_headers = {}
588
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
573
589
 
574
590
  # Set Headers
575
591
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -597,6 +613,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
597
613
  end
598
614
 
599
615
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
616
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
617
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
600
618
  # Deserialize Response
601
619
  if status_code == 200
602
620
  begin
@@ -624,8 +642,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
624
642
  #
625
643
  # @return [WorkspaceListResult] operation results.
626
644
  #
627
- def list_by_resource_group(resource_group_name, custom_headers = nil)
628
- response = list_by_resource_group_async(resource_group_name, custom_headers).value!
645
+ def list_by_resource_group(resource_group_name, custom_headers:nil)
646
+ response = list_by_resource_group_async(resource_group_name, custom_headers:custom_headers).value!
629
647
  response.body unless response.nil?
630
648
  end
631
649
 
@@ -639,8 +657,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
639
657
  #
640
658
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
641
659
  #
642
- def list_by_resource_group_with_http_info(resource_group_name, custom_headers = nil)
643
- list_by_resource_group_async(resource_group_name, custom_headers).value!
660
+ def list_by_resource_group_with_http_info(resource_group_name, custom_headers:nil)
661
+ list_by_resource_group_async(resource_group_name, custom_headers:custom_headers).value!
644
662
  end
645
663
 
646
664
  #
@@ -653,7 +671,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
653
671
  #
654
672
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
655
673
  #
656
- def list_by_resource_group_async(resource_group_name, custom_headers = nil)
674
+ def list_by_resource_group_async(resource_group_name, custom_headers:nil)
657
675
  fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
658
676
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
659
677
  fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
@@ -663,6 +681,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
663
681
 
664
682
 
665
683
  request_headers = {}
684
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
666
685
 
667
686
  # Set Headers
668
687
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -690,6 +709,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
690
709
  end
691
710
 
692
711
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
712
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
713
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
693
714
  # Deserialize Response
694
715
  if status_code == 200
695
716
  begin
@@ -715,8 +736,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
715
736
  #
716
737
  # @return [WorkspaceListResult] operation results.
717
738
  #
718
- def list(custom_headers = nil)
719
- response = list_async(custom_headers).value!
739
+ def list(custom_headers:nil)
740
+ response = list_async(custom_headers:custom_headers).value!
720
741
  response.body unless response.nil?
721
742
  end
722
743
 
@@ -728,8 +749,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
728
749
  #
729
750
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
730
751
  #
731
- def list_with_http_info(custom_headers = nil)
732
- list_async(custom_headers).value!
752
+ def list_with_http_info(custom_headers:nil)
753
+ list_async(custom_headers:custom_headers).value!
733
754
  end
734
755
 
735
756
  #
@@ -740,12 +761,13 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
740
761
  #
741
762
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
742
763
  #
743
- def list_async(custom_headers = nil)
764
+ def list_async(custom_headers:nil)
744
765
  fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
745
766
  fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
746
767
 
747
768
 
748
769
  request_headers = {}
770
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
749
771
 
750
772
  # Set Headers
751
773
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -773,6 +795,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
773
795
  end
774
796
 
775
797
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
798
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
799
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
776
800
  # Deserialize Response
777
801
  if status_code == 200
778
802
  begin
@@ -802,8 +826,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
802
826
  #
803
827
  # @return [Workspace] operation results.
804
828
  #
805
- def create_or_update(resource_group_name, workspace_name, parameters, custom_headers = nil)
806
- response = create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers).value!
829
+ def create_or_update(resource_group_name, workspace_name, parameters, custom_headers:nil)
830
+ response = create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers:custom_headers).value!
807
831
  response.body unless response.nil?
808
832
  end
809
833
 
@@ -818,9 +842,9 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
818
842
  # @return [Concurrent::Promise] promise which provides async access to http
819
843
  # response.
820
844
  #
821
- def create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers = nil)
845
+ def create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers:nil)
822
846
  # Send request
823
- promise = begin_create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers)
847
+ promise = begin_create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers:custom_headers)
824
848
 
825
849
  promise = promise.then do |response|
826
850
  # Defining deserialization method.
@@ -845,8 +869,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
845
869
  # will be added to the HTTP request.
846
870
  #
847
871
  #
848
- def delete(resource_group_name, workspace_name, custom_headers = nil)
849
- response = delete_async(resource_group_name, workspace_name, custom_headers).value!
872
+ def delete(resource_group_name, workspace_name, custom_headers:nil)
873
+ response = delete_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
850
874
  nil
851
875
  end
852
876
 
@@ -860,8 +884,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
860
884
  #
861
885
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
862
886
  #
863
- def delete_with_http_info(resource_group_name, workspace_name, custom_headers = nil)
864
- delete_async(resource_group_name, workspace_name, custom_headers).value!
887
+ def delete_with_http_info(resource_group_name, workspace_name, custom_headers:nil)
888
+ delete_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
865
889
  end
866
890
 
867
891
  #
@@ -874,7 +898,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
874
898
  #
875
899
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
876
900
  #
877
- def delete_async(resource_group_name, workspace_name, custom_headers = nil)
901
+ def delete_async(resource_group_name, workspace_name, custom_headers:nil)
878
902
  fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
879
903
  fail ArgumentError, 'workspace_name is nil' if workspace_name.nil?
880
904
  fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
@@ -882,6 +906,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
882
906
 
883
907
 
884
908
  request_headers = {}
909
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
885
910
 
886
911
  # Set Headers
887
912
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -909,6 +934,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
909
934
  end
910
935
 
911
936
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
937
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
938
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
912
939
 
913
940
  result
914
941
  end
@@ -926,8 +953,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
926
953
  #
927
954
  # @return [Workspace] operation results.
928
955
  #
929
- def get(resource_group_name, workspace_name, custom_headers = nil)
930
- response = get_async(resource_group_name, workspace_name, custom_headers).value!
956
+ def get(resource_group_name, workspace_name, custom_headers:nil)
957
+ response = get_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
931
958
  response.body unless response.nil?
932
959
  end
933
960
 
@@ -941,8 +968,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
941
968
  #
942
969
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
943
970
  #
944
- def get_with_http_info(resource_group_name, workspace_name, custom_headers = nil)
945
- get_async(resource_group_name, workspace_name, custom_headers).value!
971
+ def get_with_http_info(resource_group_name, workspace_name, custom_headers:nil)
972
+ get_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
946
973
  end
947
974
 
948
975
  #
@@ -955,7 +982,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
955
982
  #
956
983
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
957
984
  #
958
- def get_async(resource_group_name, workspace_name, custom_headers = nil)
985
+ def get_async(resource_group_name, workspace_name, custom_headers:nil)
959
986
  fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
960
987
  fail ArgumentError, 'workspace_name is nil' if workspace_name.nil?
961
988
  fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
@@ -963,6 +990,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
963
990
 
964
991
 
965
992
  request_headers = {}
993
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
966
994
 
967
995
  # Set Headers
968
996
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
@@ -990,6 +1018,116 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
990
1018
  end
991
1019
 
992
1020
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1021
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1022
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
1023
+ # Deserialize Response
1024
+ if status_code == 200
1025
+ begin
1026
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
1027
+ result_mapper = Azure::OperationalInsights::Mgmt::V2015_11_01_preview::Models::Workspace.mapper()
1028
+ result.body = @client.deserialize(result_mapper, parsed_response)
1029
+ rescue Exception => e
1030
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
1031
+ end
1032
+ end
1033
+
1034
+ result
1035
+ end
1036
+
1037
+ promise.execute
1038
+ end
1039
+
1040
+ #
1041
+ # Updates a workspace.
1042
+ #
1043
+ # @param resource_group_name [String] The resource group name of the workspace.
1044
+ # @param workspace_name [String] The name of the workspace.
1045
+ # @param parameters [Workspace] The parameters required to patch a workspace.
1046
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1047
+ # will be added to the HTTP request.
1048
+ #
1049
+ # @return [Workspace] operation results.
1050
+ #
1051
+ def update(resource_group_name, workspace_name, parameters, custom_headers:nil)
1052
+ response = update_async(resource_group_name, workspace_name, parameters, custom_headers:custom_headers).value!
1053
+ response.body unless response.nil?
1054
+ end
1055
+
1056
+ #
1057
+ # Updates a workspace.
1058
+ #
1059
+ # @param resource_group_name [String] The resource group name of the workspace.
1060
+ # @param workspace_name [String] The name of the workspace.
1061
+ # @param parameters [Workspace] The parameters required to patch a workspace.
1062
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
1063
+ # will be added to the HTTP request.
1064
+ #
1065
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
1066
+ #
1067
+ def update_with_http_info(resource_group_name, workspace_name, parameters, custom_headers:nil)
1068
+ update_async(resource_group_name, workspace_name, parameters, custom_headers:custom_headers).value!
1069
+ end
1070
+
1071
+ #
1072
+ # Updates a workspace.
1073
+ #
1074
+ # @param resource_group_name [String] The resource group name of the workspace.
1075
+ # @param workspace_name [String] The name of the workspace.
1076
+ # @param parameters [Workspace] The parameters required to patch a workspace.
1077
+ # @param [Hash{String => String}] A hash of custom headers that will be added
1078
+ # to the HTTP request.
1079
+ #
1080
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1081
+ #
1082
+ def update_async(resource_group_name, workspace_name, parameters, custom_headers:nil)
1083
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
1084
+ fail ArgumentError, 'workspace_name is nil' if workspace_name.nil?
1085
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MaxLength': '63'" if !workspace_name.nil? && workspace_name.length > 63
1086
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MinLength': '4'" if !workspace_name.nil? && workspace_name.length < 4
1087
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'Pattern': '^[A-Za-z0-9][A-Za-z0-9-]+[A-Za-z0-9]$'" if !workspace_name.nil? && workspace_name.match(Regexp.new('^^[A-Za-z0-9][A-Za-z0-9-]+[A-Za-z0-9]$$')).nil?
1088
+ fail ArgumentError, 'parameters is nil' if parameters.nil?
1089
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
1090
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
1091
+
1092
+
1093
+ request_headers = {}
1094
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1095
+
1096
+ # Set Headers
1097
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1098
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1099
+
1100
+ # Serialize Request
1101
+ request_mapper = Azure::OperationalInsights::Mgmt::V2015_11_01_preview::Models::Workspace.mapper()
1102
+ request_content = @client.serialize(request_mapper, parameters)
1103
+ request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
1104
+
1105
+ path_template = 'subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{workspaceName}'
1106
+
1107
+ request_url = @base_url || @client.base_url
1108
+
1109
+ options = {
1110
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
1111
+ path_params: {'resourceGroupName' => resource_group_name,'workspaceName' => workspace_name,'subscriptionId' => @client.subscription_id},
1112
+ query_params: {'api-version' => @client.api_version},
1113
+ body: request_content,
1114
+ headers: request_headers.merge(custom_headers || {}),
1115
+ base_url: request_url
1116
+ }
1117
+ promise = @client.make_request_async(:patch, path_template, options)
1118
+
1119
+ promise = promise.then do |result|
1120
+ http_response = result.response
1121
+ status_code = http_response.status
1122
+ response_content = http_response.body
1123
+ unless status_code == 200
1124
+ error_model = JSON.load(response_content)
1125
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
1126
+ end
1127
+
1128
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1129
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1130
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
993
1131
  # Deserialize Response
994
1132
  if status_code == 200
995
1133
  begin
@@ -1019,8 +1157,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
1019
1157
  #
1020
1158
  # @return [Workspace] operation results.
1021
1159
  #
1022
- def begin_create_or_update(resource_group_name, workspace_name, parameters, custom_headers = nil)
1023
- response = begin_create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers).value!
1160
+ def begin_create_or_update(resource_group_name, workspace_name, parameters, custom_headers:nil)
1161
+ response = begin_create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers:custom_headers).value!
1024
1162
  response.body unless response.nil?
1025
1163
  end
1026
1164
 
@@ -1036,8 +1174,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
1036
1174
  #
1037
1175
  # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
1038
1176
  #
1039
- def begin_create_or_update_with_http_info(resource_group_name, workspace_name, parameters, custom_headers = nil)
1040
- begin_create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers).value!
1177
+ def begin_create_or_update_with_http_info(resource_group_name, workspace_name, parameters, custom_headers:nil)
1178
+ begin_create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers:custom_headers).value!
1041
1179
  end
1042
1180
 
1043
1181
  #
@@ -1052,7 +1190,7 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
1052
1190
  #
1053
1191
  # @return [Concurrent::Promise] Promise object which holds the HTTP response.
1054
1192
  #
1055
- def begin_create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers = nil)
1193
+ def begin_create_or_update_async(resource_group_name, workspace_name, parameters, custom_headers:nil)
1056
1194
  fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
1057
1195
  fail ArgumentError, 'workspace_name is nil' if workspace_name.nil?
1058
1196
  fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MaxLength': '63'" if !workspace_name.nil? && workspace_name.length > 63
@@ -1064,13 +1202,12 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
1064
1202
 
1065
1203
 
1066
1204
  request_headers = {}
1205
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
1067
1206
 
1068
1207
  # Set Headers
1069
1208
  request_headers['x-ms-client-request-id'] = SecureRandom.uuid
1070
1209
  request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
1071
1210
 
1072
- request_headers['Content-Type'] = 'application/json; charset=utf-8'
1073
-
1074
1211
  # Serialize Request
1075
1212
  request_mapper = Azure::OperationalInsights::Mgmt::V2015_11_01_preview::Models::Workspace.mapper()
1076
1213
  request_content = @client.serialize(request_mapper, parameters)
@@ -1100,6 +1237,8 @@ module Azure::OperationalInsights::Mgmt::V2015_11_01_preview
1100
1237
  end
1101
1238
 
1102
1239
  result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
1240
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
1241
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
1103
1242
  # Deserialize Response
1104
1243
  if status_code == 200
1105
1244
  begin