Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
address comments
  • Loading branch information
Myron committed Apr 27, 2020
commit e604c49566edaf26a1b945fc81d69a9f483742ab
22 changes: 11 additions & 11 deletions src/azure-cli/azure/cli/command_modules/monitor/_help.py
Original file line number Diff line number Diff line change
Expand Up @@ -1110,50 +1110,50 @@

helps['monitor log-analytics workspace linked-storage create'] = """
type: command
short-summary: Create a linked storage account for log analytics workspace.
short-summary: Create some linked storage accounts for log analytics workspace.
examples:
- name: Create a linked storage account for a log analytics workspace
- name: Create two linked storage accounts for a log analytics workspace
text: az monitor log-analytics workspace linked-storage create --type AzureWatson -g MyResourceGroup --workspace-name MyWorkspace --storage-accounts SA1 SA2
"""

helps['monitor log-analytics workspace linked-storage delete'] = """
type: command
short-summary: Delete all linked storage accounts with specific data source type for log analytics workspace.
examples:
- name: Delete all linked storages with a specific type for a log analytics workspace
- name: Delete all linked storage accounts with a specific type for a log analytics workspace
text: az monitor log-analytics workspace linked-storage delete --type AzureWatson -g MyResourceGroup --workspace-name MyWorkspace
"""

helps['monitor log-analytics workspace linked-storage add'] = """
type: command
short-summary: Add some linked storages with specific data source type for log analytics workspace.
short-summary: Add some linked storage accounts with specific data source type for log analytics workspace.
examples:
- name: Add two linked storage for a log analytics workspace
- name: Add two linked storage accounts for a log analytics workspace
text: az monitor log-analytics workspace linked-storage add --type AzureWatson -g MyResourceGroup --workspace-name MyWorkspace --storage-accounts SA1 SA2
"""

helps['monitor log-analytics workspace linked-storage remove'] = """
type: command
short-summary: Remove some linked storages with specific data source type for log analytics workspace
short-summary: Remove some linked storage accounts with specific data source type for log analytics workspace
examples:
- name: Remove two linked storage for a log analytics workspace
- name: Remove two linked storage accounts for a log analytics workspace
text: az monitor log-analytics workspace linked-storage remove --type AzureWatson -g MyResourceGroup --workspace-name MyWorkspace --storage-accounts SA1 SA2.
"""

helps['monitor log-analytics workspace linked-storage list'] = """
type: command
short-summary: List all linked storages for a log analytics workspace.
short-summary: List all linked storage accounts for a log analytics workspace.
examples:
- name: List all linked storages for a log analytics workspace
- name: List all linked storage accounts for a log analytics workspace
text: az monitor log-analytics workspace linked-storage list -g MyResourceGroup --workspace-name MyWorkspace

"""

helps['monitor log-analytics workspace linked-storage show'] = """
type: command
short-summary: List all linked storages with specific data source type for a log analytics workspace.
short-summary: List all linked storage accounts with specific data source type for a log analytics workspace.
examples:
- name: Show all linked storages with a specific type for a log analytics workspace
- name: Show all linked storage accounts with a specific type for a log analytics workspace
text: az monitor log-analytics workspace linked-storage show --type AzureWatson -g MyResourceGroup --workspace-name MyWorkspace
"""

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def remove_log_analytics_workspace_linked_storage_accounts(client, resource_grou
linked_storage_accounts = client.get(resource_group_name=resource_group_name,
workspace_name=workspace_name,
data_source_type=data_source_type)
storage_account_ids_set = set([str.lower(storage_account_id) for storage_account_id in storage_account_ids ])
storage_account_ids_set = set([str.lower(storage_account_id) for storage_account_id in storage_account_ids])
for existed_storage_account_id in linked_storage_accounts.storage_account_ids:
if str.lower(existed_storage_account_id) in storage_account_ids_set:
linked_storage_accounts.storage_account_ids.remove(existed_storage_account_id)
Expand Down