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

[Refactor only] Try to use common type as much as possible and remove not used field #16648

Merged
Original file line number Diff line number Diff line change
Expand Up @@ -38,200 +38,6 @@
"name"
]
},
"IdentityType": {
"description": "The type of identity that creates/modifies resources",
"type": "string",
"enum": [
"User",
"Application",
"ManagedIdentity",
"Key"
],
"x-ms-enum": {
"name": "IdentityType",
"modelAsString": true
}
},
"Identity": {
"description": "Identity for the resource.",
"type": "object",
"properties": {
"principalId": {
"readOnly": true,
"type": "string",
"description": "The principal ID of resource identity."
},
"tenantId": {
"readOnly": true,
"type": "string",
"description": "The tenant ID of resource."
},
"type": {
"type": "string",
"description": "The identity type.",
"enum": [
"SystemAssigned"
],
"x-ms-enum": {
"name": "ResourceIdentityType",
"modelAsString": false
}
}
}
},
"Plan": {
"type": "object",
"properties": {
"name": {
"type": "string",
"description": "A user defined name of the 3rd Party Artifact that is being procured."
},
"publisher": {
"type": "string",
"description": "The publisher of the 3rd Party Artifact that is being bought. E.g. NewRelic"
},
"product": {
"type": "string",
"description": "The 3rd Party artifact that is being procured. E.g. NewRelic. Product maps to the OfferID specified for the artifact at the time of Data Market onboarding. "
},
"promotionCode": {
"type": "string",
"description": "A publisher provided promotion code as provisioned in Data Market for the said product/artifact."
},
"version": {
"type": "string",
"description": "The version of the desired product/artifact."
}
},
"description": "Plan for the resource.",
"required": [
"name",
"publisher",
"product"
]
},
"Resource": {
"type": "object",
"properties": {
"id": {
"readOnly": true,
"type": "string",
"description": "Fully qualified resource Id for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"
},
"name": {
"readOnly": true,
"type": "string",
"description": "The name of the resource"
},
"type": {
"readOnly": true,
"type": "string",
"description": "The type of the resource. Ex- Microsoft.Compute/virtualMachines or Microsoft.Storage/storageAccounts."
}
},
"x-ms-azure-resource": true
},
"TrackedResource": {
"type": "object",
"description": "The resource model definition for a ARM tracked top level resource",
"properties": {
"tags": {
"type": "object",
"additionalProperties": {
"type": "string"
},
"x-ms-mutability": [
"read",
"create",
"update"
],
"description": "Resource tags."
},
"location": {
"type": "string",
"x-ms-mutability": [
"read",
"create"
],
"description": "The geo-location where the resource lives"
},
"systemData": {
"$ref": "#/definitions/SystemData",
"readOnly": true
}
},
"required": [
"location"
],
"allOf": [
{
"$ref": "#/definitions/Resource"
}
]
},
"ProxyResource": {
"type": "object",
"description": "The resource model definition for a ARM proxy resource. It will have everything other than required location and tags",
"allOf": [
{
"$ref": "#/definitions/Resource"
}
]
},
"SystemData": {
"description": "Read only system data",
"type": "object",
"readOnly": true,
"properties": {
"createdBy": {
"type": "string",
"description": "An identifier for the identity that created the resource"
},
"createdByType": {
"$ref": "#/definitions/IdentityType",
"description": "The type of identity that created the resource"
},
"createdAt": {
"type": "string",
"format": "date-time",
"description": "The timestamp of resource creation (UTC)"
},
"lastModifiedBy": {
"type": "string",
"description": "An identifier for the identity that last modified the resource"
},
"lastModifiedByType": {
"$ref": "#/definitions/IdentityType",
"description": "The type of identity that last modified the resource"
},
"lastModifiedAt": {
"type": "string",
"format": "date-time",
"description": "The timestamp of resource last modification (UTC)"
}
}
},
"ResourceSku": {
"type": "object",
"properties": {
"capacity": {
"type": "integer",
"format": "int32"
},
"family": {
"type": "string"
},
"name": {
"type": "string"
},
"size": {
"type": "string"
},
"tier": {
"type": "string"
}
}
},
"ErrorResponse": {
"type": "object",
"properties": {
Expand Down Expand Up @@ -267,31 +73,6 @@
},
"description": "An error response from the Batch service."
},
"ODataError": {
"properties": {
"code": {
"type": "string",
"description": "A language-independent error name."
},
"message": {
"type": "string",
"description": "The error message."
},
"target": {
"type": "string",
"description": "The target of the error (for example, the name of the property in error)."
},
"details": {
"type": "array",
"items": {
"$ref": "#/definitions/ODataError"
},
"description": "The error details."
}
},
"type": "object",
"description": "Information about an error."
},
"ExtendedLocation": {
"type": "object",
"description": "The complex type of the extended location.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"type": "object",
"allOf": [
{
"$ref": "./common.json#/definitions/TrackedResource"
"$ref": "../../../../../../common-types/resource-management/v3/types.json#/definitions/TrackedResource"
}
],
"properties": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"type": "object",
"allOf": [
{
"$ref": "./common.json#/definitions/TrackedResource"
"$ref": "../../../../../../common-types/resource-management/v3/types.json#/definitions/TrackedResource"
}
],
"properties": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"type": "object",
"allOf": [
{
"$ref": "./common.json#/definitions/TrackedResource"
"$ref": "../../../../../../common-types/resource-management/v3/types.json#/definitions/TrackedResource"
}
],
"properties": {
Expand Down