azure_mgmt_operational_insights 0.17.1 → 0.19.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (234) hide show
  1. checksums.yaml +4 -4
  2. data/lib/2015-03-20/generated/azure_mgmt_operational_insights.rb +15 -16
  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/operation.rb +1 -1
  5. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/operation_display.rb +1 -1
  6. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/operation_list_result.rb +3 -3
  7. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/saved_search.rb +5 -5
  8. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/saved_searches_list_result.rb +4 -3
  9. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/{search_highlight.rb → shared_keys.rb} +13 -13
  10. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/sku_name_enum.rb +21 -0
  11. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/storage_insight_list_result.rb +2 -3
  12. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/workspace_purge_body_filters.rb +14 -1
  13. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/operational_insights_management_client.rb +3 -5
  14. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/operations.rb +2 -0
  15. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/saved_searches.rb +69 -175
  16. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/storage_insights.rb +36 -52
  17. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/workspaces.rb +319 -169
  18. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights.rb +9 -7
  19. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/data_sources.rb +10 -0
  20. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/linked_services.rb +8 -0
  21. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/data_source_list_result.rb +1 -1
  22. 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
  23. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/operation_list_result.rb +1 -1
  24. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/operation_status.rb +102 -0
  25. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/sku.rb +2 -2
  26. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/sku_name_enum.rb +1 -1
  27. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/workspace.rb +9 -10
  28. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/models/workspace_list_management_groups_result.rb +1 -1
  29. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/operational_insights_management_client.rb +95 -1
  30. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/operations.rb +4 -0
  31. data/lib/2015-11-01-preview/generated/azure_mgmt_operational_insights/workspaces.rb +24 -0
  32. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights.rb +123 -0
  33. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/available_service_tiers.rb +146 -0
  34. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/clusters.rb +959 -0
  35. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/data_exports.rb +473 -0
  36. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/data_sources.rb +603 -0
  37. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/deleted_workspaces.rb +211 -0
  38. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/gateways.rb +123 -0
  39. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/intelligence_packs.rb +351 -0
  40. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/linked_services.rb +577 -0
  41. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/linked_storage_accounts.rb +490 -0
  42. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/management_groups.rb +130 -0
  43. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/available_service_tier.rb +124 -0
  44. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/azure_entity_resource.rb +75 -0
  45. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster.rb +159 -0
  46. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_entity_status.rb +21 -0
  47. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_error_response.rb +48 -0
  48. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_list_result.rb +98 -0
  49. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_patch.rb +78 -0
  50. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_sku.rb +58 -0
  51. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/cluster_sku_name_enum.rb +15 -0
  52. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/core_summary.rb +57 -0
  53. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_export.rb +174 -0
  54. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_export_error_response.rb +48 -0
  55. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_export_list_result.rb +56 -0
  56. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_ingestion_status.rb +20 -0
  57. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_source.rb +130 -0
  58. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_source_filter.rb +61 -0
  59. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_source_kind.rb +47 -0
  60. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_source_list_result.rb +98 -0
  61. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/data_source_type.rb +19 -0
  62. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/error_additional_info.rb +59 -0
  63. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/error_contract.rb +49 -0
  64. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/error_response.rb +113 -0
  65. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/identity.rb +72 -0
  66. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/identity_type.rb +16 -0
  67. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/intelligence_pack.rb +69 -0
  68. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/key_vault_properties.rb +71 -0
  69. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/linked_service.rb +120 -0
  70. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/linked_service_entity_status.rb +18 -0
  71. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/linked_service_list_result.rb +55 -0
  72. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/linked_storage_accounts_list_result.rb +56 -0
  73. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/linked_storage_accounts_resource.rb +95 -0
  74. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/management_group.rb +128 -0
  75. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/metric_name.rb +57 -0
  76. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/operation.rb +59 -0
  77. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/operation_display.rb +79 -0
  78. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/operation_list_result.rb +101 -0
  79. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/operation_status.rb +102 -0
  80. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/private_link_scoped_resource.rb +58 -0
  81. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/proxy_resource.rb +63 -0
  82. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/public_network_access_type.rb +16 -0
  83. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/purge_state.rb +16 -0
  84. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/resource.rb +83 -0
  85. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/saved_search.rb +165 -0
  86. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/saved_searches_list_result.rb +55 -0
  87. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_get_schema_response.rb +67 -0
  88. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_metadata.rb +241 -0
  89. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_metadata_schema.rb +57 -0
  90. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_schema_value.rb +123 -0
  91. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_sort.rb +58 -0
  92. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/search_sort_enum.rb +16 -0
  93. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/shared_keys.rb +57 -0
  94. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/sku_name_enum.rb +21 -0
  95. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/storage_account.rb +58 -0
  96. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/storage_insight.rb +157 -0
  97. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/storage_insight_list_result.rb +98 -0
  98. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/storage_insight_state.rb +16 -0
  99. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/storage_insight_status.rb +58 -0
  100. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/table.rb +79 -0
  101. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/tables_list_result.rb +55 -0
  102. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/tag.rb +57 -0
  103. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/tracked_resource.rb +92 -0
  104. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/type.rb +16 -0
  105. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/usage_metric.rb +103 -0
  106. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace.rb +214 -0
  107. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_capping.rb +73 -0
  108. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_entity_status.rb +21 -0
  109. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_list_management_groups_result.rb +56 -0
  110. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_list_result.rb +55 -0
  111. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_list_usages_result.rb +56 -0
  112. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_patch.rb +207 -0
  113. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_purge_body.rb +67 -0
  114. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_purge_body_filters.rb +85 -0
  115. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_purge_response.rb +47 -0
  116. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_purge_status_response.rb +47 -0
  117. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_sku.rb +85 -0
  118. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/models/workspace_sku_name_enum.rb +21 -0
  119. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/module_definition.rb +9 -0
  120. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/operation_statuses.rb +121 -0
  121. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/operational_insights_management_client.rb +207 -0
  122. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/operations.rb +220 -0
  123. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/saved_searches.rb +457 -0
  124. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/schema.rb +130 -0
  125. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/shared_keys_operations.rb +238 -0
  126. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/storage_insight_configs.rb +592 -0
  127. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/tables.rb +359 -0
  128. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/usages.rb +130 -0
  129. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/workspace_purge.rb +277 -0
  130. data/lib/2020-03-01-preview/generated/azure_mgmt_operational_insights/workspaces.rb +768 -0
  131. data/lib/2020-08-01/generated/azure_mgmt_operational_insights.rb +123 -0
  132. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/available_service_tiers.rb +146 -0
  133. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/clusters.rb +959 -0
  134. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/data_exports.rb +473 -0
  135. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/data_sources.rb +603 -0
  136. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/deleted_workspaces.rb +211 -0
  137. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/gateways.rb +123 -0
  138. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/intelligence_packs.rb +351 -0
  139. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/linked_services.rb +577 -0
  140. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/linked_storage_accounts.rb +481 -0
  141. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/management_groups.rb +130 -0
  142. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/available_service_tier.rb +124 -0
  143. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/azure_entity_resource.rb +75 -0
  144. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/cluster.rb +159 -0
  145. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/cluster_entity_status.rb +21 -0
  146. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/cluster_error_response.rb +48 -0
  147. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/cluster_list_result.rb +98 -0
  148. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/cluster_patch.rb +78 -0
  149. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/cluster_sku.rb +58 -0
  150. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/cluster_sku_name_enum.rb +15 -0
  151. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/core_summary.rb +57 -0
  152. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/data_export.rb +174 -0
  153. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/data_export_error_response.rb +48 -0
  154. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/data_export_list_result.rb +56 -0
  155. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/data_ingestion_status.rb +20 -0
  156. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/data_source.rb +130 -0
  157. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/data_source_filter.rb +61 -0
  158. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/data_source_kind.rb +47 -0
  159. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/data_source_list_result.rb +98 -0
  160. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/data_source_type.rb +18 -0
  161. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/error_additional_info.rb +59 -0
  162. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/error_contract.rb +49 -0
  163. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/error_response.rb +113 -0
  164. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/identity.rb +72 -0
  165. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/identity_type.rb +16 -0
  166. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/intelligence_pack.rb +69 -0
  167. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/key_vault_properties.rb +71 -0
  168. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/linked_service.rb +120 -0
  169. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/linked_service_entity_status.rb +18 -0
  170. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/linked_service_list_result.rb +55 -0
  171. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/linked_storage_accounts_list_result.rb +56 -0
  172. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/linked_storage_accounts_resource.rb +95 -0
  173. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/management_group.rb +128 -0
  174. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/metric_name.rb +57 -0
  175. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/operation.rb +59 -0
  176. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/operation_display.rb +79 -0
  177. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/operation_list_result.rb +101 -0
  178. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/operation_status.rb +102 -0
  179. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/private_link_scoped_resource.rb +58 -0
  180. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/proxy_resource.rb +63 -0
  181. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/public_network_access_type.rb +16 -0
  182. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/purge_state.rb +16 -0
  183. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/resource.rb +83 -0
  184. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/saved_search.rb +165 -0
  185. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/saved_searches_list_result.rb +55 -0
  186. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/search_get_schema_response.rb +67 -0
  187. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/search_metadata.rb +241 -0
  188. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/search_metadata_schema.rb +57 -0
  189. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/search_schema_value.rb +123 -0
  190. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/search_sort.rb +58 -0
  191. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/search_sort_enum.rb +16 -0
  192. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/shared_keys.rb +57 -0
  193. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/sku_name_enum.rb +21 -0
  194. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/storage_account.rb +58 -0
  195. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/storage_insight.rb +157 -0
  196. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/storage_insight_list_result.rb +98 -0
  197. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/storage_insight_state.rb +16 -0
  198. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/storage_insight_status.rb +58 -0
  199. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/table.rb +79 -0
  200. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/tables_list_result.rb +55 -0
  201. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/tag.rb +57 -0
  202. data/lib/{2015-03-20/generated/azure_mgmt_operational_insights/models/search_results_response.rb → 2020-08-01/generated/azure_mgmt_operational_insights/models/tracked_resource.rb} +33 -31
  203. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/type.rb +16 -0
  204. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/usage_metric.rb +103 -0
  205. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace.rb +213 -0
  206. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_capping.rb +72 -0
  207. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_entity_status.rb +21 -0
  208. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_list_management_groups_result.rb +56 -0
  209. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_list_result.rb +55 -0
  210. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_list_usages_result.rb +56 -0
  211. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_patch.rb +206 -0
  212. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_purge_body.rb +67 -0
  213. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_purge_body_filters.rb +85 -0
  214. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_purge_response.rb +47 -0
  215. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_purge_status_response.rb +47 -0
  216. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_sku.rb +85 -0
  217. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/models/workspace_sku_name_enum.rb +21 -0
  218. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/module_definition.rb +9 -0
  219. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/operation_statuses.rb +121 -0
  220. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/operational_insights_management_client.rb +207 -0
  221. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/operations.rb +220 -0
  222. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/saved_searches.rb +457 -0
  223. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/schema.rb +130 -0
  224. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/shared_keys_operations.rb +238 -0
  225. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/storage_insight_configs.rb +592 -0
  226. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/tables.rb +359 -0
  227. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/usages.rb +130 -0
  228. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/workspace_purge.rb +277 -0
  229. data/lib/2020-08-01/generated/azure_mgmt_operational_insights/workspaces.rb +768 -0
  230. data/lib/azure_mgmt_operational_insights.rb +2 -0
  231. data/lib/profiles/latest/modules/operationalinsights_profile_module.rb +291 -145
  232. data/lib/version.rb +1 -1
  233. metadata +208 -9
  234. data/lib/2015-03-20/generated/azure_mgmt_operational_insights/models/search_parameters.rb +0 -94
