-
Notifications
You must be signed in to change notification settings - Fork 5.1k
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
Donaliu/20200207 sap monitor #8528
Changes from 1 commit
09ffe27
f98c566
49deb5b
39c7f76
a0a7433
ef42ba9
0bbb803
c99eaf4
ff0ca1c
853f3ba
a3e5de3
c6ff07e
1f058cf
ea21c3f
eacfca8
e336f58
32548ed
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
"parameters": { | ||
"api-version": "2020-02-07-preview", | ||
"subscriptionId": "00000000-0000-0000-0000-000000000000", | ||
"resourceGroupName": "myResourceGroup", | ||
"sapMonitorName": "mySapMonitor" | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"value": [ | ||
{ | ||
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.HanaOnAzure/sapMonitors/mySapMonitor/providerInstances/myProviderInstance1", | ||
"name": "myProviderInstance1", | ||
"type": "hana", | ||
"properties": "{\"hostname\":\"10.0.0.10\",\"dbName\":\"SYSTEMDB\",\"sqlPort\":30015,\"dbUsername\":\"SYSTEM\"}" | ||
}, | ||
{ | ||
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.HanaOnAzure/sapMonitors/mySapMonitor/providerInstances/myProviderInstance2", | ||
"name": "myProviderInstance2", | ||
"type": "hana", | ||
"properties": "{\"hostname\":\"10.0.0.11\",\"dbName\":\"SYSTEMDB\",\"sqlPort\":30015,\"dbUsername\":\"SYSTEM\"}" | ||
} | ||
] | ||
} | ||
} | ||
} | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -256,6 +256,52 @@ | |
} | ||
} | ||
}, | ||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HanaOnAzure/sapMonitors/{sapMonitorName}/providerInstances": { | ||
"get": { | ||
"tags": [ | ||
"HanaOnAzure" | ||
], | ||
"operationId": "ProviderInstances_List", | ||
"summary": "Gets a list of provider instnaces in the specified SAP monitor.", | ||
"description": "Gets a list of provider instnaces in the specified SAP monitor. The operations returns various properties of each provider instnaces.", | ||
"x-ms-examples": { | ||
"List all SAP Monitors in a subscription": { | ||
"$ref": "./examples/ProviderInstances_List.json" | ||
} | ||
}, | ||
"parameters": [ | ||
{ | ||
"$ref": "#/parameters/ApiVersionParameter" | ||
}, | ||
{ | ||
"$ref": "#/parameters/SubscriptionIdParameter" | ||
}, | ||
{ | ||
"$ref": "#/parameters/ResourceGroupNameParameter" | ||
}, | ||
{ | ||
"$ref": "#/parameters/SapMonitorNameParameter" | ||
} | ||
], | ||
"responses": { | ||
"200": { | ||
"description": "OK", | ||
"schema": { | ||
"$ref": "#/definitions/ProviderInstanceListResult" | ||
} | ||
}, | ||
"default": { | ||
"description": "Error response describing why the operation failed.", | ||
"schema": { | ||
"$ref": "#/definitions/ErrorResponse" | ||
} | ||
} | ||
}, | ||
"x-ms-pageable": { | ||
"nextLinkName": "nextLink" | ||
} | ||
} | ||
}, | ||
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.HanaOnAzure/sapMonitors/{sapMonitorName}/providerInstances/{providerInstanceName}": { | ||
"get": { | ||
PakDLiu marked this conversation as resolved.
Show resolved
Hide resolved
|
||
"tags": [ | ||
|
@@ -410,37 +456,63 @@ | |
}, | ||
"definitions": { | ||
"Resource": { | ||
"description": "The resource model definition.", | ||
"description": "The core properties of ARM resources", | ||
"properties": { | ||
"id": { | ||
"readOnly": true, | ||
"type": "string", | ||
"description": "Resource ID" | ||
"description": "Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/trafficManagerProfiles/{resourceName}" | ||
}, | ||
"name": { | ||
"readOnly": true, | ||
"type": "string", | ||
"description": "Resource name" | ||
"description": "The name of the resource" | ||
}, | ||
"type": { | ||
"readOnly": true, | ||
"type": "string", | ||
"description": "Resource type" | ||
}, | ||
"location": { | ||
"type": "string", | ||
"description": "Resource location" | ||
}, | ||
"description": "The type of the resource. Ex- Microsoft.Network/trafficManagerProfiles." | ||
} | ||
}, | ||
"x-ms-azure-resource": true | ||
}, | ||
"TrackedResource": { | ||
"description": "The resource model definition for a ARM tracked top level resource", | ||
"properties": { | ||
"tags": { | ||
"readOnly": true, | ||
"type": "object", | ||
"additionalProperties": { | ||
"type": "string" | ||
}, | ||
"description": "Resource tags" | ||
"x-ms-mutability": [ | ||
"read", | ||
"create", | ||
"update" | ||
], | ||
"description": "Resource tags." | ||
}, | ||
"location": { | ||
"type": "string", | ||
"x-ms-mutability": [ | ||
"read", | ||
"create" | ||
], | ||
"description": "The Azure Region where the resource lives" | ||
} | ||
}, | ||
"x-ms-azure-resource": true | ||
"allOf": [ | ||
{ | ||
"$ref": "#/definitions/Resource" | ||
} | ||
] | ||
}, | ||
"ProxyResource": { | ||
"description": "The resource model definition for a ARM proxy resource. It will have everything other than required location and tags", | ||
"allOf": [ | ||
{ | ||
"$ref": "#/definitions/Resource" | ||
} | ||
] | ||
}, | ||
"ErrorResponse": { | ||
"description": "Describes the format of Error response.", | ||
|
@@ -495,7 +567,7 @@ | |
}, | ||
"allOf": [ | ||
{ | ||
"$ref": "#/definitions/Resource" | ||
"$ref": "#/definitions/TrackedResource" | ||
} | ||
], | ||
"description": "SAP monitor info on Azure (ARM properties and SAP monitor properties)" | ||
|
@@ -545,37 +617,39 @@ | |
"readOnly": true, | ||
"type": "string", | ||
"description": "The version of the payload running in the Collector VM" | ||
}, | ||
"providerInstances": { | ||
} | ||
}, | ||
"description": "Describes the properties of a SAP monitor." | ||
}, | ||
"ProviderInstanceListResult": { | ||
"properties": { | ||
"value": { | ||
"type": "array", | ||
"items": { | ||
"$ref": "#/definitions/ProviderInstance" | ||
}, | ||
"description": "The list of monitor provider instances." | ||
"description": "The list of provider instances." | ||
}, | ||
"nextLink": { | ||
"type": "string", | ||
"description": "The URL to get the next set of provider instances." | ||
} | ||
}, | ||
"description": "Describes the properties of a SAP monitor." | ||
"description": "The response from the List provider instances operation." | ||
}, | ||
"ProviderInstance": { | ||
PakDLiu marked this conversation as resolved.
Show resolved
Hide resolved
|
||
"properties": { | ||
"id": { | ||
"readOnly": true, | ||
"type": "string", | ||
"description": "Resource ID" | ||
}, | ||
"name": { | ||
"type": "string", | ||
"description": "The name of the provider instance." | ||
}, | ||
"type": { | ||
"type": "string", | ||
"description": "The provider instance type." | ||
}, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why is there no modelling of the properties of the provider instance? This is going to make writing tools to consume this type very difficult, both in SDKs and for customers consuming the API directly There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is by design. the properties field is a JSON string and the schema will be determined by the type field. We wanted to make the API flexible. Also, other teams will be implementing their own providers and it will be up to them what their JSON schema will be. |
||
"properties": { | ||
"type": "string", | ||
"description": "A JSON string containing the properties of the provider instance." | ||
} | ||
} | ||
}, | ||
"allOf": [ | ||
{ | ||
"$ref": "#/definitions/ProxyResource" | ||
} | ||
], | ||
"description": "A provider instance associated with a SAP monitor." | ||
} | ||
}, | ||
"parameters": { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we call this 'providers'? This is the name of a resource type and all resources under it are implicitly referred to as Instances.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I find "providers" not that a good choice, for two reasons:
That being said, "providerInstances" seems like a better choice to me.