Skip to content

Commit

Permalink
Add autorest.az configurations for azure monitor control service (#12090
Browse files Browse the repository at this point in the history
)

* add AMCS config for codegen

* reorganize command group

* rename command group

* Codegen modify try to rename DataCollectionRules create parameters

* hide DataCollectionRules Create & Update commands and DataCollectionRuleAssociations Create command

* use alias instand of rename in code-gen

* use monitor-control-service as the extension name

* Update readme.python.md
  • Loading branch information
kairu-ms authored Dec 23, 2020
1 parent 0e13406 commit 04feecb
Show file tree
Hide file tree
Showing 3 changed files with 107 additions and 0 deletions.
92 changes: 92 additions & 0 deletions specification/monitor/resource-manager/readme.az.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
## AZ

These settings apply only when `--az` is specified on the command line.
``` yaml $(az)
batch:
- AMCS: true
```
``` yaml $(az) && $(AMCS)
az:
extensions: monitor-control-service
parent-extension: monitor
namespace: azure.mgmt.amcs
package-name: azure-mgmt-amcs
az-output-folder: $(azure-cli-extension-folder)/src/monitor-control-service
python-sdk-output-folder: "$(az-output-folder)/azext_amcs/vendored_sdks/amcs"
# add additinal configuration here specific for Azure CLI
# refer to the faq.md for more details
```

# Az.AMCS
This directory contains the CLI common model for the Azure Monitor Control Service (AMCS).

> Metadata
``` yaml $(AMCS)

extension-mode: preview

directive:

- where:
group: monitor monitor-control-service data-collection-rule
set:
group: monitor data-collection-rule
- where:
group: monitor data-collection-rule
set:
group: monitor data-collection rule

- where:
group: monitor monitor-control-service data-collection-rule-association
set:
group: monitor data-collection-rule-association
- where:
group: monitor data-collection-rule-association
set:
group: monitor data-collection rule-association
- where:
group: monitor data-collection rule-association
set:
group: monitor data-collection rule association

cli:
cli-directive:
# -------- data-collection rule --------
- where:
group: DataCollectionRules
param: dataCollectionRuleName
alias:
- name
- n
- where:
group: DataCollectionRuleAssociations
op: Create
hidden: True
- where:
group: DataCollectionRules
op: Create
hidden: True
- where:
group: DataCollectionRules
op: Update
hidden: True

# -------- data-collection rule association --------
- where:
group: DataCollectionRuleAssociations
param: resourceUri
alias:
- resource
- where:
group: DataCollectionRuleAssociations
param: dataCollectionRuleName
alias:
- rule_name
- where:
group: DataCollectionRuleAssociations
param: associationName
alias:
- name
- n
```
5 changes: 5 additions & 0 deletions specification/monitor/resource-manager/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ To see additional help and options, run:

### Basic Information

There are the global settings for the Azure Monitor Control Service (AMCS) extension.
``` yaml $(AMCS)
tag: package-2019-11-01-preview-only
```
These are the global settings for the MonitorClient API.
``` yaml
Expand Down
10 changes: 10 additions & 0 deletions specification/monitor/resource-manager/readme.python.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,16 @@ modelerfour:
lenient-model-deduplication: true
```

These settings apply when `--track2` and `--AMCS` is specified on the command line.

``` yaml $(track2) && $(AMCS)
package-version: 0.1.0
namespace: azure.mgmt.amcs
package-name: azure-mgmt-amcs
basic-setup-py: true
output-folder: $(python-sdks-folder)/amcs/azure-mgmt-amcs
```

### Python multi-api

Generate all API versions currently shipped for this package
Expand Down

0 comments on commit 04feecb

Please sign in to comment.