Skip to content

Commit b879a8f

Browse files
tdarolyTaher Darolywala
andauthored
currentworkloadProfileStates - GET (#20550)
* commit after reset * remove 404 Co-authored-by: Taher Darolywala <[email protected]>
1 parent ddca448 commit b879a8f

File tree

2 files changed

+139
-4
lines changed

2 files changed

+139
-4
lines changed

specification/app/resource-manager/Microsoft.App/preview/2022-06-01-preview/ManagedEnvironments.json

Lines changed: 103 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -677,10 +677,6 @@
677677
"$ref": "#/definitions/EnvironmentAuthToken"
678678
}
679679
},
680-
"404": {
681-
"description": "Not found.",
682-
"x-ms-error-response": true
683-
},
684680
"default": {
685681
"description": "Error response.",
686682
"schema": {
@@ -694,6 +690,56 @@
694690
}
695691
}
696692
}
693+
},
694+
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.App/managedEnvironments/{environmentName}/workloadProfileStates": {
695+
"get": {
696+
"tags": [
697+
"ManagedEnvironments"
698+
],
699+
"summary": "Get all workload Profile States for a Premium Managed Environment..",
700+
"description": "Get all workload Profile States for a Premium Managed Environment.",
701+
"operationId": "ManagedEnvironments_ListWorkloadProfileStates",
702+
"parameters": [
703+
{
704+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/SubscriptionIdParameter"
705+
},
706+
{
707+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ResourceGroupNameParameter"
708+
},
709+
{
710+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/parameters/ApiVersionParameter"
711+
},
712+
{
713+
"name": "environmentName",
714+
"in": "path",
715+
"description": "Name of the Managed Environment.",
716+
"required": true,
717+
"type": "string"
718+
}
719+
],
720+
"responses": {
721+
"200": {
722+
"description": "OK",
723+
"schema": {
724+
"$ref": "#/definitions/workloadProfileStatesCollection"
725+
}
726+
},
727+
"default": {
728+
"description": "Common error response.",
729+
"schema": {
730+
"$ref": "./CommonDefinitions.json#/definitions/DefaultErrorResponse"
731+
}
732+
}
733+
},
734+
"x-ms-pageable": {
735+
"nextLinkName": "nextLink"
736+
},
737+
"x-ms-examples": {
738+
"List environments by subscription": {
739+
"$ref": "./examples/ManagedEnvironments_ListWorkloadProfileStates.json"
740+
}
741+
}
742+
}
697743
}
698744
},
699745
"definitions": {
@@ -1025,6 +1071,59 @@
10251071
"required": [
10261072
"name"
10271073
]
1074+
},
1075+
"workloadProfileStates": {
1076+
"description": "Collection of all the workload Profile States for a Premium Managed Environment..",
1077+
"type": "object",
1078+
"allOf": [
1079+
{
1080+
"$ref": "../../../../../common-types/resource-management/v3/types.json#/definitions/ProxyResource"
1081+
}
1082+
],
1083+
"properties": {
1084+
"properties": {
1085+
"description": "Workload Profile resource specific properties.",
1086+
"type": "object",
1087+
"properties": {
1088+
"minimumCount": {
1089+
"type": "integer",
1090+
"format": "int32",
1091+
"description": "Minimum count of instances."
1092+
},
1093+
"maximumCount": {
1094+
"type": "integer",
1095+
"format": "int32",
1096+
"description": "Maximum count of nodes."
1097+
},
1098+
"currentCount": {
1099+
"type": "integer",
1100+
"format": "int32",
1101+
"description": "Current count of nodes."
1102+
}
1103+
}
1104+
}
1105+
}
1106+
},
1107+
"workloadProfileStatesCollection": {
1108+
"description": "Collection of workloadProfileStates",
1109+
"required": [
1110+
"value"
1111+
],
1112+
"type": "object",
1113+
"properties": {
1114+
"value": {
1115+
"description": "Collection of resources.",
1116+
"type": "array",
1117+
"items": {
1118+
"$ref": "#/definitions/workloadProfileStates"
1119+
}
1120+
},
1121+
"nextLink": {
1122+
"description": "Link to next page of resources.",
1123+
"type": "string",
1124+
"readOnly": true
1125+
}
1126+
}
10281127
}
10291128
},
10301129
"securityDefinitions": {
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{
2+
"parameters": {
3+
"subscriptionId": "8efdecc5-919e-44eb-b179-915dca89ebf9",
4+
"resourceGroupName": "examplerg",
5+
"environmentName": "jlaw-demo1",
6+
"api-version": "2022-06-01-preview"
7+
},
8+
"responses": {
9+
"200": {
10+
"body": {
11+
"value": [
12+
{
13+
"id": "/subscriptions/55f240e3-3d66-44f6-8358-4e4f3d7a2e51/providers/Microsoft.App/workloadProfileStates/GP1",
14+
"name": "GP1",
15+
"type": "/providers/Microsoft.App/workloadProfileStates",
16+
"properties": {
17+
"minimumCount": 3,
18+
"maximumCount": 10,
19+
"currentCount": 3
20+
}
21+
},
22+
{
23+
"id": "/subscriptions/55f240e3-3d66-44f6-8358-4e4f3d7a2e51/providers/Microsoft.App/workloadProfileStates/MO3",
24+
"name": "MO3",
25+
"type": "/providers/Microsoft.App/workloadProfileStates",
26+
"properties": {
27+
"minimumCount": 0,
28+
"maximumCount": 2,
29+
"currentCount": 0
30+
}
31+
}
32+
]
33+
}
34+
}
35+
}
36+
}

0 commit comments

Comments
 (0)