@@ -0,0 +1,490 @@
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::OperationalInsights::Mgmt::V2020_03_01_preview
7
+ #
8
+ # Operational Insights Client
9
+ #
10
+ class LinkedStorageAccounts
11
+ include MsRestAzure
12
+
13
+ #
14
+ # Creates and initializes a new instance of the LinkedStorageAccounts class.
15
+ # @param client service class for accessing basic functionality.
16
+ #
17
+ def initialize(client)
18
+ @client = client
19
+ end
20
+
21
+ # @return [OperationalInsightsManagementClient] reference to the OperationalInsightsManagementClient
22
+ attr_reader :client
23
+
24
+ #
25
+ # Create or Update a link relation between current workspace and a group of
26
+ # storage accounts of a specific data source type.
27
+ #
28
+ # @param resource_group_name [String] The name of the resource group. The name
29
+ # is case insensitive.
30
+ # @param workspace_name [String] The name of the workspace.
31
+ # @param data_source_type [DataSourceType] Linked storage accounts type.
32
+ # Possible values include: 'CustomLogs', 'AzureWatson', 'Query', 'Ingestion',
33
+ # 'Alerts'
34
+ # @param parameters [LinkedStorageAccountsResource] The parameters required to
35
+ # create or update linked storage accounts.
36
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
37
+ # will be added to the HTTP request.
38
+ #
39
+ # @return [LinkedStorageAccountsResource] operation results.
40
+ #
41
+ def create_or_update(resource_group_name, workspace_name, data_source_type, parameters, custom_headers:nil)
42
+ response = create_or_update_async(resource_group_name, workspace_name, data_source_type, parameters, custom_headers:custom_headers).value!
43
+ response.body unless response.nil?
44
+ end
45
+
46
+ #
47
+ # Create or Update a link relation between current workspace and a group of
48
+ # storage accounts of a specific data source type.
49
+ #
50
+ # @param resource_group_name [String] The name of the resource group. The name
51
+ # is case insensitive.
52
+ # @param workspace_name [String] The name of the workspace.
53
+ # @param data_source_type [DataSourceType] Linked storage accounts type.
54
+ # Possible values include: 'CustomLogs', 'AzureWatson', 'Query', 'Ingestion',
55
+ # 'Alerts'
56
+ # @param parameters [LinkedStorageAccountsResource] The parameters required to
57
+ # create or update linked storage accounts.
58
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
59
+ # will be added to the HTTP request.
60
+ #
61
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
62
+ #
63
+ def create_or_update_with_http_info(resource_group_name, workspace_name, data_source_type, parameters, custom_headers:nil)
64
+ create_or_update_async(resource_group_name, workspace_name, data_source_type, parameters, custom_headers:custom_headers).value!
65
+ end
66
+
67
+ #
68
+ # Create or Update a link relation between current workspace and a group of
69
+ # storage accounts of a specific data source type.
70
+ #
71
+ # @param resource_group_name [String] The name of the resource group. The name
72
+ # is case insensitive.
73
+ # @param workspace_name [String] The name of the workspace.
74
+ # @param data_source_type [DataSourceType] Linked storage accounts type.
75
+ # Possible values include: 'CustomLogs', 'AzureWatson', 'Query', 'Ingestion',
76
+ # 'Alerts'
77
+ # @param parameters [LinkedStorageAccountsResource] The parameters required to
78
+ # create or update linked storage accounts.
79
+ # @param [Hash{String => String}] A hash of custom headers that will be added
80
+ # to the HTTP request.
81
+ #
82
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
83
+ #
84
+ def create_or_update_async(resource_group_name, workspace_name, data_source_type, parameters, custom_headers:nil)
85
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
86
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
87
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
88
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'Pattern': '^[-\w\._\(\)]+$'" if !resource_group_name.nil? && resource_group_name.match(Regexp.new('^^[-\w\._\(\)]+$$')).nil?
89
+ fail ArgumentError, 'workspace_name is nil' if workspace_name.nil?
90
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MaxLength': '63'" if !workspace_name.nil? && workspace_name.length > 63
91
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MinLength': '4'" if !workspace_name.nil? && workspace_name.length < 4
92
+ 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?
93
+ fail ArgumentError, 'data_source_type is nil' if data_source_type.nil?
94
+ fail ArgumentError, 'parameters is nil' if parameters.nil?
95
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
96
+ fail ArgumentError, "'@client.subscription_id' should satisfy the constraint - 'MinLength': '1'" if !@client.subscription_id.nil? && @client.subscription_id.length < 1
97
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
98
+ fail ArgumentError, "'@client.api_version' should satisfy the constraint - 'MinLength': '1'" if !@client.api_version.nil? && @client.api_version.length < 1
99
+
100
+
101
+ request_headers = {}
102
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
103
+
104
+ # Set Headers
105
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
106
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
107
+
108
+ # Serialize Request
109
+ request_mapper = Azure::OperationalInsights::Mgmt::V2020_03_01_preview::Models::LinkedStorageAccountsResource.mapper()
110
+ request_content = @client.serialize(request_mapper, parameters)
111
+ request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil
112
+
113
+ path_template = 'subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{workspaceName}/linkedStorageAccounts/{dataSourceType}'
114
+
115
+ request_url = @base_url || @client.base_url
116
+
117
+ options = {
118
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
119
+ path_params: {'resourceGroupName' => resource_group_name,'workspaceName' => workspace_name,'dataSourceType' => data_source_type,'subscriptionId' => @client.subscription_id},
120
+ query_params: {'api-version' => @client.api_version},
121
+ body: request_content,
122
+ headers: request_headers.merge(custom_headers || {}),
123
+ base_url: request_url
124
+ }
125
+ promise = @client.make_request_async(:put, path_template, options)
126
+
127
+ promise = promise.then do |result|
128
+ http_response = result.response
129
+ status_code = http_response.status
130
+ response_content = http_response.body
131
+ unless status_code == 200
132
+ error_model = JSON.load(response_content)
133
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
134
+ end
135
+
136
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
137
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
138
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
139
+ # Deserialize Response
140
+ if status_code == 200
141
+ begin
142
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
143
+ result_mapper = Azure::OperationalInsights::Mgmt::V2020_03_01_preview::Models::LinkedStorageAccountsResource.mapper()
144
+ result.body = @client.deserialize(result_mapper, parsed_response)
145
+ rescue Exception => e
146
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
147
+ end
148
+ end
149
+
150
+ result
151
+ end
152
+
153
+ promise.execute
154
+ end
155
+
156
+ #
157
+ # Deletes all linked storage accounts of a specific data source type associated
158
+ # with the specified workspace.
159
+ #
160
+ # @param resource_group_name [String] The name of the resource group. The name
161
+ # is case insensitive.
162
+ # @param workspace_name [String] The name of the workspace.
163
+ # @param data_source_type [DataSourceType] Linked storage accounts type.
164
+ # Possible values include: 'CustomLogs', 'AzureWatson', 'Query', 'Ingestion',
165
+ # 'Alerts'
166
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
167
+ # will be added to the HTTP request.
168
+ #
169
+ #
170
+ def delete(resource_group_name, workspace_name, data_source_type, custom_headers:nil)
171
+ response = delete_async(resource_group_name, workspace_name, data_source_type, custom_headers:custom_headers).value!
172
+ nil
173
+ end
174
+
175
+ #
176
+ # Deletes all linked storage accounts of a specific data source type associated
177
+ # with the specified workspace.
178
+ #
179
+ # @param resource_group_name [String] The name of the resource group. The name
180
+ # is case insensitive.
181
+ # @param workspace_name [String] The name of the workspace.
182
+ # @param data_source_type [DataSourceType] Linked storage accounts type.
183
+ # Possible values include: 'CustomLogs', 'AzureWatson', 'Query', 'Ingestion',
184
+ # 'Alerts'
185
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
186
+ # will be added to the HTTP request.
187
+ #
188
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
189
+ #
190
+ def delete_with_http_info(resource_group_name, workspace_name, data_source_type, custom_headers:nil)
191
+ delete_async(resource_group_name, workspace_name, data_source_type, custom_headers:custom_headers).value!
192
+ end
193
+
194
+ #
195
+ # Deletes all linked storage accounts of a specific data source type associated
196
+ # with the specified workspace.
197
+ #
198
+ # @param resource_group_name [String] The name of the resource group. The name
199
+ # is case insensitive.
200
+ # @param workspace_name [String] The name of the workspace.
201
+ # @param data_source_type [DataSourceType] Linked storage accounts type.
202
+ # Possible values include: 'CustomLogs', 'AzureWatson', 'Query', 'Ingestion',
203
+ # 'Alerts'
204
+ # @param [Hash{String => String}] A hash of custom headers that will be added
205
+ # to the HTTP request.
206
+ #
207
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
208
+ #
209
+ def delete_async(resource_group_name, workspace_name, data_source_type, custom_headers:nil)
210
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
211
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
212
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
213
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'Pattern': '^[-\w\._\(\)]+$'" if !resource_group_name.nil? && resource_group_name.match(Regexp.new('^^[-\w\._\(\)]+$$')).nil?
214
+ fail ArgumentError, 'workspace_name is nil' if workspace_name.nil?
215
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MaxLength': '63'" if !workspace_name.nil? && workspace_name.length > 63
216
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MinLength': '4'" if !workspace_name.nil? && workspace_name.length < 4
217
+ 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?
218
+ fail ArgumentError, 'data_source_type is nil' if data_source_type.nil?
219
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
220
+ fail ArgumentError, "'@client.api_version' should satisfy the constraint - 'MinLength': '1'" if !@client.api_version.nil? && @client.api_version.length < 1
221
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
222
+ fail ArgumentError, "'@client.subscription_id' should satisfy the constraint - 'MinLength': '1'" if !@client.subscription_id.nil? && @client.subscription_id.length < 1
223
+
224
+
225
+ request_headers = {}
226
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
227
+
228
+ # Set Headers
229
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
230
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
231
+ path_template = 'subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{workspaceName}/linkedStorageAccounts/{dataSourceType}'
232
+
233
+ request_url = @base_url || @client.base_url
234
+
235
+ options = {
236
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
237
+ path_params: {'resourceGroupName' => resource_group_name,'workspaceName' => workspace_name,'dataSourceType' => data_source_type,'subscriptionId' => @client.subscription_id},
238
+ query_params: {'api-version' => @client.api_version},
239
+ headers: request_headers.merge(custom_headers || {}),
240
+ base_url: request_url
241
+ }
242
+ promise = @client.make_request_async(:delete, path_template, options)
243
+
244
+ promise = promise.then do |result|
245
+ http_response = result.response
246
+ status_code = http_response.status
247
+ response_content = http_response.body
248
+ unless status_code == 200
249
+ error_model = JSON.load(response_content)
250
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
251
+ end
252
+
253
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
254
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
255
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
256
+
257
+ result
258
+ end
259
+
260
+ promise.execute
261
+ end
262
+
263
+ #
264
+ # Gets all linked storage account of a specific data source type associated
265
+ # with the specified workspace.
266
+ #
267
+ # @param resource_group_name [String] The name of the resource group. The name
268
+ # is case insensitive.
269
+ # @param workspace_name [String] The name of the workspace.
270
+ # @param data_source_type [DataSourceType] Linked storage accounts type.
271
+ # Possible values include: 'CustomLogs', 'AzureWatson', 'Query', 'Ingestion',
272
+ # 'Alerts'
273
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
274
+ # will be added to the HTTP request.
275
+ #
276
+ # @return [LinkedStorageAccountsResource] operation results.
277
+ #
278
+ def get(resource_group_name, workspace_name, data_source_type, custom_headers:nil)
279
+ response = get_async(resource_group_name, workspace_name, data_source_type, custom_headers:custom_headers).value!
280
+ response.body unless response.nil?
281
+ end
282
+
283
+ #
284
+ # Gets all linked storage account of a specific data source type associated
285
+ # with the specified workspace.
286
+ #
287
+ # @param resource_group_name [String] The name of the resource group. The name
288
+ # is case insensitive.
289
+ # @param workspace_name [String] The name of the workspace.
290
+ # @param data_source_type [DataSourceType] Linked storage accounts type.
291
+ # Possible values include: 'CustomLogs', 'AzureWatson', 'Query', 'Ingestion',
292
+ # 'Alerts'
293
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
294
+ # will be added to the HTTP request.
295
+ #
296
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
297
+ #
298
+ def get_with_http_info(resource_group_name, workspace_name, data_source_type, custom_headers:nil)
299
+ get_async(resource_group_name, workspace_name, data_source_type, custom_headers:custom_headers).value!
300
+ end
301
+
302
+ #
303
+ # Gets all linked storage account of a specific data source type associated
304
+ # with the specified workspace.
305
+ #
306
+ # @param resource_group_name [String] The name of the resource group. The name
307
+ # is case insensitive.
308
+ # @param workspace_name [String] The name of the workspace.
309
+ # @param data_source_type [DataSourceType] Linked storage accounts type.
310
+ # Possible values include: 'CustomLogs', 'AzureWatson', 'Query', 'Ingestion',
311
+ # 'Alerts'
312
+ # @param [Hash{String => String}] A hash of custom headers that will be added
313
+ # to the HTTP request.
314
+ #
315
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
316
+ #
317
+ def get_async(resource_group_name, workspace_name, data_source_type, custom_headers:nil)
318
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
319
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
320
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
321
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'Pattern': '^[-\w\._\(\)]+$'" if !resource_group_name.nil? && resource_group_name.match(Regexp.new('^^[-\w\._\(\)]+$$')).nil?
322
+ fail ArgumentError, 'workspace_name is nil' if workspace_name.nil?
323
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MaxLength': '63'" if !workspace_name.nil? && workspace_name.length > 63
324
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MinLength': '4'" if !workspace_name.nil? && workspace_name.length < 4
325
+ 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?
326
+ fail ArgumentError, 'data_source_type is nil' if data_source_type.nil?
327
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
328
+ fail ArgumentError, "'@client.api_version' should satisfy the constraint - 'MinLength': '1'" if !@client.api_version.nil? && @client.api_version.length < 1
329
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
330
+ fail ArgumentError, "'@client.subscription_id' should satisfy the constraint - 'MinLength': '1'" if !@client.subscription_id.nil? && @client.subscription_id.length < 1
331
+
332
+
333
+ request_headers = {}
334
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
335
+
336
+ # Set Headers
337
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
338
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
339
+ path_template = 'subscriptions/{subscriptionId}/resourcegroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{workspaceName}/linkedStorageAccounts/{dataSourceType}'
340
+
341
+ request_url = @base_url || @client.base_url
342
+
343
+ options = {
344
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
345
+ path_params: {'resourceGroupName' => resource_group_name,'workspaceName' => workspace_name,'dataSourceType' => data_source_type,'subscriptionId' => @client.subscription_id},
346
+ query_params: {'api-version' => @client.api_version},
347
+ headers: request_headers.merge(custom_headers || {}),
348
+ base_url: request_url
349
+ }
350
+ promise = @client.make_request_async(:get, path_template, options)
351
+
352
+ promise = promise.then do |result|
353
+ http_response = result.response
354
+ status_code = http_response.status
355
+ response_content = http_response.body
356
+ unless status_code == 200
357
+ error_model = JSON.load(response_content)
358
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
359
+ end
360
+
361
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
362
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
363
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
364
+ # Deserialize Response
365
+ if status_code == 200
366
+ begin
367
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
368
+ result_mapper = Azure::OperationalInsights::Mgmt::V2020_03_01_preview::Models::LinkedStorageAccountsResource.mapper()
369
+ result.body = @client.deserialize(result_mapper, parsed_response)
370
+ rescue Exception => e
371
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
372
+ end
373
+ end
374
+
375
+ result
376
+ end
377
+
378
+ promise.execute
379
+ end
380
+
381
+ #
382
+ # Gets all linked storage accounts associated with the specified workspace,
383
+ # storage accounts will be sorted by their data source type.
384
+ #
385
+ # @param resource_group_name [String] The name of the resource group. The name
386
+ # is case insensitive.
387
+ # @param workspace_name [String] The name of the workspace.
388
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
389
+ # will be added to the HTTP request.
390
+ #
391
+ # @return [LinkedStorageAccountsListResult] operation results.
392
+ #
393
+ def list_by_workspace(resource_group_name, workspace_name, custom_headers:nil)
394
+ response = list_by_workspace_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
395
+ response.body unless response.nil?
396
+ end
397
+
398
+ #
399
+ # Gets all linked storage accounts associated with the specified workspace,
400
+ # storage accounts will be sorted by their data source type.
401
+ #
402
+ # @param resource_group_name [String] The name of the resource group. The name
403
+ # is case insensitive.
404
+ # @param workspace_name [String] The name of the workspace.
405
+ # @param custom_headers [Hash{String => String}] A hash of custom headers that
406
+ # will be added to the HTTP request.
407
+ #
408
+ # @return [MsRestAzure::AzureOperationResponse] HTTP response information.
409
+ #
410
+ def list_by_workspace_with_http_info(resource_group_name, workspace_name, custom_headers:nil)
411
+ list_by_workspace_async(resource_group_name, workspace_name, custom_headers:custom_headers).value!
412
+ end
413
+
414
+ #
415
+ # Gets all linked storage accounts associated with the specified workspace,
416
+ # storage accounts will be sorted by their data source type.
417
+ #
418
+ # @param resource_group_name [String] The name of the resource group. The name
419
+ # is case insensitive.
420
+ # @param workspace_name [String] The name of the workspace.
421
+ # @param [Hash{String => String}] A hash of custom headers that will be added
422
+ # to the HTTP request.
423
+ #
424
+ # @return [Concurrent::Promise] Promise object which holds the HTTP response.
425
+ #
426
+ def list_by_workspace_async(resource_group_name, workspace_name, custom_headers:nil)
427
+ fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
428
+ fail ArgumentError, "'@client.subscription_id' should satisfy the constraint - 'MinLength': '1'" if !@client.subscription_id.nil? && @client.subscription_id.length < 1
429
+ fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
430
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MaxLength': '90'" if !resource_group_name.nil? && resource_group_name.length > 90
431
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'MinLength': '1'" if !resource_group_name.nil? && resource_group_name.length < 1
432
+ fail ArgumentError, "'resource_group_name' should satisfy the constraint - 'Pattern': '^[-\w\._\(\)]+$'" if !resource_group_name.nil? && resource_group_name.match(Regexp.new('^^[-\w\._\(\)]+$$')).nil?
433
+ fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
434
+ fail ArgumentError, "'@client.api_version' should satisfy the constraint - 'MinLength': '1'" if !@client.api_version.nil? && @client.api_version.length < 1
435
+ fail ArgumentError, 'workspace_name is nil' if workspace_name.nil?
436
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MaxLength': '63'" if !workspace_name.nil? && workspace_name.length > 63
437
+ fail ArgumentError, "'workspace_name' should satisfy the constraint - 'MinLength': '4'" if !workspace_name.nil? && workspace_name.length < 4
438
+ 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?
439
+
440
+
441
+ request_headers = {}
442
+ request_headers['Content-Type'] = 'application/json; charset=utf-8'
443
+
444
+ # Set Headers
445
+ request_headers['x-ms-client-request-id'] = SecureRandom.uuid
446
+ request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
447
+ path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.OperationalInsights/workspaces/{workspaceName}/linkedStorageAccounts'
448
+
449
+ request_url = @base_url || @client.base_url
450
+
451
+ options = {
452
+ middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
453
+ path_params: {'subscriptionId' => @client.subscription_id,'resourceGroupName' => resource_group_name,'workspaceName' => workspace_name},
454
+ query_params: {'api-version' => @client.api_version},
455
+ headers: request_headers.merge(custom_headers || {}),
456
+ base_url: request_url
457
+ }
458
+ promise = @client.make_request_async(:get, path_template, options)
459
+
460
+ promise = promise.then do |result|
461
+ http_response = result.response
462
+ status_code = http_response.status
463
+ response_content = http_response.body
464
+ unless status_code == 200
465
+ error_model = JSON.load(response_content)
466
+ fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
467
+ end
468
+
469
+ result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
470
+ result.correlation_request_id = http_response['x-ms-correlation-request-id'] unless http_response['x-ms-correlation-request-id'].nil?
471
+ result.client_request_id = http_response['x-ms-client-request-id'] unless http_response['x-ms-client-request-id'].nil?
472
+ # Deserialize Response
473
+ if status_code == 200
474
+ begin
475
+ parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
476
+ result_mapper = Azure::OperationalInsights::Mgmt::V2020_03_01_preview::Models::LinkedStorageAccountsListResult.mapper()
477
+ result.body = @client.deserialize(result_mapper, parsed_response)
478
+ rescue Exception => e
479
+ fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
480
+ end
481
+ end
482
+
483
+ result
484
+ end
485
+
486
+ promise.execute
487
+ end
488
+
489
+ end
490
+ end