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.AzureStack to add version stable/2017-06-01 #8240

2 changes: 2 additions & 0 deletions custom-words.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1696,3 +1696,5 @@ getactivesessions
disconnectactivesessions
bsls
sessionids
Dsms
cloudmanifestfile
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,53 @@
"nextLinkName": "nextLink"
}
}
},
"/providers/Microsoft.AzureStack/cloudmanifestfile": {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cloudmanifestfile [](start = 37, length = 17)

As per the RPC, resource type names should be plural. If it's a singleton, the correct pattern would be to implement the following routes:

  • /providers/Microsoft.AzureStack/cloudmanifestfiles
  • /providers/Microsoft.AzureStack/cloudmanifestfiles/default

default can be substituted with master, current, or latest depending on the requirements.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

Copy link
Member

@majastrz majastrz Feb 14, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need the list route also (/providers/Microsoft.AzureStack/cloudmanifestfiles). Yes, I know it's weird to have it just for 1 result, but that's the pattern.


In reply to: 379690800 [](ancestors = 379690800)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do I have to implement the API for list? We don't have a use case for that.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah :(. GET verb in ARM RPC is reserved for resources, which for a read-only resource like this would require LIST and GET at minimum. The other alternative would be to make it a POST action.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For some reason, I couldn't get proxy action work on tenant level. And this should not be a POST. I'll probably implement the list same as GET default.

"get": {
"x-ms-examples": {
"Returns the properties of a cloud specific manifest file.": {
"$ref": "examples/Operation/Get.json"
}
},
"tags": [
"AzureStack"
],
"description": "Returns a cloud specific manifest JSON file.",
"operationId": "CloudManifestFile_Get",
"parameters": [
{
"$ref": "#/parameters/ApiVersionParameter"
},
{
"name": "verificationVersion",
"in": "query",
"description": "Signing verification key version.",
"required": false,
"type": "string"
},
{
"name": "versionCreationDate",
"in": "query",
"description": "Signing verification key version creation date.",
"required": false,
"type": "string"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/CloudManifestFileResponse"
}
},
"default": {
"description": "Error response describing why the operation failed.",
"schema": {
"$ref": "#/definitions/ErrorResponse"
}
}
}
}
}
},
"definitions": {
Expand Down Expand Up @@ -191,6 +238,63 @@
}
}
},
"CloudManifestFileResponse": {
"description": "Cloud specific manifest GET response.",
"type": "object",
"properties": {
"value": {
"description": "Cloud specific manifest data.",
"$ref": "#/definitions/CloudManifestFileProperties"
}
}
},
"CloudManifestFileProperties": {
"description": "Cloud specific manifest JSON properties.",
"type": "object",
"properties": {
"deploymentData": {
"description": "Cloud specific manifest data.",
"$ref": "#/definitions/CloudManifestFileDeploymentData"
},
"signature": {
"description": "Signature of the cloud specific manifest data.",
"type": "string"
}
}
},
"CloudManifestFileDeploymentData": {
"description": "Cloud specific manifest data for AzureStack deployment.",
"type": "object",
"properties": {
"externalDsmsCertificates": {
"description": "Dsms external certificates.",
"type": "string"
},
"customCloudVerificationKey": {
"description": "Signing verification public key.",
"type": "string"
},
"customEnvironmentEndpoints": {
"description": "Environment endpoints.",
"x-ms-client-flatten": true,
"$ref": "#/definitions/CloudManifestFileEnvironmentEndpoints"
}
}
},
"CloudManifestFileEnvironmentEndpoints": {
"description": "Cloud specific environment endpoints for AzureStack deployment.",
"type": "object",
"properties": {
"customCloudArmEndpoint": {
"description": "ARM endpoint.",
"type": "string"
},
"externalDsmsEndpoint": {
"description": "Dsms endpoint.",
"type": "string"
}
}
},
"ErrorDetails": {
"description": "The details of the error.",
"properties": {
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"parameters": {
"api-version": "2017-06-01"
},
"responses": {
"200": {
"body": {
"value": {
"deploymentData": {
"externalDsmsCertificates": "",
"customCloudVerificationKey": "",
"customEnvironmentEndpoints": {
"customCloudArmEndpoint": "https://management.azure.microsoft.scloud/",
"externalDsmsEndpoint": "https://global-dsms.dsms.core.microsoft.scloud/dsms/issuercertificates"
}
},
"signature": ""
}
majastrz marked this conversation as resolved.
Show resolved Hide resolved
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,16 @@
},
"origin": "user,system"
},
{
"name": "Microsoft.AzureStack/cloudmanifestfile/read",
"display": {
"provider": "Azure Stack Resource Provider.",
"resource": "Azure Stack Cloud Manifest File",
"operation": "Read Resource Provider Operations",
"description": "Gets the cloud specific manifest file."
},
"origin": "user,system"
},
{
"name": "Microsoft.AzureStack/Operations/read",
"display": {
Expand Down