Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Hub Generated] Review request for Microsoft.Insights to add version stable/2016-06-01 #14085

Merged
Merged
Show file tree
Hide file tree
Changes from 15 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
42534f3
Adds base for updating Microsoft.Insights from version stable/2016-09…
ToddKingMSFT Apr 22, 2021
d50636b
Updates readme
ToddKingMSFT Apr 22, 2021
60cade1
Updates API version in new specs and examples
ToddKingMSFT Apr 22, 2021
192b9b5
Delete serviceDiagnosticsSettings_API.json
ToddKingMSFT Apr 22, 2021
0cd6b98
Delete createOrUpdateServiceDiagnosticSetting.json
ToddKingMSFT Apr 22, 2021
7aed9d1
Delete getServiceDiagnosticSetting.json
ToddKingMSFT Apr 22, 2021
02dba72
Delete updateServiceDiagnosticSetting.json
ToddKingMSFT Apr 22, 2021
150964f
Delete GetMetricFiltered.json
ToddKingMSFT Apr 23, 2021
ef9ecae
Update GetMetric.json
ToddKingMSFT Apr 23, 2021
cadc898
Update metrics_API.json
ToddKingMSFT Apr 23, 2021
a5f9350
Update readme.md
ToddKingMSFT Apr 23, 2021
12a8439
Update metrics_API.json
ToddKingMSFT May 26, 2021
4ab657b
Update metrics_API.json
ToddKingMSFT May 27, 2021
c70bee3
Update GetMetric.json
ToddKingMSFT May 27, 2021
9e040cb
Update readme.md
ToddKingMSFT May 27, 2021
877618b
Create operations_API.json
ToddKingMSFT May 27, 2021
0c8ba09
Create OperationList.json
ToddKingMSFT May 27, 2021
8e26170
Update readme.md
ToddKingMSFT May 27, 2021
d07e6f6
Update readme.md
ToddKingMSFT May 27, 2021
2b4955d
Update operations_API.json
ToddKingMSFT May 27, 2021
a8551a0
Update metrics_API.json
ToddKingMSFT Jun 10, 2021
27816bc
Merge branch 'Azure:master' into dev-monitor-Microsoft.Insights-2016-…
ToddKingMSFT Jun 10, 2021
7aa095d
Update metrics_API.json
ToddKingMSFT Jun 10, 2021
7a34762
Update operations_API.json
ToddKingMSFT Jun 10, 2021
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,137 @@
{
"parameters": {
"resourceUri": "subscriptions/1f3fa6d2-851c-4a91-9087-1a050f3a9c38/resourceGroups/todking/providers/Microsoft.Storage/storageAccounts/tkfileserv/blobServices/default",
"$filter": "(name.value eq 'BlobCapacity') and aggregationType eq 'Average' and timeGrain eq duration'PT30M' and startTime eq 2021-04-21T10:37:24.0000028Z and endTime eq 2021-04-22T01:26:59.0000795Z",
"api-version": "2016-06-01"
},
"responses": {
"200": {
"body": {
"value": [
{
"data": [
{
"timeStamp": "2021-04-21T10:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T11:07:00Z"
},
{
"timeStamp": "2021-04-21T11:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T12:07:00Z"
},
{
"timeStamp": "2021-04-21T12:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T13:07:00Z"
},
{
"timeStamp": "2021-04-21T13:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T14:07:00Z"
},
{
"timeStamp": "2021-04-21T14:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T15:07:00Z"
},
{
"timeStamp": "2021-04-21T15:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T16:07:00Z"
},
{
"timeStamp": "2021-04-21T16:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T17:07:00Z"
},
{
"timeStamp": "2021-04-21T17:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T18:07:00Z"
},
{
"timeStamp": "2021-04-21T18:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T19:07:00Z"
},
{
"timeStamp": "2021-04-21T19:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T20:07:00Z"
},
{
"timeStamp": "2021-04-21T20:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T21:07:00Z"
},
{
"timeStamp": "2021-04-21T21:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T22:07:00Z"
},
{
"timeStamp": "2021-04-21T22:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-21T23:07:00Z"
},
{
"timeStamp": "2021-04-21T23:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-22T00:07:00Z"
},
{
"timeStamp": "2021-04-22T00:37:00Z",
"average": 78278.125
},
{
"timeStamp": "2021-04-22T01:07:00Z"
}
],
"id": "/subscriptions/1f3fa6d2-851c-4a91-9087-1a050f3a9c38/resourceGroups/todking/providers/Microsoft.Storage/storageAccounts/tkfileserv/blobServices/default/providers/Microsoft.Insights/metrics/BlobCapacity",
"name": {
"value": "BlobCapacity",
"localizedValue": "Blob Capacity"
},
"type": "Microsoft.Insights/metrics",
"unit": "1"
}
]
}
},
"default": {
"body": {
"code": "BadRequest",
"message": "only conditions of the form '<name> eq <value>' are allowed, where <name> = 'timeGrain', 'startTime', 'endTime', 'name.value', 'aggregationType', 'debugRegion' : invalid filter"
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,198 @@
{
"swagger": "2.0",
"info": {
"title": "MonitorClient",
"version": "2016-06-01"
},
"host": "management.azure.com",
"schemes": [
"https"
],
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"security": [
{
"azure_auth": [
"user_impersonation"
]
}
],
"securityDefinitions": {
"azure_auth": {
"type": "oauth2",
"authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize",
"flow": "implicit",
"description": "Azure Active Directory OAuth2 Flow",
"scopes": {
"user_impersonation": "impersonate your user account"
}
}
},
"paths": {
"/{resourceUri}/providers/Microsoft.Insights/metrics": {
"get": {
"tags": [
"Metrics"
],
"operationId": "Metrics_List",
"description": "Lists the metric values for a resource.",
"parameters": [
{
"name": "resourceUri",
"in": "path",
"required": true,
"type": "string",
"description": "The identifier of the resource.",
"x-ms-parameter-location": "method",
"x-ms-skip-url-encoding": true
},
{
"name": "$filter",
"in": "query",
"type": "string",
"description": "Specifies the set of data returned.<br>The filter is optional. If present it must contain a list of metric names to retrieve of the form: *(name.value eq 'metricName' [or name.value eq 'metricName' or ...])*. Optionally, the filter can contain conditions for the following attributes *aggregationType*, *startTime*, *endTime*, and *timeGrain* of the form *attributeName operator value*. Where operator is one of *ne*, *eq*, *gt*, *lt*.<br>Several conditions can be combined with parentheses and logical operators, e.g: *and*, *or*.<br>Some example filter expressions are:<br>- $filter=(name.value eq 'RunsSucceeded') and aggregationType eq 'Total' and startTime eq 2016-02-20 and endTime eq 2016-02-21 and timeGrain eq duration'PT1M',<br>- $filter=(name.value eq 'RunsSucceeded') and (aggregationType eq 'Total' or aggregationType eq 'Average') and startTime eq 2016-02-20 and endTime eq 2016-02-21 and timeGrain eq duration'PT1H',<br>- $filter=(name.value eq 'ActionsCompleted' or name.value eq 'RunsSucceeded') and (aggregationType eq 'Total' or aggregationType eq 'Average') and startTime eq 2016-02-20 and endTime eq 2016-02-21 and timeGrain eq duration'PT1M'.<br><br>**NOTE**: When a metrics query comes in with multiple metrics, but with no aggregation types defined, the service will pick the Primary aggregation type of the first metrics to be used as the default aggregation type for all the metrics.",
"required": true
},
{
"$ref": "../../../../../common-types/resource-management/v2/types.json#/parameters/ApiVersionParameter"
}
],
"responses": {
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "../../../../../common-types/resource-management/v1/types.json#/definitions/ErrorResponse"
}
},
"200": {
"description": "Successful request to get the list of metric values",
"schema": {
"$ref": "#/definitions/MetricCollection"
}
}
},
"x-ms-pageable": {
"nextLinkName": null
},
"x-ms-odata": "#/definitions/Metric",
"x-ms-examples": {
"Get Metric with filter": {
"$ref": "./examples/GetMetric.json"
}
}
}
}
},
"definitions": {
"LocalizableString": {
"required": [
"value"
],
"properties": {
"value": {
"type": "string",
"description": "the invariant value."
},
"localizedValue": {
"type": "string",
"description": "the locale specific value."
}
},
"description": "The localizable string class."
},
"Unit": {
"type": "string",
"description": "Number representing the unit of the metric. 0=Count, 1=Bytes, 2=Seconds, 3=CountPerSecond, 4=BytesPerSecond, 5=Percent, 6=MilliSeconds, 7=ByteSeconds"
},
"MetricValue": {
"required": [
"timeStamp"
],
"properties": {
"timeStamp": {
"type": "string",
"format": "date-time",
"description": "the timestamp for the metric value in ISO 8601 format."
},
"average": {
"type": "number",
"format": "double",
"description": "the average value in the time range."
},
"minimum": {
"type": "number",
"format": "double",
"description": "the least value in the time range."
},
"maximum": {
"type": "number",
"format": "double",
"description": "the greatest value in the time range."
},
"total": {
"type": "number",
"format": "double",
"description": "the sum of all of the values in the time range."
},
"count": {
"type": "integer",
"format": "int64",
"description": "the number of samples in the time range. Can be used to determine the number of values that contributed to the average value."
}
},
"description": "Represents a metric value."
},
"Metric": {
"required": [
"name",
"unit",
"data"
],
"properties": {
"id": {
"type": "string",
"description": "the id, resourceId, of the metric."
},
"type": {
"type": "string",
"description": "the resource type of the metric resource."
},
"name": {
"$ref": "#/definitions/LocalizableString",
"description": "the name and the display name of the metric, i.e. it is localizable string."
},
"unit": {
"$ref": "#/definitions/Unit",
"description": "the unit of the metric."
},
"data": {
"type": "array",
"items": {
"$ref": "#/definitions/MetricValue"
},
"description": "Array of data points representing the metric values."
}
},
"description": "A set of metric values in a time range."
},
"MetricCollection": {
"properties": {
"value": {
"type": "array",
"items": {
"$ref": "#/definitions/Metric"
},
"description": "the value of the collection."
}
},
"required": [
"value"
],
"description": "The collection of metric value sets."
}
}
}
10 changes: 10 additions & 0 deletions specification/monitor/resource-manager/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ These are the global settings for the MonitorClient API.
``` yaml !$(python) || !$(track2)
title: MonitorClient
```

``` yaml $(python) && $(track2)
title: MonitorManagementClient
```
Expand Down Expand Up @@ -520,6 +521,15 @@ input-file:
- Microsoft.Insights/stable/2016-09-01/serviceDiagnosticsSettings_API.json
```

### Tag: package-2016-06-only

These settings apply only when `--tag=package-2016-06-only` is specified on the command line.

```yaml $(tag) == 'package-2016-06-only'
input-file:
- Microsoft.Insights/stable/2016-06-01/metrics_API.json
```

### Tag: package-2016-03-01-only

These settings apply only when `--tag=package-2016-03-01-only` is specified on the command line.
Expand Down