Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
99c2fbc
Initial commit - copying diagnostic file from 2025-02-01-preview vers…
Elina-L Jul 7, 2025
ea2bdee
Replace diagnostic.json file with contents from previous 2025-06-05 PR
Elina-L Jul 7, 2025
3ff768e
Ran prettier on diagnostic.json
Elina-L Jul 7, 2025
271ce8c
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 8, 2025
0a43039
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 8, 2025
a85278d
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 9, 2025
82c0b9f
Remove common.json from 2025-06-05-only tag
Elina-L Jul 9, 2025
3209b5b
Merge branch 'wenxliu/CDRPNewApiVersion20250605' of https://github.co…
Elina-L Jul 9, 2025
e629fab
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 9, 2025
058d0e4
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 10, 2025
61c07e0
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 11, 2025
2dbb914
Upgrade v3 to v5 in diagnostic.json
Elina-L Jul 11, 2025
3980ca5
Merge branch 'wenxliu/CDRPNewApiVersion20250605' of https://github.co…
Elina-L Jul 11, 2025
67adf86
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 11, 2025
8ad49fa
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 11, 2025
305839f
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 15, 2025
8842df1
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 15, 2025
968f7c2
Merge branch 'wenxliu/CDRPNewApiVersion20250605' of https://github.co…
Elina-L Jul 16, 2025
7bf62a6
Merge branch 'main' into wenxliu/CDRPNewApiVersion20250605
Elina-L Jul 17, 2025
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,255 @@
{
"swagger": "2.0",
"info": {
"title": "ComputeDiagnosticResourceProviderClient",
"description": "The Compute Diagnostic Resource Provider Client",
"version": "2025-06-05"
},
"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": {
"/subscriptions/{subscriptionId}/providers/Microsoft.Compute/locations/{location}/placementScores/spot": {
"get": {
"tags": [
"placementScores_spot"
],
"operationId": "SpotPlacementScores_Get",
"description": "Gets Spot Placement Scores metadata.",
"parameters": [
{
"$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter"
},
{
"$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/LocationParameter"
},
{
"$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter"
}
],
"responses": {
"200": {
"description": "Success",
"schema": {
"$ref": "#/definitions/ComputeDiagnosticBase"
}
},
"default": {
"description": "Error response describing why the get call failed.",
"schema": {
"$ref": "../../../../../../common-types/resource-management/v5/types.json#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
"Gets the metadata of Spot Placement Scores.": {
"$ref": "./examples/GetSpotPlacementScores.json"
}
}
}
},
"/subscriptions/{subscriptionId}/providers/Microsoft.Compute/locations/{location}/placementScores/spot/generate": {
"post": {
"tags": [
"spotPlacementScores"
],
"operationId": "SpotPlacementScores_Post",
"description": "Generates placement scores for Spot VM skus.",
"parameters": [
{
"$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/SubscriptionIdParameter"
},
{
"$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/LocationParameter"
},
{
"$ref": "../../../../../../common-types/resource-management/v5/types.json#/parameters/ApiVersionParameter"
},
{
"name": "spotPlacementScoresInput",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/SpotPlacementScoresInput"
},
"description": "SpotPlacementScores object supplied in the body of the Post spot placement scores operation."
}
],
"responses": {
"200": {
"description": "Success",
"schema": {
"$ref": "#/definitions/SpotPlacementScoresResponse"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "../../../../../../common-types/resource-management/v5/types.json#/definitions/ErrorResponse"
}
}
},
"x-ms-examples": {
"Returns spot VM placement scores for given configurations.": {
"$ref": "./examples/GenerateSpotPlacementScores.json"
}
}
}
}
},
"definitions": {
"ComputeDiagnosticBase": {
"description": "Contains metadata of a diagnostic type",
"type": "object",
"properties": {
"properties": {
"$ref": "#/definitions/DiagnosticProperties"
}
},
"allOf": [
{
"$ref": "../../../../../../common-types/resource-management/v5/types.json#/definitions/ProxyResource"
}
]
},
"DiagnosticProperties": {
"description": "Contains additional properties of a diagnostic",
"type": "object",
"properties": {
"supportedResourceTypes": {
"type": "array",
"items": {
"type": "string"
},
"description": "Describes what are the supported resource types for a diagnostic."
}
}
},
"SpotPlacementScoresInput": {
"type": "object",
"properties": {
"desiredLocations": {
"type": "array",
"items": {
"type": "string"
},
"description": "The desired regions"
},
"desiredSizes": {
"type": "array",
"items": {
"$ref": "#/definitions/ResourceSize"
},
"description": "The desired virtual machine SKU sizes."
},
"desiredCount": {
"type": "integer",
"format": "int32",
"description": "Desired instance count per region/zone based on the scope."
},
"availabilityZones": {
"type": "boolean",
"description": "Defines if the scope is zonal or regional."
}
},
"description": "SpotPlacementScores API Input."
},
"SpotPlacementScoresResponse": {
"type": "object",
"properties": {
"desiredLocations": {
"type": "array",
"items": {
"type": "string"
},
"description": "The desired regions"
},
"desiredSizes": {
"type": "array",
"items": {
"$ref": "#/definitions/ResourceSize"
},
"description": "The desired virtual machine SKU sizes."
},
"desiredCount": {
"type": "integer",
"format": "int32",
"description": "Desired instance count per region/zone based on the scope."
},
"availabilityZones": {
"type": "boolean",
"description": "Defines if the scope is zonal or regional."
},
"placementScores": {
"type": "array",
"items": {
"$ref": "#/definitions/PlacementScore"
},
"description": "A placement score indicating the likelihood of successfully allocating the specified Spot VM(s), as well as the expected lifetimes of the Spot VM(s) after allocation."
}
},
"description": "SpotPlacementScores API response."
},
"ResourceSize": {
"type": "object",
"properties": {
"sku": {
"type": "string",
"description": "The resource's CRP virtual machine SKU size."
}
},
"description": "SpotPlacementRecommender API response."
},
"PlacementScore": {
"type": "object",
"properties": {
"sku": {
"type": "string",
"description": "The resource's CRP virtual machine SKU size."
},
"region": {
"type": "string",
"description": "The region."
},
"availabilityZone": {
"type": "string",
"description": "The availability zone."
},
"score": {
"type": "string",
"description": "A placement score indicating the likelihood of successfully allocating the specified Spot VM(s), as well as the expected lifetimes of the Spot VM(s) after allocation."
},
"isQuotaAvailable": {
"type": "boolean",
"description": "Whether the desired quota is available."
}
},
"description": "The spot placement score for sku/region/zone combination."
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
{
"parameters": {
"subscriptionId": "00000000-0000-0000-0000-000000000000",
"location": "eastus",
"api-version": "2025-06-05",
"spotPlacementScoresInput": {
"desiredLocations": [
"eastus",
"eastus2"
],
"desiredSizes": [
{
"sku": "Standard_D2_v2"
}
],
"desiredCount": 1,
"availabilityZones": true
}
},
"responses": {
"200": {
"body": {
"desiredLocations": [
"eastus",
"eastus2"
],
"desiredSizes": [
{
"sku": "Standard_D2_v2"
}
],
"desiredCount": 1,
"availabilityZones": true,
"placementScores": [
{
"sku": "Standard_D2_v2",
"region": "eastus",
"availabilityZone": "1",
"score": "High",
"isQuotaAvailable": true
},
{
"sku": "Standard_D2_v2",
"region": "eastus",
"availabilityZone": "2",
"score": "High",
"isQuotaAvailable": true
},
{
"sku": "Standard_D2_v2",
"region": "eastus",
"availabilityZone": "3",
"score": "High",
"isQuotaAvailable": true
},
{
"sku": "Standard_D2_v2",
"region": "eastus2",
"availabilityZone": "1",
"score": "DataNotFoundOrStale",
"isQuotaAvailable": true
},
{
"sku": "Standard_D2_v2",
"region": "eastus2",
"availabilityZone": "2",
"score": "High",
"isQuotaAvailable": true
},
{
"sku": "Standard_D2_v2",
"region": "eastus2",
"availabilityZone": "3",
"score": "High",
"isQuotaAvailable": true
}
]
},
"headers": {
"x-ms-request-id": "12345678-1234-1234-1234-123456789abc",
"location": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/eastus/placementScores/spot/generate?api-version=2025-06-05"
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
{
"parameters": {
"subscriptionId": "00000000-0000-0000-0000-000000000000",
"location": "eastus",
"api-version": "2025-06-05"
},
"responses": {
"200": {
"headers": {
"x-ms-request-id": "12345678-1234-1234-1234-123456789abc"
},
"body": {
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/placementScores/spot?api-version=2025-06-05",
"name": "spotPlacementScores",
"type": "Microsoft.Compute/placementScores",
"properties": {
"supportedResourceTypes": [
"Microsoft.Compute/virtualMachines"
]
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@
- tool: TypeSpecRequirement
path: DiagnosticRP/preview/2025-02-01-preview/**/*.json
reason: CDRP service not yet ready to migrate to typespec
- tool: TypeSpecRequirement
path: DiagnosticRP/stable/2025-06-05/**/*.json
reason: CDRP service not yet ready to migrate to typespec
Loading
Loading