From 5251cc1fec1ca2e30429ac1c3f77c967c7f06f64 Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Tue, 19 Feb 2019 10:17:34 -0800 Subject: [PATCH 01/11] Initializing instance pools swagger and examples - no usages / managed instances get by instance pool --- .../CreateOrUpdateInstancePoolMax.json | 68 +++ .../CreateOrUpdateInstancePoolMin.json | 61 ++ .../examples/DeleteInstancePool.json | 13 + .../examples/GetInstancePool.json | 31 + .../examples/ListInstancePools.json | 53 ++ .../examples/PatchInstancePool.json | 37 ++ .../2018-06-01-preview/instancePools.json | 534 ++++++++++++++++++ 7 files changed, 797 insertions(+) create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/CreateOrUpdateInstancePoolMax.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/CreateOrUpdateInstancePoolMin.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/DeleteInstancePool.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/GetInstancePool.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ListInstancePools.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/PatchInstancePool.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/instancePools.json diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/CreateOrUpdateInstancePoolMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/CreateOrUpdateInstancePoolMax.json new file mode 100644 index 000000000000..0c913654fe3b --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/CreateOrUpdateInstancePoolMax.json @@ -0,0 +1,68 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "group1", + "instancePoolName": "testIP", + "api-version": "2018-06-01-preview", + "parameters": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "family": "Gen5" + }, + "tags": { + "a": "b" + }, + "properties": { + "subnetId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Network/virtualNetwork/myvnet/subnets/mysubnet1", + "vCores": 8, + "licenseType": "LicenseIncluded" + } + } + }, + "responses": { + "200": { + "body": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "family": "Gen5" + }, + "properties": { + "subnetId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Network/virtualNetwork/myvnet/subnets/mysubnet1", + "vCores": 8, + "licenseType": "LicenseIncluded" + }, + "location": "onebox", + "tags": { + "a": "b" + }, + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Sql/instancePools/testIP", + "name": "testIP", + "type": "Microsoft.Sql/instancePools" + } + }, + "201": { + "body": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "family": "Gen5" + }, + "properties": { + "subnetId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Network/virtualNetwork/myvnet/subnets/mysubnet1", + "vCores": 8, + "licenseType": "LicenseIncluded" + }, + "location": "onebox", + "tags": { + "a": "b" + }, + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Sql/instancePools/testIP", + "name": "testIP", + "type": "Microsoft.Sql/instancePools" + } + }, + "202": {} + } +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/CreateOrUpdateInstancePoolMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/CreateOrUpdateInstancePoolMin.json new file mode 100644 index 000000000000..f89c6c4a9c2b --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/CreateOrUpdateInstancePoolMin.json @@ -0,0 +1,61 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "group1", + "instancePoolName": "testIP", + "api-version": "2018-06-01-preview", + "parameters": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "family": "Gen5" + }, + "properties": { + "subnetId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Network/virtualNetwork/myvnet/subnets/mysubnet1", + "vCores": 8, + "licenseType": "LicenseIncluded" + } + } + }, + "responses": { + "200": { + "body": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "family": "Gen5" + }, + "properties": { + "subnetId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Network/virtualNetwork/myvnet/subnets/mysubnet1", + "vCores": 8, + "licenseType": "LicenseIncluded" + }, + "location": "onebox", + "tags": {}, + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Sql/instancePools/testIP", + "name": "testIP", + "type": "Microsoft.Sql/instancePools" + } + }, + "201": { + "body": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "family": "Gen5" + }, + "properties": { + "subnetId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Network/virtualNetwork/myvnet/subnets/mysubnet1", + "vCores": 8, + "licenseType": "LicenseIncluded" + }, + "location": "onebox", + "tags": {}, + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Sql/instancePools/testIP", + "name": "testIP", + "type": "Microsoft.Sql/instancePools" + } + }, + "202": {} + } +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/DeleteInstancePool.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/DeleteInstancePool.json new file mode 100644 index 000000000000..ac2aa9603066 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/DeleteInstancePool.json @@ -0,0 +1,13 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "group1", + "instancePoolName": "testIP", + "api-version": "2018-06-01-preview" + }, + "responses": { + "200": {}, + "202": {}, + "204": {} + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/GetInstancePool.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/GetInstancePool.json new file mode 100644 index 000000000000..3f67d1f95f1f --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/GetInstancePool.json @@ -0,0 +1,31 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "group1", + "instancePoolName": "testIP", + "api-version": "2018-06-01-preview" + }, + "responses": { + "200": { + "body": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "family": "Gen5" + }, + "properties": { + "subnetId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Network/virtualNetwork/myvnet/subnets/mysubnet1", + "vCores": 8, + "licenseType": "LicenseIncluded" + }, + "location": "onebox", + "tags": { + "a": "b" + }, + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Sql/instancePools/testIP", + "name": "testIP", + "type": "Microsoft.Sql/instancePools" + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ListInstancePools.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ListInstancePools.json new file mode 100644 index 000000000000..1d0bc444bbd4 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ListInstancePools.json @@ -0,0 +1,53 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "group1", + "api-version": "2018-06-01-preview" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "family": "Gen5" + }, + "properties": { + "subnetId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Network/virtualNetwork/myvnet/subnets/mysubnet1", + "vCores": 8, + "licenseType": "LicenseIncluded" + }, + "location": "onebox", + "tags": { + "a": "b" + }, + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Sql/instancePools/testIP", + "name": "testIP", + "type": "Microsoft.Sql/instancePools" + }, + { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "family": "Gen5" + }, + "properties": { + "subnetId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Network/virtualNetwork/myvnet/subnets/mysubnet1", + "vCores": 8, + "licenseType": "LicenseIncluded" + }, + "location": "onebox", + "tags": { + "a": "b" + }, + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Sql/instancePools/testIP2", + "name": "testIP2", + "type": "Microsoft.Sql/instancePools" + } + ] + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/PatchInstancePool.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/PatchInstancePool.json new file mode 100644 index 000000000000..ec3deec20cfe --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/PatchInstancePool.json @@ -0,0 +1,37 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "group1", + "instancePoolName": "testIP", + "api-version": "2018-06-01-preview", + "parameters": { + "tags": { + "x": "y" + } + } + }, + "responses": { + "200": { + "body": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "family": "Gen5" + }, + "properties": { + "subnetId": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Network/virtualNetwork/myvnet/subnets/mysubnet1", + "vCores": 8, + "licenseType": "LicenseIncluded" + }, + "location": "onebox", + "tags": { + "x": "y" + }, + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/group1/providers/Microsoft.Sql/instancePools/testIP", + "name": "testIP", + "type": "Microsoft.Sql/instancePools" + } + }, + "202": {} + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/instancePools.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/instancePools.json new file mode 100644 index 000000000000..b2fa25a09c2e --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/instancePools.json @@ -0,0 +1,534 @@ +{ + "swagger": "2.0", + "info": { + "version": "2018-06-01-preview", + "title": "SqlManagementClient", + "description": "The Azure SQL Database management API provides a RESTful set of web APIs that interact with Azure SQL Database services to manage your databases. The API enables users to create, retrieve, update, and delete databases, servers, and other entities." + }, + "host": "management.azure.com", + "schemes": [ + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "paths": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/instancePools/{instancePoolName}": { + "get": { + "tags": [ + "InstancePools" + ], + "description": "Gets an instance pool.", + "operationId": "InstancePools_Get", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "name": "instancePoolName", + "in": "path", + "description": "The name of the instance pool to be retrieved.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the specified instance pool.", + "schema": { + "$ref": "#/definitions/InstancePool" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 404 InstancePoolNotFound - An instance pool cannot be found." + } + }, + "x-ms-examples": { + "Get an instance pool": { + "$ref": "./examples/GetInstancePool.json" + } + } + }, + "put": { + "tags": [ + "InstancePools" + ], + "description": "Creates or updates an instance pool.", + "operationId": "InstancePools_CreateOrUpdate", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "name": "instancePoolName", + "in": "path", + "description": "The name of the instance pool to be created or updated.", + "required": true, + "type": "string" + }, + { + "name": "parameters", + "in": "body", + "description": "The requested instance pool resource state.", + "required": true, + "schema": { + "$ref": "#/definitions/InstancePool" + } + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully updated the instance pool.", + "schema": { + "$ref": "#/definitions/InstancePool" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 InvalidResourceRequestBody - The resource or resource properties in the request body is empty or invalid.\n\n * 400 MissingSkuName - Sku name is rerquired.\n\n * 400 InstancePoolRequestedVcoreCountIsInvalid - Requested VCore count for instance pool is invalid.\n\n * 400 InstancePoolRequestMissingSku - Instance Pool request is missing Sku.\n\n * 400 InstancePoolRequestMissingSkuTier - Instance Pool request is missing Sku Tier.\n\n * 400 InstancePoolRequestMissingSkuFamily - Instance Pool request is missing Sku Family.\n\n * 400 InstancePoolRequestedSubnetResourceIdIsInvalid - Subnet Resource Id for instance pool is Null or empty.\n\n * 400 InstancePoolRequestedLicenseTypeIsInvalid - License Type for instacne pool is Null or empty.\n\n * 409 InstancePoolBusy - An instance pool is busy with another ongoing operation." + }, + "202": { + "description": "Accepted" + }, + "201": { + "description": "Successfully created the instance pool.", + "schema": { + "$ref": "#/definitions/InstancePool" + } + } + }, + "x-ms-long-running-operation": true, + "x-ms-examples": { + "Create an instance pool with all properties.": { + "$ref": "./examples/CreateOrUpdateInstancePoolMax.json" + }, + "Create an instance pool with min properties.": { + "$ref": "./examples/CreateOrUpdateInstancePoolMin.json" + } + } + }, + "delete": { + "tags": [ + "InstancePools" + ], + "description": "Deletes an instance pool", + "operationId": "InstancePools_Delete", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "name": "instancePoolName", + "in": "path", + "description": "The name of the instance pool to be deleted", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully deleted the instance pool." + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 InstancePoolNotEmpty - An instance pool is not empty.\n\n * 404 InstancePoolNotFound - An instance pool cannot be found.\n\n * 404 InstancePoolNotFound - An instance pool cannot be found.\n\n * 409 InstancePoolBusy - An instance pool is busy with another ongoing operation." + }, + "202": { + "description": "Accepted" + }, + "204": { + "description": "The specified instance pool does not exist." + } + }, + "x-ms-long-running-operation": true, + "x-ms-examples": { + "Delete an instance pool": { + "$ref": "./examples/DeleteInstancePool.json" + } + } + }, + "patch": { + "tags": [ + "InstancePools" + ], + "description": "Updates an instance pool.", + "operationId": "InstancePools_Update", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "name": "instancePoolName", + "in": "path", + "description": "The name of the instance pool to be updated.", + "required": true, + "type": "string" + }, + { + "name": "parameters", + "in": "body", + "description": "The requested instance pool resource state.", + "required": true, + "schema": { + "$ref": "#/definitions/InstancePoolUpdate" + } + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully updated the instance pool.", + "schema": { + "$ref": "#/definitions/InstancePool" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 InvalidResourceRequestBody - The resource or resource properties in the request body is empty or invalid." + }, + "202": { + "description": "Accepted" + } + }, + "x-ms-long-running-operation": true, + "x-ms-examples": { + "Patch an instance pool": { + "$ref": "./examples/PatchInstancePool.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/instancePools": { + "get": { + "tags": [ + "InstancePools" + ], + "description": "Gets a list of instance pools in the resource group", + "operationId": "InstancePools_ListByResourceGroup", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the list of instance pools.", + "schema": { + "$ref": "#/definitions/InstancePoolListResult" + } + }, + "default": { + "description": "*** Error Responses: ***" + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + }, + "x-ms-examples": { + "List instance pools by resource group": { + "$ref": "./examples/ListInstancePools.json" + } + } + } + } + }, + "definitions": { + "Sku": { + "description": "An ARM Resource SKU.", + "required": [ + "name" + ], + "type": "object", + "properties": { + "name": { + "description": "The name of the SKU, typically, a letter + Number code, e.g. P3.", + "type": "string" + }, + "tier": { + "description": "The tier of the particular SKU, e.g. Basic, Premium.", + "type": "string" + }, + "size": { + "description": "Size of the particular SKU", + "type": "string" + }, + "family": { + "description": "If the service has different generations of hardware, for the same SKU, then that can be captured here.", + "type": "string" + }, + "capacity": { + "format": "int32", + "description": "Capacity of the particular SKU.", + "type": "integer" + } + } + }, + "InstancePoolProperties": { + "description": "Properties of an instance pool.", + "required": [ + "subnetId", + "vCores", + "licenseType" + ], + "type": "object", + "properties": { + "subnetId": { + "description": "Resource ID of the subnet to place this instance pool in.", + "type": "string", + "x-ms-mutability": [ + "read", + "create" + ] + }, + "vCores": { + "format": "int32", + "description": "Count of vCores belonging to this instance pool.", + "type": "integer", + "x-ms-mutability": [ + "read", + "create" + ] + }, + "licenseType": { + "description": "License Type of this instance pool.", + "type": "string", + "x-ms-mutability": [ + "read", + "create" + ] + } + } + }, + "Resource": { + "description": "ARM resource.", + "type": "object", + "properties": { + "id": { + "description": "Resource ID.", + "type": "string", + "readOnly": true + }, + "name": { + "description": "Resource name.", + "type": "string", + "readOnly": true + }, + "type": { + "description": "Resource type.", + "type": "string", + "readOnly": true + } + }, + "x-ms-azure-resource": true + }, + "TrackedResource": { + "description": "ARM tracked top level resource.", + "required": [ + "location" + ], + "type": "object", + "allOf": [ + { + "$ref": "#/definitions/Resource" + } + ], + "properties": { + "location": { + "description": "Resource location.", + "type": "string", + "x-ms-mutability": [ + "read", + "create" + ] + }, + "tags": { + "description": "Resource tags.", + "type": "object", + "additionalProperties": { + "type": "string" + } + } + } + }, + "InstancePool": { + "description": "An Azure SQL instance pool.", + "required": [ + "location" + ], + "type": "object", + "allOf": [ + { + "$ref": "#/definitions/TrackedResource" + } + ], + "properties": { + "sku": { + "$ref": "#/definitions/Sku", + "description": "The name and tier of the SKU." + }, + "properties": { + "$ref": "#/definitions/InstancePoolProperties", + "description": "Resource properties.", + "x-ms-client-flatten": true + } + } + }, + "InstancePoolUpdate": { + "description": "An update to an Instance pool.", + "type": "object", + "properties": { + "tags": { + "description": "Resource tags.", + "type": "object", + "additionalProperties": { + "type": "string" + } + } + } + }, + "InstancePoolListResult": { + "description": "A list of Azure SQL instance pools.", + "type": "object", + "properties": { + "value": { + "description": "Array of results.", + "type": "array", + "items": { + "$ref": "#/definitions/InstancePool" + }, + "readOnly": true + }, + "nextLink": { + "description": "Link to retrieve next page of results.", + "type": "string", + "readOnly": true + } + } + } + }, + "parameters": { + "SubscriptionIdParameter": { + "name": "subscriptionId", + "in": "path", + "description": "The subscription ID that identifies an Azure subscription.", + "required": true, + "type": "string", + "x-ms-parameter-location": "client" + }, + "ApiVersionParameter": { + "name": "api-version", + "in": "query", + "description": "The API version to use for the request.", + "required": true, + "type": "string", + "x-ms-parameter-location": "client" + }, + "ResourceGroupParameter": { + "name": "resourceGroupName", + "in": "path", + "description": "The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "ServerNameParameter": { + "name": "serverName", + "in": "path", + "description": "The name of the server.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "ManagedInstanceNameParameter": { + "name": "managedInstanceName", + "in": "path", + "description": "The name of the managed instance.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "DatabaseNameParameter": { + "name": "databaseName", + "in": "path", + "description": "The name of the database.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "BlobAuditingPolicyNameParameter": { + "name": "blobAuditingPolicyName", + "in": "path", + "description": "The name of the blob auditing policy.", + "required": true, + "type": "string", + "enum": [ + "default" + ], + "x-ms-parameter-location": "method" + }, + "SqlVirtualMachineInstanceNameParameter": { + "name": "sqlVirtualMachineInstanceName", + "in": "path", + "description": "The name of the SqlVirtualMachineInstance.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "SqlVirtualMachineContainerNameParameter": { + "name": "sqlVirtualMachineContainerName", + "in": "path", + "description": "The name of the SqlVirtualMachineContainer.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "VirtualClusterNameParameter": { + "name": "virtualClusterName", + "in": "path", + "description": "The name of the virtual cluster.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + } + }, + "securityDefinitions": { + "azure_auth": { + "type": "oauth2", + "description": "Azure Active Directory OAuth2 Flow", + "flow": "implicit", + "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", + "scopes": { + "user_impersonation": "impersonate your user account" + } + } + } +} \ No newline at end of file From 4d1949b70d5dac7b03ba1dccc8d508bf0ac2b41d Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Mon, 17 Jun 2019 16:19:25 -0700 Subject: [PATCH 02/11] Update managed instance swaggers - move ManagedInstanceListByInstancePool to 2018-06-01-preview --- .../2015-05-01-preview/managedInstances.json | 50 +- .../examples/ManagedInstanceCreateMax.json | 99 ++ .../examples/ManagedInstanceCreateMin.json | 86 ++ .../examples/ManagedInstanceDelete.json | 17 + .../examples/ManagedInstanceGet.json | 41 + .../examples/ManagedInstanceList.json | 64 ++ .../ManagedInstanceListByInstancePool.json | 0 .../ManagedInstanceListByResourceGroup.json | 65 ++ .../examples/ManagedInstanceUpdateMax.json | 62 + .../examples/ManagedInstanceUpdateMin.json | 47 + ...ityAssessmentCreateContainerSasKeyMin.json | 47 - ...tanceVulnerabilityAssessmentCreateMax.json | 53 - ...tyAssessmentCreateStorageAccessKeyMin.json | 47 - ...InstanceVulnerabilityAssessmentDelete.json | 13 - ...gedInstanceVulnerabilityAssessmentGet.json | 26 - ...VulnerabilityAssessmentListByInstance.json | 29 - ...ManagedInstancesListMetricDefinitions.json | 132 +++ .../examples/ManagedInstancesListMetrics.json | 148 +++ .../2018-06-01-preview/managedInstances.json | 1020 +++++++++++++++++ 19 files changed, 1783 insertions(+), 263 deletions(-) create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json rename specification/sql/resource-manager/Microsoft.Sql/preview/{2015-05-01-preview => 2018-06-01-preview}/examples/ManagedInstanceListByInstancePool.json (100%) create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateContainerSasKeyMin.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateMax.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateStorageAccessKeyMin.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentDelete.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentGet.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentListByInstance.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/managedInstances.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/managedInstances.json index 111fb778f6a6..b50eb3ab1b62 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/managedInstances.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/managedInstances.json @@ -130,7 +130,7 @@ } }, "default": { - "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.\n\n * 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.\n\n * 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.\n\n * 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.\n\n * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet\n\n * 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.\n\n * 400 InvalidUsername - Supplied user name contains invalid characters.\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity\n\n * 400 ServerNotFound - The requested server was not found.\n\n * 400 TokenTooLong - The provided token is too long.\n\n * 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.\n\n * 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.\n\n * 400 InvalidLoginName - The provided login name is invalid.\n\n * 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.\n\n * 400 PasswordTooShort - The provided password is too short\n\n * 400 PasswordTooLong - The provided password is too long.\n\n * 400 PasswordNotComplex - The provided password is not complex enough.\n\n * 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.\n\n * 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 InvalidLocation - An invalid location was specified.\n\n * 400 VnetInWrongRegion - Virtual network is in wrong region.\n\n * 400 InvalidServerName - Invalid server name specified.\n\n * 400 VnetAddressRangeError - Virtual network address range is invalid.\n\n * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.\n\n * 400 InvalidCollation - Invalid collation.\n\n * 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.\n\n * 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.\n\n * 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.\n\n * 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.\n\n * 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.\n\n * 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.\n\n * 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.\n\n * 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.\n\n * 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.\n\n * 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.\n\n * 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.\n\n * 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.\n\n * 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.\n\n * 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.\n\n * 400 NameAlreadyExists - The provided name already exists.\n\n * 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.\n\n * 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes\n\n * 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.\n\n * 400 ManagedInstanceUpdateSloInProgress - \"The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again.\"\n\n * 400 VnetResourceNotFound - Resource not found: '{0}'.\n\n * 400 InvalidTimezone - Invalid timezone.\n\n * 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.\n\n * 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.\n\n * 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.\n\n * 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.\n\n * 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.\n\n * 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.\n\n * 400 InvalidManagedServerDnsZonePartner - Invalid DNS zone partner resource id specified in properties.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.\n\n * 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.\n\n * 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.\n\n * 405 InvalidStorageSizeValue - \"Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 409 ConflictingServerOperation - An operation is currently in progress for the server.\n\n * 409 SubscriptionDisabled - Subscription is disabled.\n\n * 409 ServerAlreadyExists - Duplicate server name.\n\n * 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.\n\n * 409 ServerDisabled - Server is disabled.\n\n * 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.\n\n * 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 500 GatewayInternalServerError - The server encountered an unexpected exception.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.\n\n * 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.\n\n * 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.\n\n * 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.\n\n * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet\n\n * 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.\n\n * 400 SubnetHasResourcesOfDifferentType - User tried to create MI in subnet that has resources of different type.\n\n * 400 InvalidUsername - Supplied user name contains invalid characters.\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity\n\n * 400 ServerNotFound - The requested server was not found.\n\n * 400 TokenTooLong - The provided token is too long.\n\n * 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.\n\n * 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.\n\n * 400 InvalidLoginName - The provided login name is invalid.\n\n * 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.\n\n * 400 PasswordTooShort - The provided password is too short\n\n * 400 PasswordTooLong - The provided password is too long.\n\n * 400 PasswordNotComplex - The provided password is not complex enough.\n\n * 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.\n\n * 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 InvalidLocation - An invalid location was specified.\n\n * 400 VnetInWrongRegion - Virtual network is in wrong region.\n\n * 400 InvalidServerName - Invalid server name specified.\n\n * 400 VnetAddressRangeError - Virtual network address range is invalid.\n\n * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.\n\n * 400 InvalidCollation - Invalid collation.\n\n * 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.\n\n * 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.\n\n * 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.\n\n * 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.\n\n * 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.\n\n * 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.\n\n * 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.\n\n * 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.\n\n * 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.\n\n * 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.\n\n * 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.\n\n * 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.\n\n * 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.\n\n * 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.\n\n * 400 NameAlreadyExists - The provided name already exists.\n\n * 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.\n\n * 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes\n\n * 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.\n\n * 400 ManagedInstanceUpdateSloInProgress - \"The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again.\"\n\n * 400 VnetResourceNotFound - Resource not found: '{0}'.\n\n * 400 InvalidTimezone - Invalid timezone.\n\n * 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.\n\n * 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.\n\n * 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.\n\n * 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.\n\n * 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.\n\n * 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.\n\n * 400 InvalidManagedServerDnsZonePartner - Invalid DNS zone partner resource id specified in properties.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.\n\n * 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.\n\n * 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.\n\n * 405 InvalidStorageSizeValue - \"Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 409 ConflictingServerOperation - An operation is currently in progress for the server.\n\n * 409 SubscriptionDisabled - Subscription is disabled.\n\n * 409 ServerAlreadyExists - Duplicate server name.\n\n * 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.\n\n * 409 ServerDisabled - Server is disabled.\n\n * 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.\n\n * 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 500 GatewayInternalServerError - The server encountered an unexpected exception.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." }, "202": { "description": "Accepted" @@ -230,7 +230,7 @@ } }, "default": { - "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.\n\n * 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.\n\n * 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.\n\n * 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.\n\n * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet\n\n * 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.\n\n * 400 InvalidUsername - Supplied user name contains invalid characters.\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity\n\n * 400 ServerNotFound - The requested server was not found.\n\n * 400 TokenTooLong - The provided token is too long.\n\n * 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.\n\n * 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.\n\n * 400 InvalidLoginName - The provided login name is invalid.\n\n * 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.\n\n * 400 PasswordTooShort - The provided password is too short\n\n * 400 PasswordTooLong - The provided password is too long.\n\n * 400 PasswordNotComplex - The provided password is not complex enough.\n\n * 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.\n\n * 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 InvalidLocation - An invalid location was specified.\n\n * 400 VnetInWrongRegion - Virtual network is in wrong region.\n\n * 400 InvalidServerName - Invalid server name specified.\n\n * 400 VnetAddressRangeError - Virtual network address range is invalid.\n\n * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.\n\n * 400 InvalidCollation - Invalid collation.\n\n * 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.\n\n * 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.\n\n * 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.\n\n * 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.\n\n * 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.\n\n * 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.\n\n * 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.\n\n * 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.\n\n * 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.\n\n * 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.\n\n * 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.\n\n * 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.\n\n * 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.\n\n * 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.\n\n * 400 NameAlreadyExists - The provided name already exists.\n\n * 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.\n\n * 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes\n\n * 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.\n\n * 400 ManagedInstanceUpdateSloInProgress - \"The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again.\"\n\n * 400 VnetResourceNotFound - Resource not found: '{0}'.\n\n * 400 InvalidTimezone - Invalid timezone.\n\n * 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.\n\n * 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.\n\n * 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.\n\n * 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.\n\n * 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.\n\n * 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.\n\n * 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.\n\n * 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.\n\n * 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.\n\n * 405 InvalidStorageSizeValue - \"Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 409 ConflictingServerOperation - An operation is currently in progress for the server.\n\n * 409 SubscriptionDisabled - Subscription is disabled.\n\n * 409 ServerAlreadyExists - Duplicate server name.\n\n * 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.\n\n * 409 ServerDisabled - Server is disabled.\n\n * 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.\n\n * 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 500 GatewayInternalServerError - The server encountered an unexpected exception.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.\n\n * 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.\n\n * 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.\n\n * 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.\n\n * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet\n\n * 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.\n\n * 400 SubnetHasResourcesOfDifferentType - User tried to create MI in subnet that has resources of different type.\n\n * 400 InvalidUsername - Supplied user name contains invalid characters.\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity\n\n * 400 ServerNotFound - The requested server was not found.\n\n * 400 TokenTooLong - The provided token is too long.\n\n * 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.\n\n * 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.\n\n * 400 InvalidLoginName - The provided login name is invalid.\n\n * 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.\n\n * 400 PasswordTooShort - The provided password is too short\n\n * 400 PasswordTooLong - The provided password is too long.\n\n * 400 PasswordNotComplex - The provided password is not complex enough.\n\n * 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.\n\n * 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 InvalidLocation - An invalid location was specified.\n\n * 400 VnetInWrongRegion - Virtual network is in wrong region.\n\n * 400 InvalidServerName - Invalid server name specified.\n\n * 400 VnetAddressRangeError - Virtual network address range is invalid.\n\n * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.\n\n * 400 InvalidCollation - Invalid collation.\n\n * 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.\n\n * 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.\n\n * 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.\n\n * 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.\n\n * 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.\n\n * 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.\n\n * 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.\n\n * 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.\n\n * 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.\n\n * 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.\n\n * 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.\n\n * 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.\n\n * 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.\n\n * 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.\n\n * 400 NameAlreadyExists - The provided name already exists.\n\n * 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.\n\n * 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes\n\n * 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.\n\n * 400 ManagedInstanceUpdateSloInProgress - \"The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again.\"\n\n * 400 VnetResourceNotFound - Resource not found: '{0}'.\n\n * 400 InvalidTimezone - Invalid timezone.\n\n * 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.\n\n * 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.\n\n * 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.\n\n * 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.\n\n * 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.\n\n * 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.\n\n * 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.\n\n * 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.\n\n * 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.\n\n * 405 InvalidStorageSizeValue - \"Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 409 ConflictingServerOperation - An operation is currently in progress for the server.\n\n * 409 SubscriptionDisabled - Subscription is disabled.\n\n * 409 ServerAlreadyExists - Duplicate server name.\n\n * 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.\n\n * 409 ServerDisabled - Server is disabled.\n\n * 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.\n\n * 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 500 GatewayInternalServerError - The server encountered an unexpected exception.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." }, "202": { "description": "Accepted" @@ -247,52 +247,6 @@ } } }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/instancePools/{instancePoolName}/managedInstances": { - "get": { - "tags": [ - "ManagedInstances" - ], - "description": "Gets a list of all managed instances in an instance pool.", - "operationId": "ManagedInstances_ListByInstancePool", - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupParameter" - }, - { - "name": "instancePoolName", - "in": "path", - "description": "The instance pool name.", - "required": true, - "type": "string" - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully retrieved the list of managed instances.", - "schema": { - "$ref": "#/definitions/ManagedInstanceListResult" - } - }, - "default": { - "description": "*** Error Responses: ***\n\n * 404 InstancePoolNotFound - An instance pool cannot be found" - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "List managed instances by instance pool": { - "$ref": "./examples/ManagedInstanceListByInstancePool.json" - } - } - } - }, "/subscriptions/{subscriptionId}/providers/Microsoft.Sql/managedInstances": { "get": { "tags": [ diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json new file mode 100644 index 000000000000..45ba619264f4 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json @@ -0,0 +1,99 @@ +{ + "parameters" : { + "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName" : "testrg", + "managedInstanceName" : "testinstance", + "api-version" : "2015-05-01-preview", + "parameters" : { + "tags" : { + "tagKey1" : "TagValue1" + }, + "location" : "Japan East", + "sku" : { + "name" : "GP_Gen5", + "tier" : "GeneralPurpose" + }, + "properties": { + "administratorLogin": "dummylogin", + "administratorLoginPassword": "Un53cuRE!", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "dnsZonePartner": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "publicDataEndpointEnabled": false, + "proxyOverride": "Redirect", + "timezoneId": "UTC", + "instancePoolId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1" + } + } + }, + "responses" : { + "200": { + "body": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen5" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Redirect", + "dnsZone": "1b4e2caff2530", + "timezoneId": "UTC", + "instancePoolId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1" + }, + "location": "japaneast", + "tags": { + "tagKey1": "TagValue1" + }, + "id": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + }, + "201" : { + "body": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen5" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Redirect", + "dnsZone": "1b4e2caff2530", + "timezoneId": "UTC", + "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1" + }, + "location": "japaneast", + "tags": { + "tagKey1": "TagValue1" + }, + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + }, + "202" : {} + } +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json new file mode 100644 index 000000000000..02d525123917 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json @@ -0,0 +1,86 @@ +{ + "parameters": { + "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName": "testrg", + "managedInstanceName": "testinstance", + "api-version": "2015-05-01-preview", + "parameters": { + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose" + }, + "properties": { + "administratorLogin": "dummylogin", + "administratorLoginPassword": "Un53cuRE!", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded" + }, + "location": "Japan East" + } + }, + "responses": { + "200": { + "body": { + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "1b4e2caff2530" + }, + "location": "japaneast", + "tags": { + + }, + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + }, + "201": { + "body": { + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Redirect", + "dnsZone": "1b4e2caff2530" + }, + "location": "japaneast", + "tags": { + + }, + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + }, + "202": {} + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json new file mode 100644 index 000000000000..1b1db6fb5f6a --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json @@ -0,0 +1,17 @@ +{ + "parameters" : { + "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName" : "testrg", + "managedInstanceName" : "testinstance", + "api-version" : "2015-05-01-preview" + }, + "responses" : { + "200" : { + "body" : "" + }, + "202" : {}, + "204" : { + "body" : "" + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json new file mode 100644 index 000000000000..6951eb9f6334 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json @@ -0,0 +1,41 @@ +{ + "parameters" : { + "subscriptionId" : "20d7082a-0fc7-4468-82bd-542694d5042b", + "resourceGroupName" : "testrg", + "managedInstanceName" : "testinstance", + "api-version" : "2015-05-01-preview" + }, + "responses" : { + "200" : { + "body": { + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "1b4e2caff2530", + "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1" + }, + "location": "japaneast", + "tags": { + "key": "value" + }, + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json new file mode 100644 index 000000000000..d34540b24f5b --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json @@ -0,0 +1,64 @@ +{ + "parameters" : { + "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", + "api-version" : "2015-05-01-preview" + }, + "responses" : { + "200" : { + "body" : { + "value": [ + { + "location": "japaneast", + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance1", + "name": "testinstance1", + "type": "Microsoft.Sql/managedInstances", + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance1.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "1b4e2caff2530" + } + }, + { + "location": "japaneast", + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance2", + "name": "testinstance2", + "type": "Microsoft.Sql/managedInstances", + "sku": { + "name": "BC_Gen5", + "tier": "BusinessCritical", + "capacity": 16, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance2.2c3d1bdae3412.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet2/subnets/subnet2", + "state": "Ready", + "vCores": 16, + "storageSizeInGB": 1024, + "licenseType": "Full", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "2c3d1bdae3412" + } + } + ] + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/examples/ManagedInstanceListByInstancePool.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByInstancePool.json similarity index 100% rename from specification/sql/resource-manager/Microsoft.Sql/preview/2015-05-01-preview/examples/ManagedInstanceListByInstancePool.json rename to specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByInstancePool.json diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json new file mode 100644 index 000000000000..57fc3c367920 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json @@ -0,0 +1,65 @@ +{ + "parameters": { + "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName": "Test1", + "api-version": "2015-05-01-preview" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "location": "japaneast", + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance1", + "name": "testinstance1", + "type": "Microsoft.Sql/managedInstances", + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance1.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "1b4e2caff2530" + } + }, + { + "location": "japaneast", + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance2", + "name": "testinstance2", + "type": "Microsoft.Sql/managedInstances", + "sku": { + "name": "BC_Gen5", + "tier": "BusinessCritical", + "capacity": 16, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance2.2c3d1bdae3412.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet2/subnets/subnet2", + "state": "Ready", + "vCores": 16, + "storageSizeInGB": 1024, + "licenseType": "Full", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "2c3d1bdae3412" + } + } + ] + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json new file mode 100644 index 000000000000..672c99ee76bd --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json @@ -0,0 +1,62 @@ +{ + "parameters" : { + "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName" : "testrg", + "managedInstanceName" : "testinstance", + "api-version" : "2015-05-01-preview", + "parameters" : { + "tags" : { + "tagKey1" : "TagValue1" + }, + "sku" : { + "name" : "GP_Gen4", + "tier" : "GeneralPurpose", + "capacity" : 8 + }, + "properties": { + "administratorLogin": "dummylogin", + "administratorLoginPassword": "Un53cuRE!", + "proxyOverride": "Redirect", + "publicDataEndpointEnabled": false, + "licenseType": "BasePrice", + "vCores": 8, + "storageSizeInGB": 448, + "collation": "SQL_Latin1_General_CP1_CI_AS" + } + } + }, + "responses" : { + "200" : { + "body": { + "tags": { + "tagKey1": "TagValue1" + }, + "id": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances", + "location": "japaneast", + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 448, + "licenseType": "BasePrice", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Redirect", + "dnsZone": "1b4e2caff2530", + "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1" + } + } + }, + "202" : {} + } +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json new file mode 100644 index 000000000000..4a9a2b3da5ec --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json @@ -0,0 +1,47 @@ +{ + "parameters": { + "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName" : "testrg", + "managedInstanceName" : "testinstance", + "api-version": "2015-05-01-preview", + "parameters": { + "tags": { + "tagKey1": "TagValue1" + } + } + }, + "responses": { + "200": { + "body": { + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "1b4e2caff2530", + "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1" + }, + "location": "japaneast", + "tags": { + "tagKey1": "TagValue1" + }, + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + }, + "202": {} + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateContainerSasKeyMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateContainerSasKeyMin.json deleted file mode 100644 index 734446acb9f4..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateContainerSasKeyMin.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "parameters": { - "subscriptionId": "00000000-1111-2222-3333-444444444444", - "resourceGroupName": "vulnerabilityaseessmenttest-4799", - "managedInstanceName": "vulnerabilityaseessmenttest-6440", - "vulnerabilityAssessmentName": "default", - "api-version": "2018-06-01-preview", - "parameters": { - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "storageContainerSasKey": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" - } - } - }, - "responses": { - "200": { - "body": { - "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", - "name": "default", - "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "recurringScans": { - "isEnabled": true, - "emailSubscriptionAdmins": false, - "emails": [] - } - } - } - }, - "201": { - "body": { - "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", - "name": "default", - "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "recurringScans": { - "isEnabled": true, - "emailSubscriptionAdmins": false, - "emails": [] - } - } - } - } - } -} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateMax.json deleted file mode 100644 index dfafc5136e83..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateMax.json +++ /dev/null @@ -1,53 +0,0 @@ -{ - "parameters": { - "subscriptionId": "00000000-1111-2222-3333-444444444444", - "resourceGroupName": "vulnerabilityaseessmenttest-4799", - "managedInstanceName": "vulnerabilityaseessmenttest-6440", - "vulnerabilityAssessmentName": "default", - "api-version": "2018-06-01-preview", - "parameters": { - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "storageContainerSasKey": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX", - "storageAccountAccessKey": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX", - "recurringScans": { - "isEnabled": true, - "emailSubscriptionAdmins": true, - "emails": [ "email1@mail.com", "email2@mail.com" ] - } - } - } - }, - "responses": { - "200": { - "body": { - "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", - "name": "default", - "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "recurringScans": { - "isEnabled": true, - "emailSubscriptionAdmins": true, - "emails": [ "email1@mail.com", "email2@mail.com" ] - } - } - } - }, - "201": { - "body": { - "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", - "name": "default", - "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "recurringScans": { - "isEnabled": true, - "emailSubscriptionAdmins": true, - "emails": [ "email1@mail.com", "email2@mail.com" ] - } - } - } - } - } -} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateStorageAccessKeyMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateStorageAccessKeyMin.json deleted file mode 100644 index 9f9bf693499c..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateStorageAccessKeyMin.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "parameters": { - "subscriptionId": "00000000-1111-2222-3333-444444444444", - "resourceGroupName": "vulnerabilityaseessmenttest-4799", - "managedInstanceName": "vulnerabilityaseessmenttest-6440", - "vulnerabilityAssessmentName": "default", - "api-version": "2018-06-01-preview", - "parameters": { - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "storageAccountAccessKey": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" - } - } - }, - "responses": { - "200": { - "body": { - "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", - "name": "default", - "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "recurringScans": { - "isEnabled": true, - "emailSubscriptionAdmins": false, - "emails": [] - } - } - } - }, - "201": { - "body": { - "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", - "name": "default", - "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "recurringScans": { - "isEnabled": true, - "emailSubscriptionAdmins": false, - "emails": [] - } - } - } - } - } -} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentDelete.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentDelete.json deleted file mode 100644 index cea35165541e..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentDelete.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "parameters": { - "subscriptionId": "00000000-1111-2222-3333-444444444444", - "resourceGroupName": "vulnerabilityaseessmenttest-4799", - "managedInstanceName": "vulnerabilityaseessmenttest-6440", - "vulnerabilityAssessmentName": "default", - "api-version": "2018-06-01-preview" - }, - "responses": { - "200": { - } - } -} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentGet.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentGet.json deleted file mode 100644 index f422631ceb9a..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentGet.json +++ /dev/null @@ -1,26 +0,0 @@ -{ - "parameters": { - "subscriptionId": "00000000-1111-2222-3333-444444444444", - "resourceGroupName": "vulnerabilityaseessmenttest-4799", - "managedInstanceName": "vulnerabilityaseessmenttest-6440", - "vulnerabilityAssessmentName": "default", - "api-version": "2018-06-01-preview" - }, - "responses": { - "200": { - "body": { - "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", - "name": "default", - "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "recurringScans": { - "isEnabled": true, - "emailSubscriptionAdmins": true, - "emails": [ "email1@mail.com", "email2@mail.com" ] - } - } - } - } - } -} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentListByInstance.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentListByInstance.json deleted file mode 100644 index 1a3462f5a36a..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentListByInstance.json +++ /dev/null @@ -1,29 +0,0 @@ -{ - "parameters": { - "subscriptionId": "00000000-1111-2222-3333-444444444444", - "resourceGroupName": "vulnerabilityaseessmenttest-4799", - "managedInstanceName": "vulnerabilityaseessmenttest-6440", - "api-version": "2018-06-01-preview" - }, - "responses": { - "200": { - "body": { - "value": [ - { - "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", - "name": "default", - "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", - "properties": { - "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", - "recurringScans": { - "isEnabled": true, - "emailSubscriptionAdmins": true, - "emails": [ "email1@mail.com", "email2@mail.com" ] - } - } - } - ] - } - } - } -} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json new file mode 100644 index 000000000000..a08bc1535212 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json @@ -0,0 +1,132 @@ +{ + "parameters":{ + "subscriptionId":"00000000-1111-2222-3333-444444444444", + "resourceGroupName":"Test1", + "managedInstanceName":"managedInstance", + "api-version":"2017-10-01-preview" + }, + "responses":{ + "200":{ + "body":{ + "value":[ + { + "name":{ + "value":"reserved_storage_mb", + "localizedValue":"Storage space reserved" + }, + "unit":"Bytes", + "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", + "primaryAggregationType":"Average", + "supportedAggregationTypes":[ + "Average", + "Minimum", + "Maximum", + "Count" + ], + "metricAvailabilities":[ + { + "timeGrain":"PT5M", + "retention":"P14D" + }, + { + "timeGrain":"PT1H", + "retention":"P14D" + }, + { + "timeGrain":"P1D", + "retention":"P14D" + } + ] + }, + { + "name":{ + "value":"storage_space_used_mb", + "localizedValue":"Storage space used" + }, + "unit":"Bytes", + "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", + "primaryAggregationType":"Average", + "supportedAggregationTypes":[ + "Average", + "Minimum", + "Maximum", + "Count" + ], + "metricAvailabilities":[ + { + "timeGrain":"PT5M", + "retention":"P14D" + }, + { + "timeGrain":"PT1H", + "retention":"P14D" + }, + { + "timeGrain":"P1D", + "retention":"P14D" + } + ] + }, + { + "name":{ + "value":"avg_cpu_percent", + "localizedValue":"Average CPU percentage" + }, + "unit":"Percent", + "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", + "primaryAggregationType":"Average", + "supportedAggregationTypes":[ + "Average", + "Minimum", + "Maximum", + "Count" + ], + "metricAvailabilities":[ + { + "timeGrain":"PT5M", + "retention":"P14D" + }, + { + "timeGrain":"PT1H", + "retention":"P14D" + }, + { + "timeGrain":"P1D", + "retention":"P14D" + } + ] + }, + { + "name":{ + "value":"virtual_core_count", + "localizedValue":"Virtual core count" + }, + "unit":"Count", + "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", + "primaryAggregationType":"Average", + "supportedAggregationTypes":[ + "Average", + "Minimum", + "Maximum", + "Count" + ], + "metricAvailabilities":[ + { + "timeGrain":"PT5M", + "retention":"P14D" + }, + { + "timeGrain":"PT1H", + "retention":"P14D" + }, + { + "timeGrain":"P1D", + "retention":"P14D" + } + ] + } + ] + } + } + } + } \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json new file mode 100644 index 000000000000..8ec4dbff4d00 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json @@ -0,0 +1,148 @@ +{ + "parameters":{ + "subscriptionId":"00000000-1111-2222-3333-444444444444", + "resourceGroupName":"Test1", + "managedInstanceName":"managedInstance", + "metric":"avg_cpu_percent", + "timespan":"2018-03-01T00:00:00Z/2018-03-03T18:00:00Z", + "aggregation":"average", + "interval":"PT5M", + "api-version":"2017-10-01-preview" + }, + "responses":{ + "200":{ + "body":{ + "value":[ + { + "name":{ + "value":"avg_cpu_percent", + "localizedValue":"Average CPU percentage" + }, + "unit":"Percent", + "timeGrain":"PT5M", + "startTime":"3/1/2018 1:00:00 AM", + "endTime":"3/3/2018 7:00:00 PM", + "timeseries":[ + { + "data":[ + { + "timeStamp":"2018-03-02T13:30:01Z", + "average":1.881666, + "minimum":0.13, + "maximum":7.06, + "count":12 + }, + { + "timeStamp":"2018-03-02T13:35:01Z", + "average":0.8755, + "minimum":0.12, + "maximum":4.22, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:40:01Z", + "average":0.4665, + "minimum":0.14, + "maximum":2.31, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:45:01Z", + "average":0.3545, + "minimum":0.13, + "maximum":1.72, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:50:01Z", + "average":0.3505, + "minimum":0.13, + "maximum":1.38, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:55:01Z", + "average":0.3535, + "minimum":0.13, + "maximum":1.39, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:00:01Z", + "average":0.418, + "minimum":0.13, + "maximum":1.54, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:05:01Z", + "average":0.35, + "minimum":0.15, + "maximum":1.44, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:10:01Z", + "average":0.3525, + "minimum":0.14, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:15:01Z", + "average":0.352, + "minimum":0.15, + "maximum":1.56, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:20:01Z", + "average":0.3495, + "minimum":0.16, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:25:01Z", + "average":0.368, + "minimum":0.15, + "maximum":1.31, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:30:01Z", + "average":0.438, + "minimum":0.15, + "maximum":2.69, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:35:01Z", + "average":0.3895, + "minimum":0.16, + "maximum":1.29, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:40:01Z", + "average":0.3515, + "minimum":0.12, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:45:01Z", + "average":0.405263, + "minimum":0.12, + "maximum":2.17, + "count":19 + } + ] + } + ] + } + ] + } + } + } + } \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json new file mode 100644 index 000000000000..74174755d34f --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json @@ -0,0 +1,1020 @@ +{ + "swagger": "2.0", + "info": { + "version": "2018-06-01-preview", + "title": "SqlManagementClient", + "description": "The Azure SQL Database management API provides a RESTful set of web APIs that interact with Azure SQL Database services to manage your databases. The API enables users to create, retrieve, update, and delete databases, servers, and other entities." + }, + "host": "management.azure.com", + "schemes": [ + "https" + ], + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "paths": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/metricDefinitions": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a list of managed instance metric definitions.", + "operationId": "ManagedInstances_ListMetricDefinitions", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the list of metric definitions for managed instance.", + "schema": { + "$ref": "#/definitions/MetricDefinitionListResult" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 404 ServerNotFound - The requested server was not found.\n\n * 405 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + }, + "x-ms-examples": { + "List metric definitions by managed instance": { + "$ref": "./examples/ManagedInstancesListMetricDefinitions.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/metrics": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a list of managed instance metrics.", + "operationId": "ManagedInstances_ListMetrics", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "name": "metric", + "in": "query", + "description": "Name of the metrics to get.", + "required": false, + "type": "string" + }, + { + "name": "timespan", + "in": "query", + "description": "The timespan for the metric.", + "required": false, + "type": "string" + }, + { + "name": "aggregation", + "in": "query", + "description": "The aggregation type to use.", + "required": false, + "type": "string" + }, + { + "name": "interval", + "in": "query", + "description": "The time step to be used to summarize the metric values.", + "required": false, + "type": "string" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the list of databases.", + "schema": { + "$ref": "#/definitions/MetricListResult" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 404 ServerNotFound - The requested server was not found.\n\n * 405 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + }, + "x-ms-examples": { + "List metrics by managed instance": { + "$ref": "./examples/ManagedInstancesListMetrics.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/instancePools/{instancePoolName}/managedInstances": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a list of all managed instances in an instance pool.", + "operationId": "ManagedInstances_ListByInstancePool", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "name": "instancePoolName", + "in": "path", + "description": "The instance pool name.", + "required": true, + "type": "string" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the list of managed instances.", + "schema": { + "$ref": "#/definitions/ManagedInstanceListResult" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 404 InstancePoolNotFound - An instance pool cannot be found" + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + }, + "x-ms-examples": { + "List managed instances by instance pool": { + "$ref": "./examples/ManagedInstanceListByInstancePool.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a list of managed instances in a resource group.", + "operationId": "ManagedInstances_ListByResourceGroup", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the list of managed instances.", + "schema": { + "$ref": "#/definitions/ManagedInstanceListResult" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + }, + "x-ms-examples": { + "List managed instances by resource group": { + "$ref": "./examples/ManagedInstanceListByResourceGroup.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a managed instance.", + "operationId": "ManagedInstances_Get", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the specified managed instance.", + "schema": { + "$ref": "#/definitions/ManagedInstance" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + } + }, + "x-ms-examples": { + "Get managed instance": { + "$ref": "./examples/ManagedInstanceGet.json" + } + } + }, + "put": { + "tags": [ + "ManagedInstances" + ], + "description": "Creates or updates a managed instance.", + "operationId": "ManagedInstances_CreateOrUpdate", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "name": "parameters", + "in": "body", + "description": "The requested managed instance resource state.", + "required": true, + "schema": { + "$ref": "#/definitions/ManagedInstance" + } + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully updated the managed instance.", + "schema": { + "$ref": "#/definitions/ManagedInstance" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.\n\n * 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.\n\n * 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.\n\n * 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.\n\n * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet\n\n * 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.\n\n * 400 SubnetHasResourcesOfDifferentType - User tried to create MI in subnet that has resources of different type.\n\n * 400 InvalidUsername - Supplied user name contains invalid characters.\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity\n\n * 400 ServerNotFound - The requested server was not found.\n\n * 400 TokenTooLong - The provided token is too long.\n\n * 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.\n\n * 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.\n\n * 400 InvalidLoginName - The provided login name is invalid.\n\n * 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.\n\n * 400 PasswordTooShort - The provided password is too short\n\n * 400 PasswordTooLong - The provided password is too long.\n\n * 400 PasswordNotComplex - The provided password is not complex enough.\n\n * 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.\n\n * 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 InvalidLocation - An invalid location was specified.\n\n * 400 VnetInWrongRegion - Virtual network is in wrong region.\n\n * 400 InvalidServerName - Invalid server name specified.\n\n * 400 VnetAddressRangeError - Virtual network address range is invalid.\n\n * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.\n\n * 400 InvalidCollation - Invalid collation.\n\n * 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.\n\n * 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.\n\n * 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.\n\n * 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.\n\n * 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.\n\n * 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.\n\n * 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.\n\n * 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.\n\n * 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.\n\n * 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.\n\n * 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.\n\n * 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.\n\n * 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.\n\n * 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.\n\n * 400 NameAlreadyExists - The provided name already exists.\n\n * 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.\n\n * 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes\n\n * 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.\n\n * 400 ManagedInstanceUpdateSloInProgress - \"The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again.\"\n\n * 400 VnetResourceNotFound - Resource not found: '{0}'.\n\n * 400 InvalidTimezone - Invalid timezone.\n\n * 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.\n\n * 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.\n\n * 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.\n\n * 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.\n\n * 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.\n\n * 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.\n\n * 400 InvalidManagedServerDnsZonePartner - Invalid DNS zone partner resource id specified in properties.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.\n\n * 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.\n\n * 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.\n\n * 405 InvalidStorageSizeValue - \"Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 409 ConflictingServerOperation - An operation is currently in progress for the server.\n\n * 409 SubscriptionDisabled - Subscription is disabled.\n\n * 409 ServerAlreadyExists - Duplicate server name.\n\n * 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.\n\n * 409 ServerDisabled - Server is disabled.\n\n * 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.\n\n * 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 500 GatewayInternalServerError - The server encountered an unexpected exception.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + }, + "202": { + "description": "Accepted" + }, + "201": { + "description": "Successfully created the managed instance.", + "schema": { + "$ref": "#/definitions/ManagedInstance" + } + } + }, + "x-ms-long-running-operation": true, + "x-ms-examples": { + "Create managed instance with minimal properties": { + "$ref": "./examples/ManagedInstanceCreateMin.json" + }, + "Create managed instance with all properties": { + "$ref": "./examples/ManagedInstanceCreateMax.json" + } + } + }, + "delete": { + "tags": [ + "ManagedInstances" + ], + "description": "Deletes a managed instance.", + "operationId": "ManagedInstances_Delete", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully deleted the managed instance." + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + }, + "202": { + "description": "Accepted" + }, + "204": { + "description": "The specified managed instance does not exist." + } + }, + "x-ms-long-running-operation": true, + "x-ms-examples": { + "Delete managed instance": { + "$ref": "./examples/ManagedInstanceDelete.json" + } + } + }, + "patch": { + "tags": [ + "ManagedInstances" + ], + "description": "Updates a managed instance.", + "operationId": "ManagedInstances_Update", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "name": "parameters", + "in": "body", + "description": "The requested managed instance resource state.", + "required": true, + "schema": { + "$ref": "#/definitions/ManagedInstanceUpdate" + } + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully updated the managed instance.", + "schema": { + "$ref": "#/definitions/ManagedInstance" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.\n\n * 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.\n\n * 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.\n\n * 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.\n\n * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet\n\n * 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.\n\n * 400 SubnetHasResourcesOfDifferentType - User tried to create MI in subnet that has resources of different type.\n\n * 400 InvalidUsername - Supplied user name contains invalid characters.\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity\n\n * 400 ServerNotFound - The requested server was not found.\n\n * 400 TokenTooLong - The provided token is too long.\n\n * 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.\n\n * 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.\n\n * 400 InvalidLoginName - The provided login name is invalid.\n\n * 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.\n\n * 400 PasswordTooShort - The provided password is too short\n\n * 400 PasswordTooLong - The provided password is too long.\n\n * 400 PasswordNotComplex - The provided password is not complex enough.\n\n * 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.\n\n * 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 InvalidLocation - An invalid location was specified.\n\n * 400 VnetInWrongRegion - Virtual network is in wrong region.\n\n * 400 InvalidServerName - Invalid server name specified.\n\n * 400 VnetAddressRangeError - Virtual network address range is invalid.\n\n * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.\n\n * 400 InvalidCollation - Invalid collation.\n\n * 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.\n\n * 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.\n\n * 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.\n\n * 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.\n\n * 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.\n\n * 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.\n\n * 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.\n\n * 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.\n\n * 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.\n\n * 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.\n\n * 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.\n\n * 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.\n\n * 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.\n\n * 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.\n\n * 400 NameAlreadyExists - The provided name already exists.\n\n * 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.\n\n * 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes\n\n * 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.\n\n * 400 ManagedInstanceUpdateSloInProgress - \"The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again.\"\n\n * 400 VnetResourceNotFound - Resource not found: '{0}'.\n\n * 400 InvalidTimezone - Invalid timezone.\n\n * 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.\n\n * 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.\n\n * 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.\n\n * 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.\n\n * 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.\n\n * 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.\n\n * 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.\n\n * 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.\n\n * 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.\n\n * 405 InvalidStorageSizeValue - \"Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 409 ConflictingServerOperation - An operation is currently in progress for the server.\n\n * 409 SubscriptionDisabled - Subscription is disabled.\n\n * 409 ServerAlreadyExists - Duplicate server name.\n\n * 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.\n\n * 409 ServerDisabled - Server is disabled.\n\n * 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.\n\n * 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 500 GatewayInternalServerError - The server encountered an unexpected exception.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + }, + "202": { + "description": "Accepted" + } + }, + "x-ms-long-running-operation": true, + "x-ms-examples": { + "Update managed instance with minimal properties": { + "$ref": "./examples/ManagedInstanceUpdateMin.json" + }, + "Update managed instance with all properties": { + "$ref": "./examples/ManagedInstanceUpdateMax.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/providers/Microsoft.Sql/managedInstances": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a list of all managed instances in the subscription.", + "operationId": "ManagedInstances_List", + "parameters": [ + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the list of managed instances.", + "schema": { + "$ref": "#/definitions/ManagedInstanceListResult" + } + }, + "default": { + "description": "*** Error Responses: ***" + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + }, + "x-ms-examples": { + "List managed instances": { + "$ref": "./examples/ManagedInstanceList.json" + } + } + } + } + }, + "definitions": { + "MetricDefinitionListResult": { + "description": "A list of metric definition resources.", + "type": "object", + "properties": { + "value": { + "description": "Array of results.", + "type": "array", + "items": { + "$ref": "#/definitions/MetricDefinition" + }, + "readOnly": true + }, + "nextLink": { + "description": "Link to retrieve next page of results.", + "type": "string", + "readOnly": true + } + } + }, + "MetricDefinition": { + "description": "A metric definition resource.", + "type": "object", + "properties": { + "name": { + "$ref": "#/definitions/MetricName", + "description": "Name of the metric.", + "readOnly": true + }, + "unit": { + "description": "The unit of the metric.", + "enum": [ + "Count", + "Bytes", + "Seconds", + "Percent", + "CountPerSecond", + "BytesPerSecond" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "UnitType", + "modelAsString": true + } + }, + "resourceId": { + "description": "The uri of the resource that the metric describes.", + "type": "string", + "readOnly": true + }, + "primaryAggregationType": { + "description": "The primary aggregation type defining how metric values are displayed.", + "enum": [ + "None", + "Average", + "Count", + "Minimum", + "Maximum", + "Total" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "PrimaryAggregationType", + "modelAsString": true + } + }, + "supportedAggregationTypes": { + "description": "The supported aggregation types defining how metric values are displayed.", + "type": "array", + "items": { + "type": "string" + }, + "readOnly": true + }, + "metricAvailabilities": { + "description": "The list of metric availabilities for the metric.", + "type": "array", + "items": { + "$ref": "#/definitions/MetricAvailability" + }, + "readOnly": true + } + } + }, + "MetricName": { + "description": "A managed instance metric name.", + "type": "object", + "properties": { + "value": { + "description": "The name of the database metric.", + "type": "string", + "readOnly": true + }, + "localizedValue": { + "description": "The friendly name of the database metric.", + "type": "string", + "readOnly": true + } + } + }, + "MetricAvailability": { + "description": "A metric availability value.", + "type": "object", + "properties": { + "timeGrain": { + "description": "The granularity of the database metric.", + "enum": [ + "PT5M", + "PT1H", + "P1D" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "TimeGrainType", + "modelAsString": true + } + }, + "retention": { + "description": "The length of retention for the database metric.", + "enum": [ + "P14D" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "RetentionType", + "modelAsString": true + } + } + } + }, + "MetricListResult": { + "description": "A list of metric resources.", + "type": "object", + "properties": { + "value": { + "description": "Array of results.", + "type": "array", + "items": { + "$ref": "#/definitions/Metric" + }, + "readOnly": true + }, + "nextLink": { + "description": "Link to retrieve next page of results.", + "type": "string", + "readOnly": true + } + } + }, + "Metric": { + "description": "A metric resource.", + "type": "object", + "properties": { + "name": { + "$ref": "#/definitions/MetricName", + "description": "The name information for the metric.", + "readOnly": true + }, + "unit": { + "description": "The unit of the metric.", + "enum": [ + "Count", + "Bytes", + "Seconds", + "Percent", + "CountPerSecond", + "BytesPerSecond" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "UnitType", + "modelAsString": true + } + }, + "timeGrain": { + "description": "The time step to be used to summarize the metric values.", + "enum": [ + "PT5M", + "PT1H", + "P1D" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "TimeGrainType", + "modelAsString": true + } + }, + "startTime": { + "description": "The start time for the metric (ISO-8601 format).", + "type": "string", + "readOnly": true + }, + "endTime": { + "description": "The end time for the metric (ISO-8601 format).", + "type": "string", + "readOnly": true + }, + "timeseries": { + "description": "The metric timeseries for the specified time window and timestep.", + "type": "array", + "items": { + "$ref": "#/definitions/MetricTimeseries" + }, + "readOnly": true + } + } + }, + "MetricTimeseries": { + "description": "A metric timeseries.", + "type": "object", + "properties": { + "data": { + "description": "The metric values for the specified time window and timestep.", + "type": "array", + "items": { + "$ref": "#/definitions/MetricValue" + }, + "readOnly": true + } + } + }, + "MetricValue": { + "description": "A metric value.", + "type": "object", + "properties": { + "timeStamp": { + "format": "date-time", + "description": "The metric timestamp (ISO-8601 format).", + "type": "string", + "readOnly": true + }, + "average": { + "format": "double", + "description": "The average value of the metric.", + "type": "number", + "readOnly": true + }, + "minimum": { + "format": "double", + "description": "The min value of the metric.", + "type": "number", + "readOnly": true + }, + "maximum": { + "format": "double", + "description": "The max value of the metric.", + "type": "number", + "readOnly": true + }, + "total": { + "format": "double", + "description": "The total value of the metric.", + "type": "number", + "readOnly": true + }, + "count": { + "format": "int32", + "description": "The number of values for the metric.", + "type": "integer", + "readOnly": true + } + } + }, + "ManagedInstanceListResult": { + "description": "A list of managed instances.", + "type": "object", + "properties": { + "value": { + "description": "Array of results.", + "type": "array", + "items": { + "$ref": "#/definitions/ManagedInstance" + }, + "readOnly": true + }, + "nextLink": { + "description": "Link to retrieve next page of results.", + "type": "string", + "readOnly": true + } + } + }, + "ManagedInstanceProperties": { + "description": "The properties of a managed instance.", + "type": "object", + "properties": { + "managedInstanceCreateMode": { + "description": "Specifies the mode of database creation.\r\n\r\nDefault: Regular instance creation.\r\n\r\nRestore: Creates an instance by restoring a set of backups to specific point in time. RestorePointInTime and SourceManagedInstanceId must be specified.", + "enum": [ + "Default", + "PointInTimeRestore" + ], + "type": "string", + "x-ms-enum": { + "name": "ManagedServerCreateMode", + "modelAsString": true + }, + "x-ms-mutability": [ + "create" + ] + }, + "fullyQualifiedDomainName": { + "description": "The fully qualified domain name of the managed instance.", + "type": "string", + "readOnly": true + }, + "administratorLogin": { + "description": "Administrator username for the managed instance. Can only be specified when the managed instance is being created (and is required for creation).", + "type": "string", + "x-ms-mutability": [ + "read", + "create" + ] + }, + "administratorLoginPassword": { + "description": "The administrator login password (required for managed instance creation).", + "type": "string", + "x-ms-mutability": [ + "create", + "update" + ] + }, + "subnetId": { + "description": "Subnet resource ID for the managed instance.", + "type": "string" + }, + "state": { + "description": "The state of the managed instance.", + "type": "string", + "readOnly": true + }, + "licenseType": { + "description": "The license type. Possible values are 'LicenseIncluded' (regular price inclusive of a new SQL license) and 'BasePrice' (discounted AHB price for bringing your own SQL licenses).", + "enum": [ + "LicenseIncluded", + "BasePrice" + ], + "type": "string", + "x-ms-enum": { + "name": "ManagedInstanceLicenseType", + "modelAsString": true + } + }, + "vCores": { + "format": "int32", + "description": "The number of vCores. Allowed values: 8, 16, 24, 32, 40, 64, 80.", + "type": "integer" + }, + "storageSizeInGB": { + "format": "int32", + "description": "Storage size in GB. Minimum value: 32. Maximum value: 8192. Increments of 32 GB allowed only.", + "type": "integer" + }, + "collation": { + "description": "Collation of the managed instance.", + "type": "string", + "x-ms-mutability": [ + "read", + "create" + ] + }, + "dnsZone": { + "description": "The Dns Zone that the managed instance is in.", + "type": "string", + "readOnly": true + }, + "dnsZonePartner": { + "description": "The resource id of another managed instance whose DNS zone this managed instance will share after creation.", + "type": "string", + "x-ms-mutability": [ + "create" + ] + }, + "publicDataEndpointEnabled": { + "description": "Whether or not the public data endpoint is enabled.", + "type": "boolean" + }, + "sourceManagedInstanceId": { + "description": "The resource identifier of the source managed instance associated with create operation of this instance.", + "type": "string", + "x-ms-mutability": [ + "create" + ] + }, + "restorePointInTime": { + "format": "date-time", + "description": "Specifies the point in time (ISO8601 format) of the source database that will be restored to create the new database.", + "type": "string", + "x-ms-mutability": [ + "create" + ] + }, + "proxyOverride": { + "description": "Connection type used for connecting to the instance.", + "enum": [ + "Proxy", + "Redirect", + "Default" + ], + "type": "string", + "x-ms-enum": { + "name": "ManagedInstanceProxyOverride", + "modelAsString": true + } + }, + "timezoneId": { + "description": "Id of the timezone. Allowed values are timezones supported by Windows.\r\nWindows keeps details on supported timezones, including the id, in registry under\r\nKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Time Zones.\r\nYou can get those registry values via SQL Server by querying SELECT name AS timezone_id FROM sys.time_zone_info.\r\nList of Ids can also be obtained by executing [System.TimeZoneInfo]::GetSystemTimeZones() in PowerShell.\r\nAn example of valid timezone id is \"Pacific Standard Time\" or \"W. Europe Standard Time\".", + "type": "string", + "x-ms-mutability": [ + "read", + "create" + ] + }, + "instancePoolId": { + "description": "The Id of the instance pool this managed server belongs to.", + "type": "string" + } + } + }, + "ManagedInstance": { + "description": "An Azure SQL managed instance.", + "required": [ + "location" + ], + "type": "object", + "allOf": [ + { + "$ref": "../../../common/v1/types.json#/definitions/TrackedResource" + } + ], + "properties": { + "identity": { + "$ref": "../../../common/v1/types.json#/definitions/ResourceIdentity", + "description": "The Azure Active Directory identity of the managed instance.", + "x-ms-mutability": [ + "read", + "create" + ] + }, + "sku": { + "$ref": "../../../common/v1/types.json#/definitions/Sku", + "description": "Managed instance SKU. Allowed values for sku.name: GP_Gen4, GP_Gen5, BC_Gen4, BC_Gen5" + }, + "properties": { + "$ref": "#/definitions/ManagedInstanceProperties", + "description": "Resource properties.", + "x-ms-client-flatten": true + } + } + }, + "ManagedInstanceUpdate": { + "description": "An update request for an Azure SQL Database managed instance.", + "type": "object", + "properties": { + "sku": { + "$ref": "../../../common/v1/types.json#/definitions/Sku", + "description": "Managed instance sku" + }, + "properties": { + "$ref": "#/definitions/ManagedInstanceProperties", + "description": "Resource properties.", + "x-ms-client-flatten": true + }, + "tags": { + "description": "Resource tags.", + "type": "object", + "additionalProperties": { + "type": "string" + } + } + } + } + }, + "parameters": { + "SubscriptionIdParameter": { + "name": "subscriptionId", + "in": "path", + "description": "The subscription ID that identifies an Azure subscription.", + "required": true, + "type": "string", + "x-ms-parameter-location": "client" + }, + "ApiVersionParameter": { + "name": "api-version", + "in": "query", + "description": "The API version to use for the request.", + "required": true, + "type": "string", + "x-ms-parameter-location": "client" + }, + "ResourceGroupParameter": { + "name": "resourceGroupName", + "in": "path", + "description": "The name of the resource group that contains the resource. You can obtain this value from the Azure Resource Manager API or the portal.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "ServerNameParameter": { + "name": "serverName", + "in": "path", + "description": "The name of the server.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "ManagedInstanceNameParameter": { + "name": "managedInstanceName", + "in": "path", + "description": "The name of the managed instance.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "DatabaseNameParameter": { + "name": "databaseName", + "in": "path", + "description": "The name of the database.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "BlobAuditingPolicyNameParameter": { + "name": "blobAuditingPolicyName", + "in": "path", + "description": "The name of the blob auditing policy.", + "required": true, + "type": "string", + "enum": [ + "default" + ], + "x-ms-parameter-location": "method" + }, + "SqlVirtualMachineInstanceNameParameter": { + "name": "sqlVirtualMachineInstanceName", + "in": "path", + "description": "The name of the SqlVirtualMachineInstance.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "SqlVirtualMachineContainerNameParameter": { + "name": "sqlVirtualMachineContainerName", + "in": "path", + "description": "The name of the SqlVirtualMachineContainer.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + }, + "VirtualClusterNameParameter": { + "name": "virtualClusterName", + "in": "path", + "description": "The name of the virtual cluster.", + "required": true, + "type": "string", + "x-ms-parameter-location": "method" + } + }, + "securityDefinitions": { + "azure_auth": { + "type": "oauth2", + "description": "Azure Active Directory OAuth2 Flow", + "flow": "implicit", + "authorizationUrl": "https://login.microsoftonline.com/common/oauth2/authorize", + "scopes": { + "user_impersonation": "impersonate your user account" + } + } + } +} From d5e20a19330cfbabd79c7ba225922ac2105629d5 Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Mon, 17 Jun 2019 16:26:19 -0700 Subject: [PATCH 03/11] Putting these back in 2018-06-01-preview --- ...ityAssessmentCreateContainerSasKeyMin.json | 47 ++++++++++++++++ ...tanceVulnerabilityAssessmentCreateMax.json | 53 +++++++++++++++++++ ...tyAssessmentCreateStorageAccessKeyMin.json | 47 ++++++++++++++++ ...InstanceVulnerabilityAssessmentDelete.json | 13 +++++ ...gedInstanceVulnerabilityAssessmentGet.json | 26 +++++++++ ...VulnerabilityAssessmentListByInstance.json | 29 ++++++++++ 6 files changed, 215 insertions(+) create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateContainerSasKeyMin.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateMax.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateStorageAccessKeyMin.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentDelete.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentGet.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentListByInstance.json diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateContainerSasKeyMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateContainerSasKeyMin.json new file mode 100644 index 000000000000..734446acb9f4 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateContainerSasKeyMin.json @@ -0,0 +1,47 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "vulnerabilityaseessmenttest-4799", + "managedInstanceName": "vulnerabilityaseessmenttest-6440", + "vulnerabilityAssessmentName": "default", + "api-version": "2018-06-01-preview", + "parameters": { + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "storageContainerSasKey": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" + } + } + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", + "name": "default", + "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "recurringScans": { + "isEnabled": true, + "emailSubscriptionAdmins": false, + "emails": [] + } + } + } + }, + "201": { + "body": { + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", + "name": "default", + "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "recurringScans": { + "isEnabled": true, + "emailSubscriptionAdmins": false, + "emails": [] + } + } + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateMax.json new file mode 100644 index 000000000000..dfafc5136e83 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateMax.json @@ -0,0 +1,53 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "vulnerabilityaseessmenttest-4799", + "managedInstanceName": "vulnerabilityaseessmenttest-6440", + "vulnerabilityAssessmentName": "default", + "api-version": "2018-06-01-preview", + "parameters": { + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "storageContainerSasKey": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX", + "storageAccountAccessKey": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX", + "recurringScans": { + "isEnabled": true, + "emailSubscriptionAdmins": true, + "emails": [ "email1@mail.com", "email2@mail.com" ] + } + } + } + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", + "name": "default", + "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "recurringScans": { + "isEnabled": true, + "emailSubscriptionAdmins": true, + "emails": [ "email1@mail.com", "email2@mail.com" ] + } + } + } + }, + "201": { + "body": { + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", + "name": "default", + "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "recurringScans": { + "isEnabled": true, + "emailSubscriptionAdmins": true, + "emails": [ "email1@mail.com", "email2@mail.com" ] + } + } + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateStorageAccessKeyMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateStorageAccessKeyMin.json new file mode 100644 index 000000000000..9f9bf693499c --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentCreateStorageAccessKeyMin.json @@ -0,0 +1,47 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "vulnerabilityaseessmenttest-4799", + "managedInstanceName": "vulnerabilityaseessmenttest-6440", + "vulnerabilityAssessmentName": "default", + "api-version": "2018-06-01-preview", + "parameters": { + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "storageAccountAccessKey": "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" + } + } + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", + "name": "default", + "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "recurringScans": { + "isEnabled": true, + "emailSubscriptionAdmins": false, + "emails": [] + } + } + } + }, + "201": { + "body": { + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", + "name": "default", + "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "recurringScans": { + "isEnabled": true, + "emailSubscriptionAdmins": false, + "emails": [] + } + } + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentDelete.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentDelete.json new file mode 100644 index 000000000000..cea35165541e --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentDelete.json @@ -0,0 +1,13 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "vulnerabilityaseessmenttest-4799", + "managedInstanceName": "vulnerabilityaseessmenttest-6440", + "vulnerabilityAssessmentName": "default", + "api-version": "2018-06-01-preview" + }, + "responses": { + "200": { + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentGet.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentGet.json new file mode 100644 index 000000000000..f422631ceb9a --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentGet.json @@ -0,0 +1,26 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "vulnerabilityaseessmenttest-4799", + "managedInstanceName": "vulnerabilityaseessmenttest-6440", + "vulnerabilityAssessmentName": "default", + "api-version": "2018-06-01-preview" + }, + "responses": { + "200": { + "body": { + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", + "name": "default", + "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "recurringScans": { + "isEnabled": true, + "emailSubscriptionAdmins": true, + "emails": [ "email1@mail.com", "email2@mail.com" ] + } + } + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentListByInstance.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentListByInstance.json new file mode 100644 index 000000000000..1a3462f5a36a --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceVulnerabilityAssessmentListByInstance.json @@ -0,0 +1,29 @@ +{ + "parameters": { + "subscriptionId": "00000000-1111-2222-3333-444444444444", + "resourceGroupName": "vulnerabilityaseessmenttest-4799", + "managedInstanceName": "vulnerabilityaseessmenttest-6440", + "api-version": "2018-06-01-preview" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "id": "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/vulnerabilityaseessmenttest-4799/providers/Microsoft.Sql/managedInstances/vulnerabilityaseessmenttest-6440/vulnerabilityAssessments/default", + "name": "default", + "type": "Microsoft.Sql/managedInstances/vulnerabilityAssessments", + "properties": { + "storageContainerPath": "https://myStorage.blob.core.windows.net/vulnerability-assessment/", + "recurringScans": { + "isEnabled": true, + "emailSubscriptionAdmins": true, + "emails": [ "email1@mail.com", "email2@mail.com" ] + } + } + } + ] + } + } + } +} \ No newline at end of file From 3d1adff1b1c1c1691496b7633a4176356d1738e0 Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Mon, 17 Jun 2019 16:45:49 -0700 Subject: [PATCH 04/11] Update readme.md to have 2018-06-01-preview managedInstances json file --- specification/sql/resource-manager/readme.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/specification/sql/resource-manager/readme.md b/specification/sql/resource-manager/readme.md index 2392da3460ac..dc8b2f8389a0 100644 --- a/specification/sql/resource-manager/readme.md +++ b/specification/sql/resource-manager/readme.md @@ -120,6 +120,7 @@ input-file: - Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json - Microsoft.Sql/preview/2018-06-01-preview/instancePools.json - Microsoft.Sql/preview/2018-06-01-preview/usages.json +- Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json # Needed when there is more than one input file @@ -211,6 +212,7 @@ input-file: - Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json - Microsoft.Sql/preview/2018-06-01-preview/instancePools.json - Microsoft.Sql/preview/2018-06-01-preview/usages.json +- Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json # Needed when there is more than one input file override-info: @@ -295,6 +297,7 @@ input-file: - Microsoft.Sql/preview/2018-06-01-preview/managedDatabaseSensitivityLabels.json - Microsoft.Sql/preview/2018-06-01-preview/instancePools.json - Microsoft.Sql/preview/2018-06-01-preview/usages.json +- Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json # Needed when there is more than one input file override-info: @@ -460,6 +463,7 @@ input-file: - ./Microsoft.Sql/preview/2018-06-01-preview/ServerVulnerabilityAssessments.json - ./Microsoft.Sql/preview/2018-06-01-preview/instancePools.json - ./Microsoft.Sql/preview/2018-06-01-preview/usages.json + - ./Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json # Needed when there is more than one input file override-info: From 0f3fc6dcc876350b772177e59d9d9ced07c61b20 Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Mon, 17 Jun 2019 17:51:48 -0700 Subject: [PATCH 05/11] Update example api versions to 2018-06-01-preview --- .../2018-06-01-preview/examples/ManagedInstanceCreateMax.json | 2 +- .../2018-06-01-preview/examples/ManagedInstanceCreateMin.json | 4 ++-- .../2018-06-01-preview/examples/ManagedInstanceDelete.json | 4 ++-- .../2018-06-01-preview/examples/ManagedInstanceGet.json | 4 ++-- .../2018-06-01-preview/examples/ManagedInstanceList.json | 4 ++-- .../examples/ManagedInstanceListByInstancePool.json | 4 ++-- .../examples/ManagedInstanceListByResourceGroup.json | 4 ++-- .../2018-06-01-preview/examples/ManagedInstanceUpdateMax.json | 2 +- .../2018-06-01-preview/examples/ManagedInstanceUpdateMin.json | 4 ++-- .../examples/ManagedInstancesListMetricDefinitions.json | 4 ++-- .../examples/ManagedInstancesListMetrics.json | 4 ++-- 11 files changed, 20 insertions(+), 20 deletions(-) diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json index 45ba619264f4..ebc90b3fe214 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json @@ -3,7 +3,7 @@ "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", "resourceGroupName" : "testrg", "managedInstanceName" : "testinstance", - "api-version" : "2015-05-01-preview", + "api-version" : "2018-06-01-preview", "parameters" : { "tags" : { "tagKey1" : "TagValue1" diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json index 02d525123917..fdad41d792e2 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json @@ -3,7 +3,7 @@ "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", "resourceGroupName": "testrg", "managedInstanceName": "testinstance", - "api-version": "2015-05-01-preview", + "api-version": "2018-06-01-preview", "parameters": { "sku": { "name": "GP_Gen4", @@ -83,4 +83,4 @@ }, "202": {} } -} \ No newline at end of file +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json index 1b1db6fb5f6a..5c201e79220d 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json @@ -3,7 +3,7 @@ "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", "resourceGroupName" : "testrg", "managedInstanceName" : "testinstance", - "api-version" : "2015-05-01-preview" + "api-version" : "2018-06-01-preview" }, "responses" : { "200" : { @@ -14,4 +14,4 @@ "body" : "" } } -} \ No newline at end of file +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json index 6951eb9f6334..7f297064d6ec 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json @@ -3,7 +3,7 @@ "subscriptionId" : "20d7082a-0fc7-4468-82bd-542694d5042b", "resourceGroupName" : "testrg", "managedInstanceName" : "testinstance", - "api-version" : "2015-05-01-preview" + "api-version" : "2018-06-01-preview" }, "responses" : { "200" : { @@ -38,4 +38,4 @@ } } } -} \ No newline at end of file +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json index d34540b24f5b..529b6fdd1c81 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json @@ -1,7 +1,7 @@ { "parameters" : { "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", - "api-version" : "2015-05-01-preview" + "api-version" : "2018-06-01-preview" }, "responses" : { "200" : { @@ -61,4 +61,4 @@ } } } -} \ No newline at end of file +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByInstancePool.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByInstancePool.json index 078955c03c4c..313ef50fc116 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByInstancePool.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByInstancePool.json @@ -3,7 +3,7 @@ "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", "resourceGroupName": "Test1", "instancePoolName": "pool1", - "api-version": "2015-05-01-preview" + "api-version": "2018-06-01-preview" }, "responses": { "200": { @@ -65,4 +65,4 @@ } } } -} \ No newline at end of file +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json index 57fc3c367920..7ef8a934da16 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json @@ -2,7 +2,7 @@ "parameters": { "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", "resourceGroupName": "Test1", - "api-version": "2015-05-01-preview" + "api-version": "2018-06-01-preview" }, "responses": { "200": { @@ -62,4 +62,4 @@ } } } -} \ No newline at end of file +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json index 672c99ee76bd..a9f060756e1c 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json @@ -3,7 +3,7 @@ "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", "resourceGroupName" : "testrg", "managedInstanceName" : "testinstance", - "api-version" : "2015-05-01-preview", + "api-version" : "2018-06-01-preview", "parameters" : { "tags" : { "tagKey1" : "TagValue1" diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json index 4a9a2b3da5ec..3e8be01f972a 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json @@ -3,7 +3,7 @@ "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", "resourceGroupName" : "testrg", "managedInstanceName" : "testinstance", - "api-version": "2015-05-01-preview", + "api-version": "2018-06-01-preview", "parameters": { "tags": { "tagKey1": "TagValue1" @@ -44,4 +44,4 @@ }, "202": {} } -} \ No newline at end of file +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json index a08bc1535212..d840d0ac3028 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json @@ -3,7 +3,7 @@ "subscriptionId":"00000000-1111-2222-3333-444444444444", "resourceGroupName":"Test1", "managedInstanceName":"managedInstance", - "api-version":"2017-10-01-preview" + "api-version":"2018-06-01-preview" }, "responses":{ "200":{ @@ -129,4 +129,4 @@ } } } - } \ No newline at end of file + } diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json index 8ec4dbff4d00..c383a02b9afc 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json @@ -7,7 +7,7 @@ "timespan":"2018-03-01T00:00:00Z/2018-03-03T18:00:00Z", "aggregation":"average", "interval":"PT5M", - "api-version":"2017-10-01-preview" + "api-version":"2018-06-01-preview" }, "responses":{ "200":{ @@ -145,4 +145,4 @@ } } } - } \ No newline at end of file + } From 96d5add4cd1a898c28c6cc3fb9cb81425a31d7b1 Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Mon, 17 Jun 2019 18:11:52 -0700 Subject: [PATCH 06/11] Filter to managed instance list by instance pool --- .../examples/ManagedInstanceCreateMax.json | 99 --- .../examples/ManagedInstanceCreateMin.json | 86 --- .../examples/ManagedInstanceDelete.json | 17 - .../examples/ManagedInstanceGet.json | 41 -- .../examples/ManagedInstanceList.json | 64 -- .../ManagedInstanceListByResourceGroup.json | 65 -- .../examples/ManagedInstanceUpdateMax.json | 62 -- .../examples/ManagedInstanceUpdateMin.json | 47 -- ...ManagedInstancesListMetricDefinitions.json | 132 ---- .../examples/ManagedInstancesListMetrics.json | 148 ---- .../2018-06-01-preview/managedInstances.json | 669 ------------------ 11 files changed, 1430 deletions(-) delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json deleted file mode 100644 index ebc90b3fe214..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json +++ /dev/null @@ -1,99 +0,0 @@ -{ - "parameters" : { - "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", - "resourceGroupName" : "testrg", - "managedInstanceName" : "testinstance", - "api-version" : "2018-06-01-preview", - "parameters" : { - "tags" : { - "tagKey1" : "TagValue1" - }, - "location" : "Japan East", - "sku" : { - "name" : "GP_Gen5", - "tier" : "GeneralPurpose" - }, - "properties": { - "administratorLogin": "dummylogin", - "administratorLoginPassword": "Un53cuRE!", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "vCores": 8, - "storageSizeInGB": 1024, - "licenseType": "LicenseIncluded", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "dnsZonePartner": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", - "publicDataEndpointEnabled": false, - "proxyOverride": "Redirect", - "timezoneId": "UTC", - "instancePoolId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1" - } - } - }, - "responses" : { - "200": { - "body": { - "sku": { - "name": "GP_Gen5", - "tier": "GeneralPurpose", - "capacity": 8, - "family": "Gen5" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "state": "Ready", - "vCores": 8, - "storageSizeInGB": 1024, - "licenseType": "LicenseIncluded", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Redirect", - "dnsZone": "1b4e2caff2530", - "timezoneId": "UTC", - "instancePoolId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1" - }, - "location": "japaneast", - "tags": { - "tagKey1": "TagValue1" - }, - "id": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", - "name": "testinstance", - "type": "Microsoft.Sql/managedInstances" - } - }, - "201" : { - "body": { - "sku": { - "name": "GP_Gen5", - "tier": "GeneralPurpose", - "capacity": 8, - "family": "Gen5" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "state": "Ready", - "vCores": 8, - "storageSizeInGB": 1024, - "licenseType": "LicenseIncluded", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Redirect", - "dnsZone": "1b4e2caff2530", - "timezoneId": "UTC", - "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1" - }, - "location": "japaneast", - "tags": { - "tagKey1": "TagValue1" - }, - "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", - "name": "testinstance", - "type": "Microsoft.Sql/managedInstances" - } - }, - "202" : {} - } -} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json deleted file mode 100644 index fdad41d792e2..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json +++ /dev/null @@ -1,86 +0,0 @@ -{ - "parameters": { - "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", - "resourceGroupName": "testrg", - "managedInstanceName": "testinstance", - "api-version": "2018-06-01-preview", - "parameters": { - "sku": { - "name": "GP_Gen4", - "tier": "GeneralPurpose" - }, - "properties": { - "administratorLogin": "dummylogin", - "administratorLoginPassword": "Un53cuRE!", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "vCores": 8, - "storageSizeInGB": 1024, - "licenseType": "LicenseIncluded" - }, - "location": "Japan East" - } - }, - "responses": { - "200": { - "body": { - "sku": { - "name": "GP_Gen4", - "tier": "GeneralPurpose", - "capacity": 8, - "family": "Gen4" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "state": "Ready", - "vCores": 8, - "storageSizeInGB": 1024, - "licenseType": "LicenseIncluded", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Default", - "dnsZone": "1b4e2caff2530" - }, - "location": "japaneast", - "tags": { - - }, - "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", - "name": "testinstance", - "type": "Microsoft.Sql/managedInstances" - } - }, - "201": { - "body": { - "sku": { - "name": "GP_Gen4", - "tier": "GeneralPurpose", - "capacity": 8, - "family": "Gen4" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "state": "Ready", - "vCores": 8, - "storageSizeInGB": 1024, - "licenseType": "LicenseIncluded", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Redirect", - "dnsZone": "1b4e2caff2530" - }, - "location": "japaneast", - "tags": { - - }, - "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", - "name": "testinstance", - "type": "Microsoft.Sql/managedInstances" - } - }, - "202": {} - } -} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json deleted file mode 100644 index 5c201e79220d..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "parameters" : { - "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", - "resourceGroupName" : "testrg", - "managedInstanceName" : "testinstance", - "api-version" : "2018-06-01-preview" - }, - "responses" : { - "200" : { - "body" : "" - }, - "202" : {}, - "204" : { - "body" : "" - } - } -} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json deleted file mode 100644 index 7f297064d6ec..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "parameters" : { - "subscriptionId" : "20d7082a-0fc7-4468-82bd-542694d5042b", - "resourceGroupName" : "testrg", - "managedInstanceName" : "testinstance", - "api-version" : "2018-06-01-preview" - }, - "responses" : { - "200" : { - "body": { - "sku": { - "name": "GP_Gen4", - "tier": "GeneralPurpose", - "capacity": 8, - "family": "Gen4" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "state": "Ready", - "vCores": 8, - "storageSizeInGB": 1024, - "licenseType": "LicenseIncluded", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Default", - "dnsZone": "1b4e2caff2530", - "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1" - }, - "location": "japaneast", - "tags": { - "key": "value" - }, - "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", - "name": "testinstance", - "type": "Microsoft.Sql/managedInstances" - } - } - } -} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json deleted file mode 100644 index 529b6fdd1c81..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json +++ /dev/null @@ -1,64 +0,0 @@ -{ - "parameters" : { - "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", - "api-version" : "2018-06-01-preview" - }, - "responses" : { - "200" : { - "body" : { - "value": [ - { - "location": "japaneast", - "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance1", - "name": "testinstance1", - "type": "Microsoft.Sql/managedInstances", - "sku": { - "name": "GP_Gen4", - "tier": "GeneralPurpose", - "capacity": 8, - "family": "Gen4" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance1.1b4e2caff2530.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "state": "Ready", - "vCores": 8, - "storageSizeInGB": 1024, - "licenseType": "LicenseIncluded", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Default", - "dnsZone": "1b4e2caff2530" - } - }, - { - "location": "japaneast", - "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance2", - "name": "testinstance2", - "type": "Microsoft.Sql/managedInstances", - "sku": { - "name": "BC_Gen5", - "tier": "BusinessCritical", - "capacity": 16, - "family": "Gen4" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance2.2c3d1bdae3412.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet2/subnets/subnet2", - "state": "Ready", - "vCores": 16, - "storageSizeInGB": 1024, - "licenseType": "Full", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Default", - "dnsZone": "2c3d1bdae3412" - } - } - ] - } - } - } -} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json deleted file mode 100644 index 7ef8a934da16..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json +++ /dev/null @@ -1,65 +0,0 @@ -{ - "parameters": { - "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", - "resourceGroupName": "Test1", - "api-version": "2018-06-01-preview" - }, - "responses": { - "200": { - "body": { - "value": [ - { - "location": "japaneast", - "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance1", - "name": "testinstance1", - "type": "Microsoft.Sql/managedInstances", - "sku": { - "name": "GP_Gen4", - "tier": "GeneralPurpose", - "capacity": 8, - "family": "Gen4" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance1.1b4e2caff2530.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "state": "Ready", - "vCores": 8, - "storageSizeInGB": 1024, - "licenseType": "LicenseIncluded", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Default", - "dnsZone": "1b4e2caff2530" - } - }, - { - "location": "japaneast", - "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance2", - "name": "testinstance2", - "type": "Microsoft.Sql/managedInstances", - "sku": { - "name": "BC_Gen5", - "tier": "BusinessCritical", - "capacity": 16, - "family": "Gen4" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance2.2c3d1bdae3412.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet2/subnets/subnet2", - "state": "Ready", - "vCores": 16, - "storageSizeInGB": 1024, - "licenseType": "Full", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Default", - "dnsZone": "2c3d1bdae3412" - } - } - ] - } - } - } -} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json deleted file mode 100644 index a9f060756e1c..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json +++ /dev/null @@ -1,62 +0,0 @@ -{ - "parameters" : { - "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", - "resourceGroupName" : "testrg", - "managedInstanceName" : "testinstance", - "api-version" : "2018-06-01-preview", - "parameters" : { - "tags" : { - "tagKey1" : "TagValue1" - }, - "sku" : { - "name" : "GP_Gen4", - "tier" : "GeneralPurpose", - "capacity" : 8 - }, - "properties": { - "administratorLogin": "dummylogin", - "administratorLoginPassword": "Un53cuRE!", - "proxyOverride": "Redirect", - "publicDataEndpointEnabled": false, - "licenseType": "BasePrice", - "vCores": 8, - "storageSizeInGB": 448, - "collation": "SQL_Latin1_General_CP1_CI_AS" - } - } - }, - "responses" : { - "200" : { - "body": { - "tags": { - "tagKey1": "TagValue1" - }, - "id": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", - "name": "testinstance", - "type": "Microsoft.Sql/managedInstances", - "location": "japaneast", - "sku": { - "name": "GP_Gen4", - "tier": "GeneralPurpose", - "capacity": 8, - "family": "Gen4" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "state": "Ready", - "vCores": 8, - "storageSizeInGB": 448, - "licenseType": "BasePrice", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Redirect", - "dnsZone": "1b4e2caff2530", - "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1" - } - } - }, - "202" : {} - } -} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json deleted file mode 100644 index 3e8be01f972a..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json +++ /dev/null @@ -1,47 +0,0 @@ -{ - "parameters": { - "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", - "resourceGroupName" : "testrg", - "managedInstanceName" : "testinstance", - "api-version": "2018-06-01-preview", - "parameters": { - "tags": { - "tagKey1": "TagValue1" - } - } - }, - "responses": { - "200": { - "body": { - "sku": { - "name": "GP_Gen4", - "tier": "GeneralPurpose", - "capacity": 8, - "family": "Gen4" - }, - "properties": { - "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", - "administratorLogin": "dummylogin", - "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", - "state": "Ready", - "vCores": 8, - "storageSizeInGB": 1024, - "licenseType": "LicenseIncluded", - "collation": "SQL_Latin1_General_CP1_CI_AS", - "publicDataEndpointEnabled": false, - "proxyOverride": "Default", - "dnsZone": "1b4e2caff2530", - "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1" - }, - "location": "japaneast", - "tags": { - "tagKey1": "TagValue1" - }, - "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", - "name": "testinstance", - "type": "Microsoft.Sql/managedInstances" - } - }, - "202": {} - } -} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json deleted file mode 100644 index d840d0ac3028..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json +++ /dev/null @@ -1,132 +0,0 @@ -{ - "parameters":{ - "subscriptionId":"00000000-1111-2222-3333-444444444444", - "resourceGroupName":"Test1", - "managedInstanceName":"managedInstance", - "api-version":"2018-06-01-preview" - }, - "responses":{ - "200":{ - "body":{ - "value":[ - { - "name":{ - "value":"reserved_storage_mb", - "localizedValue":"Storage space reserved" - }, - "unit":"Bytes", - "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", - "primaryAggregationType":"Average", - "supportedAggregationTypes":[ - "Average", - "Minimum", - "Maximum", - "Count" - ], - "metricAvailabilities":[ - { - "timeGrain":"PT5M", - "retention":"P14D" - }, - { - "timeGrain":"PT1H", - "retention":"P14D" - }, - { - "timeGrain":"P1D", - "retention":"P14D" - } - ] - }, - { - "name":{ - "value":"storage_space_used_mb", - "localizedValue":"Storage space used" - }, - "unit":"Bytes", - "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", - "primaryAggregationType":"Average", - "supportedAggregationTypes":[ - "Average", - "Minimum", - "Maximum", - "Count" - ], - "metricAvailabilities":[ - { - "timeGrain":"PT5M", - "retention":"P14D" - }, - { - "timeGrain":"PT1H", - "retention":"P14D" - }, - { - "timeGrain":"P1D", - "retention":"P14D" - } - ] - }, - { - "name":{ - "value":"avg_cpu_percent", - "localizedValue":"Average CPU percentage" - }, - "unit":"Percent", - "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", - "primaryAggregationType":"Average", - "supportedAggregationTypes":[ - "Average", - "Minimum", - "Maximum", - "Count" - ], - "metricAvailabilities":[ - { - "timeGrain":"PT5M", - "retention":"P14D" - }, - { - "timeGrain":"PT1H", - "retention":"P14D" - }, - { - "timeGrain":"P1D", - "retention":"P14D" - } - ] - }, - { - "name":{ - "value":"virtual_core_count", - "localizedValue":"Virtual core count" - }, - "unit":"Count", - "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", - "primaryAggregationType":"Average", - "supportedAggregationTypes":[ - "Average", - "Minimum", - "Maximum", - "Count" - ], - "metricAvailabilities":[ - { - "timeGrain":"PT5M", - "retention":"P14D" - }, - { - "timeGrain":"PT1H", - "retention":"P14D" - }, - { - "timeGrain":"P1D", - "retention":"P14D" - } - ] - } - ] - } - } - } - } diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json deleted file mode 100644 index c383a02b9afc..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json +++ /dev/null @@ -1,148 +0,0 @@ -{ - "parameters":{ - "subscriptionId":"00000000-1111-2222-3333-444444444444", - "resourceGroupName":"Test1", - "managedInstanceName":"managedInstance", - "metric":"avg_cpu_percent", - "timespan":"2018-03-01T00:00:00Z/2018-03-03T18:00:00Z", - "aggregation":"average", - "interval":"PT5M", - "api-version":"2018-06-01-preview" - }, - "responses":{ - "200":{ - "body":{ - "value":[ - { - "name":{ - "value":"avg_cpu_percent", - "localizedValue":"Average CPU percentage" - }, - "unit":"Percent", - "timeGrain":"PT5M", - "startTime":"3/1/2018 1:00:00 AM", - "endTime":"3/3/2018 7:00:00 PM", - "timeseries":[ - { - "data":[ - { - "timeStamp":"2018-03-02T13:30:01Z", - "average":1.881666, - "minimum":0.13, - "maximum":7.06, - "count":12 - }, - { - "timeStamp":"2018-03-02T13:35:01Z", - "average":0.8755, - "minimum":0.12, - "maximum":4.22, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:40:01Z", - "average":0.4665, - "minimum":0.14, - "maximum":2.31, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:45:01Z", - "average":0.3545, - "minimum":0.13, - "maximum":1.72, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:50:01Z", - "average":0.3505, - "minimum":0.13, - "maximum":1.38, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:55:01Z", - "average":0.3535, - "minimum":0.13, - "maximum":1.39, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:00:01Z", - "average":0.418, - "minimum":0.13, - "maximum":1.54, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:05:01Z", - "average":0.35, - "minimum":0.15, - "maximum":1.44, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:10:01Z", - "average":0.3525, - "minimum":0.14, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:15:01Z", - "average":0.352, - "minimum":0.15, - "maximum":1.56, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:20:01Z", - "average":0.3495, - "minimum":0.16, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:25:01Z", - "average":0.368, - "minimum":0.15, - "maximum":1.31, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:30:01Z", - "average":0.438, - "minimum":0.15, - "maximum":2.69, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:35:01Z", - "average":0.3895, - "minimum":0.16, - "maximum":1.29, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:40:01Z", - "average":0.3515, - "minimum":0.12, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:45:01Z", - "average":0.405263, - "minimum":0.12, - "maximum":2.17, - "count":19 - } - ] - } - ] - } - ] - } - } - } - } diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json index 74174755d34f..f90dfd59b7e5 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json @@ -16,118 +16,6 @@ "application/json" ], "paths": { - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/metricDefinitions": { - "get": { - "tags": [ - "ManagedInstances" - ], - "description": "Gets a list of managed instance metric definitions.", - "operationId": "ManagedInstances_ListMetricDefinitions", - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupParameter" - }, - { - "$ref": "#/parameters/ManagedInstanceNameParameter" - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully retrieved the list of metric definitions for managed instance.", - "schema": { - "$ref": "#/definitions/MetricDefinitionListResult" - } - }, - "default": { - "description": "*** Error Responses: ***\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 404 ServerNotFound - The requested server was not found.\n\n * 405 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "List metric definitions by managed instance": { - "$ref": "./examples/ManagedInstancesListMetricDefinitions.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/metrics": { - "get": { - "tags": [ - "ManagedInstances" - ], - "description": "Gets a list of managed instance metrics.", - "operationId": "ManagedInstances_ListMetrics", - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupParameter" - }, - { - "$ref": "#/parameters/ManagedInstanceNameParameter" - }, - { - "name": "metric", - "in": "query", - "description": "Name of the metrics to get.", - "required": false, - "type": "string" - }, - { - "name": "timespan", - "in": "query", - "description": "The timespan for the metric.", - "required": false, - "type": "string" - }, - { - "name": "aggregation", - "in": "query", - "description": "The aggregation type to use.", - "required": false, - "type": "string" - }, - { - "name": "interval", - "in": "query", - "description": "The time step to be used to summarize the metric values.", - "required": false, - "type": "string" - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully retrieved the list of databases.", - "schema": { - "$ref": "#/definitions/MetricListResult" - } - }, - "default": { - "description": "*** Error Responses: ***\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 404 ServerNotFound - The requested server was not found.\n\n * 405 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "List metrics by managed instance": { - "$ref": "./examples/ManagedInstancesListMetrics.json" - } - } - } - }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/instancePools/{instancePoolName}/managedInstances": { "get": { "tags": [ @@ -173,544 +61,9 @@ } } } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances": { - "get": { - "tags": [ - "ManagedInstances" - ], - "description": "Gets a list of managed instances in a resource group.", - "operationId": "ManagedInstances_ListByResourceGroup", - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupParameter" - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully retrieved the list of managed instances.", - "schema": { - "$ref": "#/definitions/ManagedInstanceListResult" - } - }, - "default": { - "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "List managed instances by resource group": { - "$ref": "./examples/ManagedInstanceListByResourceGroup.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}": { - "get": { - "tags": [ - "ManagedInstances" - ], - "description": "Gets a managed instance.", - "operationId": "ManagedInstances_Get", - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupParameter" - }, - { - "$ref": "#/parameters/ManagedInstanceNameParameter" - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully retrieved the specified managed instance.", - "schema": { - "$ref": "#/definitions/ManagedInstance" - } - }, - "default": { - "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." - } - }, - "x-ms-examples": { - "Get managed instance": { - "$ref": "./examples/ManagedInstanceGet.json" - } - } - }, - "put": { - "tags": [ - "ManagedInstances" - ], - "description": "Creates or updates a managed instance.", - "operationId": "ManagedInstances_CreateOrUpdate", - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupParameter" - }, - { - "$ref": "#/parameters/ManagedInstanceNameParameter" - }, - { - "name": "parameters", - "in": "body", - "description": "The requested managed instance resource state.", - "required": true, - "schema": { - "$ref": "#/definitions/ManagedInstance" - } - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully updated the managed instance.", - "schema": { - "$ref": "#/definitions/ManagedInstance" - } - }, - "default": { - "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.\n\n * 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.\n\n * 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.\n\n * 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.\n\n * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet\n\n * 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.\n\n * 400 SubnetHasResourcesOfDifferentType - User tried to create MI in subnet that has resources of different type.\n\n * 400 InvalidUsername - Supplied user name contains invalid characters.\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity\n\n * 400 ServerNotFound - The requested server was not found.\n\n * 400 TokenTooLong - The provided token is too long.\n\n * 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.\n\n * 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.\n\n * 400 InvalidLoginName - The provided login name is invalid.\n\n * 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.\n\n * 400 PasswordTooShort - The provided password is too short\n\n * 400 PasswordTooLong - The provided password is too long.\n\n * 400 PasswordNotComplex - The provided password is not complex enough.\n\n * 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.\n\n * 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 InvalidLocation - An invalid location was specified.\n\n * 400 VnetInWrongRegion - Virtual network is in wrong region.\n\n * 400 InvalidServerName - Invalid server name specified.\n\n * 400 VnetAddressRangeError - Virtual network address range is invalid.\n\n * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.\n\n * 400 InvalidCollation - Invalid collation.\n\n * 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.\n\n * 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.\n\n * 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.\n\n * 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.\n\n * 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.\n\n * 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.\n\n * 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.\n\n * 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.\n\n * 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.\n\n * 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.\n\n * 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.\n\n * 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.\n\n * 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.\n\n * 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.\n\n * 400 NameAlreadyExists - The provided name already exists.\n\n * 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.\n\n * 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes\n\n * 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.\n\n * 400 ManagedInstanceUpdateSloInProgress - \"The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again.\"\n\n * 400 VnetResourceNotFound - Resource not found: '{0}'.\n\n * 400 InvalidTimezone - Invalid timezone.\n\n * 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.\n\n * 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.\n\n * 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.\n\n * 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.\n\n * 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.\n\n * 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.\n\n * 400 InvalidManagedServerDnsZonePartner - Invalid DNS zone partner resource id specified in properties.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.\n\n * 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.\n\n * 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.\n\n * 405 InvalidStorageSizeValue - \"Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 409 ConflictingServerOperation - An operation is currently in progress for the server.\n\n * 409 SubscriptionDisabled - Subscription is disabled.\n\n * 409 ServerAlreadyExists - Duplicate server name.\n\n * 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.\n\n * 409 ServerDisabled - Server is disabled.\n\n * 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.\n\n * 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 500 GatewayInternalServerError - The server encountered an unexpected exception.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." - }, - "202": { - "description": "Accepted" - }, - "201": { - "description": "Successfully created the managed instance.", - "schema": { - "$ref": "#/definitions/ManagedInstance" - } - } - }, - "x-ms-long-running-operation": true, - "x-ms-examples": { - "Create managed instance with minimal properties": { - "$ref": "./examples/ManagedInstanceCreateMin.json" - }, - "Create managed instance with all properties": { - "$ref": "./examples/ManagedInstanceCreateMax.json" - } - } - }, - "delete": { - "tags": [ - "ManagedInstances" - ], - "description": "Deletes a managed instance.", - "operationId": "ManagedInstances_Delete", - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupParameter" - }, - { - "$ref": "#/parameters/ManagedInstanceNameParameter" - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully deleted the managed instance." - }, - "default": { - "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." - }, - "202": { - "description": "Accepted" - }, - "204": { - "description": "The specified managed instance does not exist." - } - }, - "x-ms-long-running-operation": true, - "x-ms-examples": { - "Delete managed instance": { - "$ref": "./examples/ManagedInstanceDelete.json" - } - } - }, - "patch": { - "tags": [ - "ManagedInstances" - ], - "description": "Updates a managed instance.", - "operationId": "ManagedInstances_Update", - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupParameter" - }, - { - "$ref": "#/parameters/ManagedInstanceNameParameter" - }, - { - "name": "parameters", - "in": "body", - "description": "The requested managed instance resource state.", - "required": true, - "schema": { - "$ref": "#/definitions/ManagedInstanceUpdate" - } - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully updated the managed instance.", - "schema": { - "$ref": "#/definitions/ManagedInstance" - } - }, - "default": { - "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.\n\n * 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.\n\n * 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.\n\n * 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.\n\n * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet\n\n * 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.\n\n * 400 SubnetHasResourcesOfDifferentType - User tried to create MI in subnet that has resources of different type.\n\n * 400 InvalidUsername - Supplied user name contains invalid characters.\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity\n\n * 400 ServerNotFound - The requested server was not found.\n\n * 400 TokenTooLong - The provided token is too long.\n\n * 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.\n\n * 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.\n\n * 400 InvalidLoginName - The provided login name is invalid.\n\n * 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.\n\n * 400 PasswordTooShort - The provided password is too short\n\n * 400 PasswordTooLong - The provided password is too long.\n\n * 400 PasswordNotComplex - The provided password is not complex enough.\n\n * 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.\n\n * 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 InvalidLocation - An invalid location was specified.\n\n * 400 VnetInWrongRegion - Virtual network is in wrong region.\n\n * 400 InvalidServerName - Invalid server name specified.\n\n * 400 VnetAddressRangeError - Virtual network address range is invalid.\n\n * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.\n\n * 400 InvalidCollation - Invalid collation.\n\n * 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.\n\n * 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.\n\n * 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.\n\n * 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.\n\n * 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.\n\n * 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.\n\n * 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.\n\n * 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.\n\n * 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.\n\n * 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.\n\n * 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.\n\n * 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.\n\n * 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.\n\n * 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.\n\n * 400 NameAlreadyExists - The provided name already exists.\n\n * 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.\n\n * 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes\n\n * 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.\n\n * 400 ManagedInstanceUpdateSloInProgress - \"The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again.\"\n\n * 400 VnetResourceNotFound - Resource not found: '{0}'.\n\n * 400 InvalidTimezone - Invalid timezone.\n\n * 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.\n\n * 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.\n\n * 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.\n\n * 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.\n\n * 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.\n\n * 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.\n\n * 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.\n\n * 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.\n\n * 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.\n\n * 405 InvalidStorageSizeValue - \"Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 409 ConflictingServerOperation - An operation is currently in progress for the server.\n\n * 409 SubscriptionDisabled - Subscription is disabled.\n\n * 409 ServerAlreadyExists - Duplicate server name.\n\n * 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.\n\n * 409 ServerDisabled - Server is disabled.\n\n * 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.\n\n * 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 500 GatewayInternalServerError - The server encountered an unexpected exception.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." - }, - "202": { - "description": "Accepted" - } - }, - "x-ms-long-running-operation": true, - "x-ms-examples": { - "Update managed instance with minimal properties": { - "$ref": "./examples/ManagedInstanceUpdateMin.json" - }, - "Update managed instance with all properties": { - "$ref": "./examples/ManagedInstanceUpdateMax.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/providers/Microsoft.Sql/managedInstances": { - "get": { - "tags": [ - "ManagedInstances" - ], - "description": "Gets a list of all managed instances in the subscription.", - "operationId": "ManagedInstances_List", - "parameters": [ - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully retrieved the list of managed instances.", - "schema": { - "$ref": "#/definitions/ManagedInstanceListResult" - } - }, - "default": { - "description": "*** Error Responses: ***" - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "List managed instances": { - "$ref": "./examples/ManagedInstanceList.json" - } - } - } } }, "definitions": { - "MetricDefinitionListResult": { - "description": "A list of metric definition resources.", - "type": "object", - "properties": { - "value": { - "description": "Array of results.", - "type": "array", - "items": { - "$ref": "#/definitions/MetricDefinition" - }, - "readOnly": true - }, - "nextLink": { - "description": "Link to retrieve next page of results.", - "type": "string", - "readOnly": true - } - } - }, - "MetricDefinition": { - "description": "A metric definition resource.", - "type": "object", - "properties": { - "name": { - "$ref": "#/definitions/MetricName", - "description": "Name of the metric.", - "readOnly": true - }, - "unit": { - "description": "The unit of the metric.", - "enum": [ - "Count", - "Bytes", - "Seconds", - "Percent", - "CountPerSecond", - "BytesPerSecond" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "UnitType", - "modelAsString": true - } - }, - "resourceId": { - "description": "The uri of the resource that the metric describes.", - "type": "string", - "readOnly": true - }, - "primaryAggregationType": { - "description": "The primary aggregation type defining how metric values are displayed.", - "enum": [ - "None", - "Average", - "Count", - "Minimum", - "Maximum", - "Total" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "PrimaryAggregationType", - "modelAsString": true - } - }, - "supportedAggregationTypes": { - "description": "The supported aggregation types defining how metric values are displayed.", - "type": "array", - "items": { - "type": "string" - }, - "readOnly": true - }, - "metricAvailabilities": { - "description": "The list of metric availabilities for the metric.", - "type": "array", - "items": { - "$ref": "#/definitions/MetricAvailability" - }, - "readOnly": true - } - } - }, - "MetricName": { - "description": "A managed instance metric name.", - "type": "object", - "properties": { - "value": { - "description": "The name of the database metric.", - "type": "string", - "readOnly": true - }, - "localizedValue": { - "description": "The friendly name of the database metric.", - "type": "string", - "readOnly": true - } - } - }, - "MetricAvailability": { - "description": "A metric availability value.", - "type": "object", - "properties": { - "timeGrain": { - "description": "The granularity of the database metric.", - "enum": [ - "PT5M", - "PT1H", - "P1D" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "TimeGrainType", - "modelAsString": true - } - }, - "retention": { - "description": "The length of retention for the database metric.", - "enum": [ - "P14D" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "RetentionType", - "modelAsString": true - } - } - } - }, - "MetricListResult": { - "description": "A list of metric resources.", - "type": "object", - "properties": { - "value": { - "description": "Array of results.", - "type": "array", - "items": { - "$ref": "#/definitions/Metric" - }, - "readOnly": true - }, - "nextLink": { - "description": "Link to retrieve next page of results.", - "type": "string", - "readOnly": true - } - } - }, - "Metric": { - "description": "A metric resource.", - "type": "object", - "properties": { - "name": { - "$ref": "#/definitions/MetricName", - "description": "The name information for the metric.", - "readOnly": true - }, - "unit": { - "description": "The unit of the metric.", - "enum": [ - "Count", - "Bytes", - "Seconds", - "Percent", - "CountPerSecond", - "BytesPerSecond" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "UnitType", - "modelAsString": true - } - }, - "timeGrain": { - "description": "The time step to be used to summarize the metric values.", - "enum": [ - "PT5M", - "PT1H", - "P1D" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "TimeGrainType", - "modelAsString": true - } - }, - "startTime": { - "description": "The start time for the metric (ISO-8601 format).", - "type": "string", - "readOnly": true - }, - "endTime": { - "description": "The end time for the metric (ISO-8601 format).", - "type": "string", - "readOnly": true - }, - "timeseries": { - "description": "The metric timeseries for the specified time window and timestep.", - "type": "array", - "items": { - "$ref": "#/definitions/MetricTimeseries" - }, - "readOnly": true - } - } - }, - "MetricTimeseries": { - "description": "A metric timeseries.", - "type": "object", - "properties": { - "data": { - "description": "The metric values for the specified time window and timestep.", - "type": "array", - "items": { - "$ref": "#/definitions/MetricValue" - }, - "readOnly": true - } - } - }, - "MetricValue": { - "description": "A metric value.", - "type": "object", - "properties": { - "timeStamp": { - "format": "date-time", - "description": "The metric timestamp (ISO-8601 format).", - "type": "string", - "readOnly": true - }, - "average": { - "format": "double", - "description": "The average value of the metric.", - "type": "number", - "readOnly": true - }, - "minimum": { - "format": "double", - "description": "The min value of the metric.", - "type": "number", - "readOnly": true - }, - "maximum": { - "format": "double", - "description": "The max value of the metric.", - "type": "number", - "readOnly": true - }, - "total": { - "format": "double", - "description": "The total value of the metric.", - "type": "number", - "readOnly": true - }, - "count": { - "format": "int32", - "description": "The number of values for the metric.", - "type": "integer", - "readOnly": true - } - } - }, "ManagedInstanceListResult": { "description": "A list of managed instances.", "type": "object", @@ -897,28 +250,6 @@ "x-ms-client-flatten": true } } - }, - "ManagedInstanceUpdate": { - "description": "An update request for an Azure SQL Database managed instance.", - "type": "object", - "properties": { - "sku": { - "$ref": "../../../common/v1/types.json#/definitions/Sku", - "description": "Managed instance sku" - }, - "properties": { - "$ref": "#/definitions/ManagedInstanceProperties", - "description": "Resource properties.", - "x-ms-client-flatten": true - }, - "tags": { - "description": "Resource tags.", - "type": "object", - "additionalProperties": { - "type": "string" - } - } - } } }, "parameters": { From 5c378f6e0e52396832672840c0fb4a589599c6f5 Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Wed, 19 Jun 2019 16:27:28 -0700 Subject: [PATCH 07/11] Update 2018 managed instance swagger to include prior APIs --- .../examples/ManagedInstanceCreateMax.json | 99 +++ .../examples/ManagedInstanceCreateMin.json | 86 +++ .../examples/ManagedInstanceDelete.json | 17 + .../examples/ManagedInstanceGet.json | 41 + .../examples/ManagedInstanceList.json | 64 ++ .../ManagedInstanceListByInstancePool.json | 2 +- .../ManagedInstanceListByResourceGroup.json | 65 ++ .../examples/ManagedInstanceUpdateMax.json | 62 ++ .../examples/ManagedInstanceUpdateMin.json | 47 ++ ...ManagedInstancesListMetricDefinitions.json | 132 ++++ .../examples/ManagedInstancesListMetrics.json | 148 ++++ .../ManagedInstancesListMetricsMax.json | 148 ++++ .../ManagedInstancesListMetricsMin.json | 556 ++++++++++++++ .../2018-06-01-preview/managedInstances.json | 699 ++++++++++++++++++ 14 files changed, 2165 insertions(+), 1 deletion(-) create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMax.json create mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMin.json diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json new file mode 100644 index 000000000000..ebc90b3fe214 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMax.json @@ -0,0 +1,99 @@ +{ + "parameters" : { + "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName" : "testrg", + "managedInstanceName" : "testinstance", + "api-version" : "2018-06-01-preview", + "parameters" : { + "tags" : { + "tagKey1" : "TagValue1" + }, + "location" : "Japan East", + "sku" : { + "name" : "GP_Gen5", + "tier" : "GeneralPurpose" + }, + "properties": { + "administratorLogin": "dummylogin", + "administratorLoginPassword": "Un53cuRE!", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "dnsZonePartner": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "publicDataEndpointEnabled": false, + "proxyOverride": "Redirect", + "timezoneId": "UTC", + "instancePoolId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1" + } + } + }, + "responses" : { + "200": { + "body": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen5" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Redirect", + "dnsZone": "1b4e2caff2530", + "timezoneId": "UTC", + "instancePoolId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1" + }, + "location": "japaneast", + "tags": { + "tagKey1": "TagValue1" + }, + "id": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + }, + "201" : { + "body": { + "sku": { + "name": "GP_Gen5", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen5" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Redirect", + "dnsZone": "1b4e2caff2530", + "timezoneId": "UTC", + "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/pool1" + }, + "location": "japaneast", + "tags": { + "tagKey1": "TagValue1" + }, + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + }, + "202" : {} + } +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json new file mode 100644 index 000000000000..1614fc58b4cb --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceCreateMin.json @@ -0,0 +1,86 @@ +{ + "parameters": { + "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName": "testrg", + "managedInstanceName": "testinstance", + "api-version": "2018-06-01-preview", + "parameters": { + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose" + }, + "properties": { + "administratorLogin": "dummylogin", + "administratorLoginPassword": "Un53cuRE!", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded" + }, + "location": "Japan East" + } + }, + "responses": { + "200": { + "body": { + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "1b4e2caff2530" + }, + "location": "japaneast", + "tags": { + + }, + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + }, + "201": { + "body": { + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Redirect", + "dnsZone": "1b4e2caff2530" + }, + "location": "japaneast", + "tags": { + + }, + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + }, + "202": {} + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json new file mode 100644 index 000000000000..6004313ec907 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceDelete.json @@ -0,0 +1,17 @@ +{ + "parameters" : { + "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName" : "testrg", + "managedInstanceName" : "testinstance", + "api-version" : "2018-06-01-preview" + }, + "responses" : { + "200" : { + "body" : "" + }, + "202" : {}, + "204" : { + "body" : "" + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json new file mode 100644 index 000000000000..49d535c91918 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceGet.json @@ -0,0 +1,41 @@ +{ + "parameters" : { + "subscriptionId" : "20d7082a-0fc7-4468-82bd-542694d5042b", + "resourceGroupName" : "testrg", + "managedInstanceName" : "testinstance", + "api-version" : "2018-06-01-preview" + }, + "responses" : { + "200" : { + "body": { + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "1b4e2caff2530", + "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1" + }, + "location": "japaneast", + "tags": { + "key": "value" + }, + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json new file mode 100644 index 000000000000..4b4c79cada10 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceList.json @@ -0,0 +1,64 @@ +{ + "parameters" : { + "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", + "api-version" : "2018-06-01-preview" + }, + "responses" : { + "200" : { + "body" : { + "value": [ + { + "location": "japaneast", + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance1", + "name": "testinstance1", + "type": "Microsoft.Sql/managedInstances", + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance1.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "1b4e2caff2530" + } + }, + { + "location": "japaneast", + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance2", + "name": "testinstance2", + "type": "Microsoft.Sql/managedInstances", + "sku": { + "name": "BC_Gen5", + "tier": "BusinessCritical", + "capacity": 16, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance2.2c3d1bdae3412.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet2/subnets/subnet2", + "state": "Ready", + "vCores": 16, + "storageSizeInGB": 1024, + "licenseType": "Full", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "2c3d1bdae3412" + } + } + ] + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByInstancePool.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByInstancePool.json index 313ef50fc116..ac0019f76c76 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByInstancePool.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByInstancePool.json @@ -65,4 +65,4 @@ } } } -} +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json new file mode 100644 index 000000000000..de6d26231aad --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceListByResourceGroup.json @@ -0,0 +1,65 @@ +{ + "parameters": { + "subscriptionId": "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName": "Test1", + "api-version": "2018-06-01-preview" + }, + "responses": { + "200": { + "body": { + "value": [ + { + "location": "japaneast", + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance1", + "name": "testinstance1", + "type": "Microsoft.Sql/managedInstances", + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance1.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "1b4e2caff2530" + } + }, + { + "location": "japaneast", + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/Test1/providers/Microsoft.Sql/managedInstances/testinstance2", + "name": "testinstance2", + "type": "Microsoft.Sql/managedInstances", + "sku": { + "name": "BC_Gen5", + "tier": "BusinessCritical", + "capacity": 16, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance2.2c3d1bdae3412.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet2/subnets/subnet2", + "state": "Ready", + "vCores": 16, + "storageSizeInGB": 1024, + "licenseType": "Full", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "2c3d1bdae3412" + } + } + ] + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json new file mode 100644 index 000000000000..a9f060756e1c --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMax.json @@ -0,0 +1,62 @@ +{ + "parameters" : { + "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName" : "testrg", + "managedInstanceName" : "testinstance", + "api-version" : "2018-06-01-preview", + "parameters" : { + "tags" : { + "tagKey1" : "TagValue1" + }, + "sku" : { + "name" : "GP_Gen4", + "tier" : "GeneralPurpose", + "capacity" : 8 + }, + "properties": { + "administratorLogin": "dummylogin", + "administratorLoginPassword": "Un53cuRE!", + "proxyOverride": "Redirect", + "publicDataEndpointEnabled": false, + "licenseType": "BasePrice", + "vCores": 8, + "storageSizeInGB": 448, + "collation": "SQL_Latin1_General_CP1_CI_AS" + } + } + }, + "responses" : { + "200" : { + "body": { + "tags": { + "tagKey1": "TagValue1" + }, + "id": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances", + "location": "japaneast", + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 448, + "licenseType": "BasePrice", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Redirect", + "dnsZone": "1b4e2caff2530", + "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1" + } + } + }, + "202" : {} + } +} diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json new file mode 100644 index 000000000000..9ab8d63686e8 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstanceUpdateMin.json @@ -0,0 +1,47 @@ +{ + "parameters": { + "subscriptionId" : "20D7082A-0FC7-4468-82BD-542694D5042B", + "resourceGroupName" : "testrg", + "managedInstanceName" : "testinstance", + "api-version": "2018-06-01-preview", + "parameters": { + "tags": { + "tagKey1": "TagValue1" + } + } + }, + "responses": { + "200": { + "body": { + "sku": { + "name": "GP_Gen4", + "tier": "GeneralPurpose", + "capacity": 8, + "family": "Gen4" + }, + "properties": { + "fullyQualifiedDomainName": "testinstance.1b4e2caff2530.database.windows.net", + "administratorLogin": "dummylogin", + "subnetId": "/subscriptions/20D7082A-0FC7-4468-82BD-542694D5042B/resourceGroups/testrg/providers/Microsoft.Network/virtualNetworks/vnet1/subnets/subnet1", + "state": "Ready", + "vCores": 8, + "storageSizeInGB": 1024, + "licenseType": "LicenseIncluded", + "collation": "SQL_Latin1_General_CP1_CI_AS", + "publicDataEndpointEnabled": false, + "proxyOverride": "Default", + "dnsZone": "1b4e2caff2530", + "instancePoolId": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/instancePools/instancePool1" + }, + "location": "japaneast", + "tags": { + "tagKey1": "TagValue1" + }, + "id": "/subscriptions/20d7082a-0fc7-4468-82bd-542694d5042b/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testinstance", + "name": "testinstance", + "type": "Microsoft.Sql/managedInstances" + } + }, + "202": {} + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json new file mode 100644 index 000000000000..9e7825a8cd9b --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json @@ -0,0 +1,132 @@ +{ + "parameters":{ + "subscriptionId":"00000000-1111-2222-3333-444444444444", + "resourceGroupName":"Test1", + "managedInstanceName":"managedInstance", + "api-version":"2018-06-01-preview" + }, + "responses":{ + "200":{ + "body":{ + "value":[ + { + "name":{ + "value":"reserved_storage_mb", + "localizedValue":"Storage space reserved" + }, + "unit":"Bytes", + "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", + "primaryAggregationType":"Average", + "supportedAggregationTypes":[ + "Average", + "Minimum", + "Maximum", + "Count" + ], + "metricAvailabilities":[ + { + "timeGrain":"PT5M", + "retention":"P14D" + }, + { + "timeGrain":"PT1H", + "retention":"P14D" + }, + { + "timeGrain":"P1D", + "retention":"P14D" + } + ] + }, + { + "name":{ + "value":"storage_space_used_mb", + "localizedValue":"Storage space used" + }, + "unit":"Bytes", + "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", + "primaryAggregationType":"Average", + "supportedAggregationTypes":[ + "Average", + "Minimum", + "Maximum", + "Count" + ], + "metricAvailabilities":[ + { + "timeGrain":"PT5M", + "retention":"P14D" + }, + { + "timeGrain":"PT1H", + "retention":"P14D" + }, + { + "timeGrain":"P1D", + "retention":"P14D" + } + ] + }, + { + "name":{ + "value":"avg_cpu_percent", + "localizedValue":"Average CPU percentage" + }, + "unit":"Percent", + "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", + "primaryAggregationType":"Average", + "supportedAggregationTypes":[ + "Average", + "Minimum", + "Maximum", + "Count" + ], + "metricAvailabilities":[ + { + "timeGrain":"PT5M", + "retention":"P14D" + }, + { + "timeGrain":"PT1H", + "retention":"P14D" + }, + { + "timeGrain":"P1D", + "retention":"P14D" + } + ] + }, + { + "name":{ + "value":"virtual_core_count", + "localizedValue":"Virtual core count" + }, + "unit":"Count", + "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", + "primaryAggregationType":"Average", + "supportedAggregationTypes":[ + "Average", + "Minimum", + "Maximum", + "Count" + ], + "metricAvailabilities":[ + { + "timeGrain":"PT5M", + "retention":"P14D" + }, + { + "timeGrain":"PT1H", + "retention":"P14D" + }, + { + "timeGrain":"P1D", + "retention":"P14D" + } + ] + } + ] + } + } + } + } \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json new file mode 100644 index 000000000000..efcc74487186 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json @@ -0,0 +1,148 @@ +{ + "parameters":{ + "subscriptionId":"00000000-1111-2222-3333-444444444444", + "resourceGroupName":"Test1", + "managedInstanceName":"managedInstance", + "metric":"avg_cpu_percent", + "timespan":"2018-03-01T00:00:00Z/2018-03-03T18:00:00Z", + "aggregation":"average", + "interval":"PT5M", + "api-version":"2018-06-01-preview" + }, + "responses":{ + "200":{ + "body":{ + "value":[ + { + "name":{ + "value":"avg_cpu_percent", + "localizedValue":"Average CPU percentage" + }, + "unit":"Percent", + "timeGrain":"PT5M", + "startTime":"3/1/2018 1:00:00 AM", + "endTime":"3/3/2018 7:00:00 PM", + "timeseries":[ + { + "data":[ + { + "timeStamp":"2018-03-02T13:30:01Z", + "average":1.881666, + "minimum":0.13, + "maximum":7.06, + "count":12 + }, + { + "timeStamp":"2018-03-02T13:35:01Z", + "average":0.8755, + "minimum":0.12, + "maximum":4.22, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:40:01Z", + "average":0.4665, + "minimum":0.14, + "maximum":2.31, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:45:01Z", + "average":0.3545, + "minimum":0.13, + "maximum":1.72, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:50:01Z", + "average":0.3505, + "minimum":0.13, + "maximum":1.38, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:55:01Z", + "average":0.3535, + "minimum":0.13, + "maximum":1.39, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:00:01Z", + "average":0.418, + "minimum":0.13, + "maximum":1.54, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:05:01Z", + "average":0.35, + "minimum":0.15, + "maximum":1.44, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:10:01Z", + "average":0.3525, + "minimum":0.14, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:15:01Z", + "average":0.352, + "minimum":0.15, + "maximum":1.56, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:20:01Z", + "average":0.3495, + "minimum":0.16, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:25:01Z", + "average":0.368, + "minimum":0.15, + "maximum":1.31, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:30:01Z", + "average":0.438, + "minimum":0.15, + "maximum":2.69, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:35:01Z", + "average":0.3895, + "minimum":0.16, + "maximum":1.29, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:40:01Z", + "average":0.3515, + "minimum":0.12, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:45:01Z", + "average":0.405263, + "minimum":0.12, + "maximum":2.17, + "count":19 + } + ] + } + ] + } + ] + } + } + } + } \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMax.json new file mode 100644 index 000000000000..efcc74487186 --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMax.json @@ -0,0 +1,148 @@ +{ + "parameters":{ + "subscriptionId":"00000000-1111-2222-3333-444444444444", + "resourceGroupName":"Test1", + "managedInstanceName":"managedInstance", + "metric":"avg_cpu_percent", + "timespan":"2018-03-01T00:00:00Z/2018-03-03T18:00:00Z", + "aggregation":"average", + "interval":"PT5M", + "api-version":"2018-06-01-preview" + }, + "responses":{ + "200":{ + "body":{ + "value":[ + { + "name":{ + "value":"avg_cpu_percent", + "localizedValue":"Average CPU percentage" + }, + "unit":"Percent", + "timeGrain":"PT5M", + "startTime":"3/1/2018 1:00:00 AM", + "endTime":"3/3/2018 7:00:00 PM", + "timeseries":[ + { + "data":[ + { + "timeStamp":"2018-03-02T13:30:01Z", + "average":1.881666, + "minimum":0.13, + "maximum":7.06, + "count":12 + }, + { + "timeStamp":"2018-03-02T13:35:01Z", + "average":0.8755, + "minimum":0.12, + "maximum":4.22, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:40:01Z", + "average":0.4665, + "minimum":0.14, + "maximum":2.31, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:45:01Z", + "average":0.3545, + "minimum":0.13, + "maximum":1.72, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:50:01Z", + "average":0.3505, + "minimum":0.13, + "maximum":1.38, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:55:01Z", + "average":0.3535, + "minimum":0.13, + "maximum":1.39, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:00:01Z", + "average":0.418, + "minimum":0.13, + "maximum":1.54, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:05:01Z", + "average":0.35, + "minimum":0.15, + "maximum":1.44, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:10:01Z", + "average":0.3525, + "minimum":0.14, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:15:01Z", + "average":0.352, + "minimum":0.15, + "maximum":1.56, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:20:01Z", + "average":0.3495, + "minimum":0.16, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:25:01Z", + "average":0.368, + "minimum":0.15, + "maximum":1.31, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:30:01Z", + "average":0.438, + "minimum":0.15, + "maximum":2.69, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:35:01Z", + "average":0.3895, + "minimum":0.16, + "maximum":1.29, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:40:01Z", + "average":0.3515, + "minimum":0.12, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:45:01Z", + "average":0.405263, + "minimum":0.12, + "maximum":2.17, + "count":19 + } + ] + } + ] + } + ] + } + } + } + } \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMin.json new file mode 100644 index 000000000000..49f4fcbb3dfe --- /dev/null +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMin.json @@ -0,0 +1,556 @@ +{ + "parameters":{ + "subscriptionId":"00000000-1111-2222-3333-444444444444", + "resourceGroupName":"Test1", + "managedInstanceName":"managedInstance", + "api-version":"2018-06-01-preview" + }, + "responses":{ + "200":{ + "body":{ + "value":[ + { + "name":{ + "value":"avg_cpu_percent", + "localizedValue":"Average CPU percentage" + }, + "unit":"Percent", + "timeGrain":"PT5M", + "startTime":"3/1/2018 2:54:05 PM", + "endTime":"3/2/2018 2:54:05 PM", + "timeseries":[ + { + "data":[ + { + "timeStamp":"2018-03-02T13:30:01Z", + "average":1.881666, + "minimum":0.13, + "maximum":7.06, + "count":12 + }, + { + "timeStamp":"2018-03-02T13:35:01Z", + "average":0.8755, + "minimum":0.12, + "maximum":4.22, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:40:01Z", + "average":0.4665, + "minimum":0.14, + "maximum":2.31, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:45:01Z", + "average":0.3545, + "minimum":0.13, + "maximum":1.72, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:50:01Z", + "average":0.3505, + "minimum":0.13, + "maximum":1.38, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:55:01Z", + "average":0.3535, + "minimum":0.13, + "maximum":1.39, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:00:01Z", + "average":0.418, + "minimum":0.13, + "maximum":1.54, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:05:01Z", + "average":0.35, + "minimum":0.15, + "maximum":1.44, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:10:01Z", + "average":0.3525, + "minimum":0.14, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:15:01Z", + "average":0.352, + "minimum":0.15, + "maximum":1.56, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:20:01Z", + "average":0.3495, + "minimum":0.16, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:25:01Z", + "average":0.368, + "minimum":0.15, + "maximum":1.31, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:30:01Z", + "average":0.438, + "minimum":0.15, + "maximum":2.69, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:35:01Z", + "average":0.3895, + "minimum":0.16, + "maximum":1.29, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:40:01Z", + "average":0.3515, + "minimum":0.12, + "maximum":1.41, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:45:01Z", + "average":0.402, + "minimum":0.12, + "maximum":2.17, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:50:01Z", + "average":0.47, + "minimum":0.13, + "maximum":2.17, + "count":11 + } + ] + } + ] + }, + { + "name":{ + "value":"virtual_core_count", + "localizedValue":"Virtual core count" + }, + "unit":"Count", + "timeGrain":"PT5M", + "startTime":"3/1/2018 2:54:05 PM", + "endTime":"3/2/2018 2:54:05 PM", + "timeseries":[ + { + "data":[ + { + "timeStamp":"2018-03-02T13:30:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":12 + }, + { + "timeStamp":"2018-03-02T13:35:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:40:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:45:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:50:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:55:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:00:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:05:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:10:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:15:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:20:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:25:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:30:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:35:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:40:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:45:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:50:01Z", + "average":8.0, + "minimum":8.0, + "maximum":8.0, + "count":11 + } + ] + } + ] + }, + { + "name":{ + "value":"reserved_storage_mb", + "localizedValue":"Storage space reserved" + }, + "unit":"Bytes", + "timeGrain":"PT5M", + "startTime":"3/1/2018 2:54:05 PM", + "endTime":"3/2/2018 2:54:05 PM", + "timeseries":[ + { + "data":[ + { + "timeStamp":"2018-03-02T13:30:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":12 + }, + { + "timeStamp":"2018-03-02T13:35:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:40:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:45:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:50:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:55:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:00:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:05:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:10:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:15:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:20:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:25:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:30:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:35:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:40:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:45:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:50:01Z", + "average":32768.0, + "minimum":32768.0, + "maximum":32768.0, + "count":11 + } + ] + } + ] + }, + { + "name":{ + "value":"storage_space_used_mb", + "localizedValue":"Storage space used" + }, + "unit":"Bytes", + "timeGrain":"PT5M", + "startTime":"3/1/2018 2:54:05 PM", + "endTime":"3/2/2018 2:54:05 PM", + "timeseries":[ + { + "data":[ + { + "timeStamp":"2018-03-02T13:30:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":12 + }, + { + "timeStamp":"2018-03-02T13:35:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:40:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:45:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:50:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T13:55:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:00:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:05:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:10:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:15:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:20:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:25:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:30:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:35:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:40:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:45:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":20 + }, + { + "timeStamp":"2018-03-02T14:50:01Z", + "average":230.0, + "minimum":230.0, + "maximum":230.0, + "count":11 + } + ] + } + ] + } + ] + } + } + } +} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json index f90dfd59b7e5..7d8f704a460d 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json @@ -16,6 +16,349 @@ "application/json" ], "paths": { + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/metricDefinitions": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a list of managed instance metric definitions.", + "operationId": "ManagedInstances_ListMetricDefinitions", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the list of metric definitions for managed instance.", + "schema": { + "$ref": "#/definitions/MetricDefinitionListResult" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 404 ServerNotFound - The requested server was not found.\n\n * 405 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + }, + "x-ms-examples": { + "List metric definitions by managed instance": { + "$ref": "./examples/ManagedInstancesListMetricDefinitions.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/metrics": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a list of managed instance metrics.", + "operationId": "ManagedInstances_ListMetrics", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "name": "metric", + "in": "query", + "description": "Name of the metrics to get.", + "required": false, + "type": "string" + }, + { + "name": "timespan", + "in": "query", + "description": "The timespan for the metric.", + "required": false, + "type": "string" + }, + { + "name": "aggregation", + "in": "query", + "description": "The aggregation type to use.", + "required": false, + "type": "string" + }, + { + "name": "interval", + "in": "query", + "description": "The time step to be used to summarize the metric values.", + "required": false, + "type": "string" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the list of databases.", + "schema": { + "$ref": "#/definitions/MetricListResult" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 404 ServerNotFound - The requested server was not found.\n\n * 405 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + }, + "x-ms-examples": { + "List metrics by managed instance": { + "$ref": "./examples/ManagedInstancesListMetrics.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a list of managed instances in a resource group.", + "operationId": "ManagedInstances_ListByResourceGroup", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the list of managed instances.", + "schema": { + "$ref": "#/definitions/ManagedInstanceListResult" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + }, + "x-ms-examples": { + "List managed instances by resource group": { + "$ref": "./examples/ManagedInstanceListByResourceGroup.json" + } + } + } + }, + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a managed instance.", + "operationId": "ManagedInstances_Get", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the specified managed instance.", + "schema": { + "$ref": "#/definitions/ManagedInstance" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + } + }, + "x-ms-examples": { + "Get managed instance": { + "$ref": "./examples/ManagedInstanceGet.json" + } + } + }, + "put": { + "tags": [ + "ManagedInstances" + ], + "description": "Creates or updates a managed instance.", + "operationId": "ManagedInstances_CreateOrUpdate", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "name": "parameters", + "in": "body", + "description": "The requested managed instance resource state.", + "required": true, + "schema": { + "$ref": "#/definitions/ManagedInstance" + } + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully updated the managed instance.", + "schema": { + "$ref": "#/definitions/ManagedInstance" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.\n\n * 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.\n\n * 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.\n\n * 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.\n\n * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet\n\n * 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.\n\n * 400 SubnetHasResourcesOfDifferentType - User tried to create MI in subnet that has resources of different type.\n\n * 400 InvalidUsername - Supplied user name contains invalid characters.\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity\n\n * 400 ServerNotFound - The requested server was not found.\n\n * 400 TokenTooLong - The provided token is too long.\n\n * 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.\n\n * 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.\n\n * 400 InvalidLoginName - The provided login name is invalid.\n\n * 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.\n\n * 400 PasswordTooShort - The provided password is too short\n\n * 400 PasswordTooLong - The provided password is too long.\n\n * 400 PasswordNotComplex - The provided password is not complex enough.\n\n * 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.\n\n * 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 InvalidLocation - An invalid location was specified.\n\n * 400 VnetInWrongRegion - Virtual network is in wrong region.\n\n * 400 InvalidServerName - Invalid server name specified.\n\n * 400 VnetAddressRangeError - Virtual network address range is invalid.\n\n * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.\n\n * 400 InvalidCollation - Invalid collation.\n\n * 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.\n\n * 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.\n\n * 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.\n\n * 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.\n\n * 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.\n\n * 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.\n\n * 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.\n\n * 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.\n\n * 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.\n\n * 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.\n\n * 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.\n\n * 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.\n\n * 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.\n\n * 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.\n\n * 400 NameAlreadyExists - The provided name already exists.\n\n * 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.\n\n * 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes\n\n * 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.\n\n * 400 ManagedInstanceUpdateSloInProgress - \"The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again.\"\n\n * 400 VnetResourceNotFound - Resource not found: '{0}'.\n\n * 400 InvalidTimezone - Invalid timezone.\n\n * 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.\n\n * 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.\n\n * 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.\n\n * 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.\n\n * 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.\n\n * 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.\n\n * 400 InvalidManagedServerDnsZonePartner - Invalid DNS zone partner resource id specified in properties.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.\n\n * 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.\n\n * 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.\n\n * 405 InvalidStorageSizeValue - \"Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 409 ConflictingServerOperation - An operation is currently in progress for the server.\n\n * 409 SubscriptionDisabled - Subscription is disabled.\n\n * 409 ServerAlreadyExists - Duplicate server name.\n\n * 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.\n\n * 409 ServerDisabled - Server is disabled.\n\n * 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.\n\n * 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 500 GatewayInternalServerError - The server encountered an unexpected exception.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + }, + "202": { + "description": "Accepted" + }, + "201": { + "description": "Successfully created the managed instance.", + "schema": { + "$ref": "#/definitions/ManagedInstance" + } + } + }, + "x-ms-long-running-operation": true, + "x-ms-examples": { + "Create managed instance with minimal properties": { + "$ref": "./examples/ManagedInstanceCreateMin.json" + }, + "Create managed instance with all properties": { + "$ref": "./examples/ManagedInstanceCreateMax.json" + } + } + }, + "delete": { + "tags": [ + "ManagedInstances" + ], + "description": "Deletes a managed instance.", + "operationId": "ManagedInstances_Delete", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully deleted the managed instance." + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 409 ConflictingManagedInstanceOperation - An operation is currently in progress for the managed instance.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + }, + "202": { + "description": "Accepted" + }, + "204": { + "description": "The specified managed instance does not exist." + } + }, + "x-ms-long-running-operation": true, + "x-ms-examples": { + "Delete managed instance": { + "$ref": "./examples/ManagedInstanceDelete.json" + } + } + }, + "patch": { + "tags": [ + "ManagedInstances" + ], + "description": "Updates a managed instance.", + "operationId": "ManagedInstances_Update", + "parameters": [ + { + "$ref": "#/parameters/ResourceGroupParameter" + }, + { + "$ref": "#/parameters/ManagedInstanceNameParameter" + }, + { + "name": "parameters", + "in": "body", + "description": "The requested managed instance resource state.", + "required": true, + "schema": { + "$ref": "#/definitions/ManagedInstanceUpdate" + } + }, + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully updated the managed instance.", + "schema": { + "$ref": "#/definitions/ManagedInstance" + } + }, + "default": { + "description": "*** Error Responses: ***\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 HkCannotSwitchToInactive - The database cannot proceed with pricing-tier update as it has memory-optimized objects. Please drop such objects and try again.\n\n * 400 ManagedInstanceInvalidStorageSizeLessThenCurrentSizeUsed - Invalid storage size: Storage size limit ({0} GB) is less that current storage used ({1} GB). Please specify higher storage size limit.\n\n * 400 InstanceTimezoneUpdateNotSupported - Instance timezone update not supported.\n\n * 400 CreateManagedInstanceWithNonDefaultTimezoneNotSupported - Create Managed Instance with non-default timezone not supported.\n\n * 400 ManagedInstanceIpAddressRangeLimit - Cannot create a Managed Instance as there are not enough available ip addresses in the selected subnet\n\n * 400 VnetDelegationNotAllowed - User tried to inject Managed Server to subnet which is delegated.\n\n * 400 SubnetHasResourcesOfDifferentType - User tried to create MI in subnet that has resources of different type.\n\n * 400 InvalidUsername - Supplied user name contains invalid characters.\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 400 InstancePoolNotEnoughCapacity - An instance pool does not have enough vCore capacity\n\n * 400 ServerNotFound - The requested server was not found.\n\n * 400 TokenTooLong - The provided token is too long.\n\n * 400 ManagedInstanceSloUpdateFailed - SLO '{0}' operation cannot succeed as the memory usage of '{1}' exceeds the quota.\n\n * 400 ManagedInstanceLocalStorageUpdateSloDisabled - Update SLO for managed instances with local storage is not supported yet.\n\n * 400 InvalidLoginName - The provided login name is invalid.\n\n * 400 RegionDoesNotSupportVersion - A user attempted to create a server of a specified version in a location where that server version isn't supported.\n\n * 400 PasswordTooShort - The provided password is too short\n\n * 400 PasswordTooLong - The provided password is too long.\n\n * 400 PasswordNotComplex - The provided password is not complex enough.\n\n * 400 GatewayInvalidEdition - '{0}' is not a valid database edition in this version of SQL Server.\n\n * 400 InvalidSubnetResourceId - The provided subnet resource ID for the managed instance create or update is invalid.\n\n * 400 SubscriptionNotFound - The requested subscription was not found.\n\n * 400 InvalidLocation - An invalid location was specified.\n\n * 400 VnetInWrongRegion - Virtual network is in wrong region.\n\n * 400 InvalidServerName - Invalid server name specified.\n\n * 400 VnetAddressRangeError - Virtual network address range is invalid.\n\n * 400 VnetConfigIsNotAllowed - Virtual network configuration is not allowed.\n\n * 400 InvalidCollation - Invalid collation.\n\n * 400 InvalidIdentifier - The identifier contains NULL or an invalid unicode character.\n\n * 400 ManagedInstanceClassicVnetNotSupported - Managed Instance cannot be joined to a classic virtual network.\n\n * 400 AlterDbDeactivatedNotSupported - Database Operation failed for Server '{0}', Database '{1}' due to unexpected delay. Please try again.\n\n * 400 RegionDoesNotAllowProvisioning - The selected location is not accepting new Windows Azure SQL Database servers. This may change at a later time.\n\n * 400 VnetConfigHasNsg - User tried to inject Managed Server subnet with Network Security Groups.\n\n * 400 VnetConfigHasNoUdr - User tried to inject Managed Server subnet without default User Defined Route Table.\n\n * 400 VnetConfigHasInvalidUdr - User tried to inject Managed Server subnet with invalid User Defined Route Table.\n\n * 400 VnetConfigHasInvalidDns - User tried to inject Managed Server subnet with invalid custom DNS.\n\n * 400 VnetConfigHasServiceEndpoints - User tried to inject Managed Server subnet with service endpoints.\n\n * 400 VnetSubnetIsInUse - User tried to inject Managed Server subnet that is not empty.\n\n * 400 VnetSubnetIsLocked - User tried to inject Managed Server subnet that is in locked scope.\n\n * 400 VnetSubnetIsGateway - User tried to inject Managed Server subnet that is Gateway subnet.\n\n * 400 VnetSubnetIsUnknown - User tried to inject Managed Server subnet that does not exist.\n\n * 400 VnetSubnetConflictWithIntendedPolicy - User tried to inject Managed Server subnet that has a conflict with IntendedPolicy.\n\n * 400 NameAlreadyExists - The provided name already exists.\n\n * 400 ManagedInstanceInvalidEditionForSku - The specified edition {0} is not consistent with the specified SKU {1}.\n\n * 400 ProvisioningDisabled - Displays error message from resources operation authorizer as is, without changes\n\n * 400 ManagedInstanceInvalidLicenseType - The specified license type {0} is not valid.\n\n * 400 ManagedInstanceUpdateSloInProgress - \"The operation could not be completed because a service tier change is in progress for managed instance '{0}.' Please wait for the operation in progress to complete and try again.\"\n\n * 400 VnetResourceNotFound - Resource not found: '{0}'.\n\n * 400 InvalidTimezone - Invalid timezone.\n\n * 400 UnableToResolveRemoteServer - The remote partner server name could not be resolved due to an invalid server name or DNS connectivity issues.\n\n * 400 InstanceCollationUpdateNotSupported - User cannot change instance collation on Managed Instance.\n\n * 400 CreateManagedInstanceWithNonDefaultCollationNotSupported - User can create a Managed Instance only with collation 'SQL_Latin1_General_CP1_CI_AS'.\n\n * 400 ManagedInstanceOperationInProgress - The operation could not be completed because {0} operation is in progress. Please wait for the operation in progress to complete and try again.\n\n * 400 ManagedInstanceExceedMaxAzureStorage - The operation could not be completed because total allocated storage size for General Purpose instance would exceed {0}. Please reduce the number of database files and retry operation.\n\n * 400 ManagedInstanceHasGeoReplica - The operation could not be completed because instance has configured geo replicated secondary instance.\n\n * 400 MismatchingResourceGroupNameWithUrl - The provided resource group name did not match the name in the Url.\n\n * 400 MismatchingSubscriptionWithUrl - The provided subscription did not match the subscription in the Url.\n\n * 404 ServerNotInSubscription - Specified server does not exist on the specified subscription.\n\n * 404 ManagedInstanceNotInSubscriptionResourceGroup - Specified managed instance does not exist in the specified resource group and subscription.\n\n * 404 OperationIdNotFound - The operation with Id does not exist.\n\n * 404 ResourceDoesNotExist - Resource with the name '{0}' does not exist. To continue, specify a valid resource name.\n\n * 404 ResourceNotFound - The requested resource was not found.\n\n * 405 InvalidVcoreValue - vCore value {0} is not valid. Please specify a valid vCore value.\n\n * 405 InvalidHardwareGenerationValue - HardwareGeneration {0} is not valid. Please specify a valid HardwareGeneration value.\n\n * 405 InvalidStorageSizeValue - \"Invalid storage size: {0} GB. Storage size must be specified between {1} and {2} gigabytes, in increments of {3} GB.\n\n * 409 OperationCancelled - The operation has been cancelled by user.\n\n * 409 OperationInterrupted - The operation on the resource could not be completed because it was interrupted by another operation on the same resource.\n\n * 409 ConflictingServerOperation - An operation is currently in progress for the server.\n\n * 409 SubscriptionDisabled - Subscription is disabled.\n\n * 409 ServerAlreadyExists - Duplicate server name.\n\n * 409 ServerOverridePreconditionFailed - Failed to apply server override on category '{0}', because physical db or instance '{1}' in server '{2}' is currently not in 'Ready' or 'Deactivated' state.\n\n * 409 ServerDisabled - Server is disabled.\n\n * 409 ManagedInstanceIsBusy - The server '{0}' is currently busy. Please wait a few minutes before trying again.\n\n * 409 ServerQuotaExceeded - Server cannot be added to a subscription because it will exceed quota.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 ConflictingSubscriptionOperation - An operation is currently in progress for the subscription.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 500 OperationTimedOut - The operation timed out and automatically rolled back. Please retry the operation.\n\n * 500 GatewayInternalServerError - The server encountered an unexpected exception.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." + }, + "202": { + "description": "Accepted" + } + }, + "x-ms-long-running-operation": true, + "x-ms-examples": { + "Update managed instance with minimal properties": { + "$ref": "./examples/ManagedInstanceUpdateMin.json" + }, + "Update managed instance with all properties": { + "$ref": "./examples/ManagedInstanceUpdateMax.json" + } + } + } + }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/instancePools/{instancePoolName}/managedInstances": { "get": { "tags": [ @@ -61,9 +404,313 @@ } } } + }, + "/subscriptions/{subscriptionId}/providers/Microsoft.Sql/managedInstances": { + "get": { + "tags": [ + "ManagedInstances" + ], + "description": "Gets a list of all managed instances in the subscription.", + "operationId": "ManagedInstances_List", + "parameters": [ + { + "$ref": "#/parameters/SubscriptionIdParameter" + }, + { + "$ref": "#/parameters/ApiVersionParameter" + } + ], + "responses": { + "200": { + "description": "Successfully retrieved the list of managed instances.", + "schema": { + "$ref": "#/definitions/ManagedInstanceListResult" + } + }, + "default": { + "description": "*** Error Responses: ***" + } + }, + "x-ms-pageable": { + "nextLinkName": "nextLink" + }, + "x-ms-examples": { + "List managed instances": { + "$ref": "./examples/ManagedInstanceList.json" + } + } + } } }, "definitions": { + "MetricDefinitionListResult": { + "description": "A list of metric definition resources.", + "type": "object", + "properties": { + "value": { + "description": "Array of results.", + "type": "array", + "items": { + "$ref": "#/definitions/MetricDefinition" + }, + "readOnly": true + }, + "nextLink": { + "description": "Link to retrieve next page of results.", + "type": "string", + "readOnly": true + } + } + }, + "MetricDefinition": { + "description": "A metric definition resource.", + "type": "object", + "properties": { + "name": { + "$ref": "#/definitions/MetricName", + "description": "Name of the metric.", + "readOnly": true + }, + "unit": { + "description": "The unit of the metric.", + "enum": [ + "Count", + "Bytes", + "Seconds", + "Percent", + "CountPerSecond", + "BytesPerSecond" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "UnitType", + "modelAsString": true + } + }, + "resourceId": { + "description": "The uri of the resource that the metric describes.", + "type": "string", + "readOnly": true + }, + "primaryAggregationType": { + "description": "The primary aggregation type defining how metric values are displayed.", + "enum": [ + "None", + "Average", + "Count", + "Minimum", + "Maximum", + "Total" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "PrimaryAggregationType", + "modelAsString": true + } + }, + "supportedAggregationTypes": { + "description": "The supported aggregation types defining how metric values are displayed.", + "type": "array", + "items": { + "type": "string" + }, + "readOnly": true + }, + "metricAvailabilities": { + "description": "The list of metric availabilities for the metric.", + "type": "array", + "items": { + "$ref": "#/definitions/MetricAvailability" + }, + "readOnly": true + } + } + }, + "MetricName": { + "description": "A managed instance metric name.", + "type": "object", + "properties": { + "value": { + "description": "The name of the database metric.", + "type": "string", + "readOnly": true + }, + "localizedValue": { + "description": "The friendly name of the database metric.", + "type": "string", + "readOnly": true + } + } + }, + "MetricAvailability": { + "description": "A metric availability value.", + "type": "object", + "properties": { + "timeGrain": { + "description": "The granularity of the database metric.", + "enum": [ + "PT5M", + "PT1H", + "P1D" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "TimeGrainType", + "modelAsString": true + } + }, + "retention": { + "description": "The length of retention for the database metric.", + "enum": [ + "P14D" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "RetentionType", + "modelAsString": true + } + } + } + }, + "MetricListResult": { + "description": "A list of metric resources.", + "type": "object", + "properties": { + "value": { + "description": "Array of results.", + "type": "array", + "items": { + "$ref": "#/definitions/Metric" + }, + "readOnly": true + }, + "nextLink": { + "description": "Link to retrieve next page of results.", + "type": "string", + "readOnly": true + } + } + }, + "Metric": { + "description": "A metric resource.", + "type": "object", + "properties": { + "name": { + "$ref": "#/definitions/MetricName", + "description": "The name information for the metric.", + "readOnly": true + }, + "unit": { + "description": "The unit of the metric.", + "enum": [ + "Count", + "Bytes", + "Seconds", + "Percent", + "CountPerSecond", + "BytesPerSecond" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "UnitType", + "modelAsString": true + } + }, + "timeGrain": { + "description": "The time step to be used to summarize the metric values.", + "enum": [ + "PT5M", + "PT1H", + "P1D" + ], + "type": "string", + "readOnly": true, + "x-ms-enum": { + "name": "TimeGrainType", + "modelAsString": true + } + }, + "startTime": { + "description": "The start time for the metric (ISO-8601 format).", + "type": "string", + "readOnly": true + }, + "endTime": { + "description": "The end time for the metric (ISO-8601 format).", + "type": "string", + "readOnly": true + }, + "timeseries": { + "description": "The metric timeseries for the specified time window and timestep.", + "type": "array", + "items": { + "$ref": "#/definitions/MetricTimeseries" + }, + "readOnly": true + } + } + }, + "MetricTimeseries": { + "description": "A metric timeseries.", + "type": "object", + "properties": { + "data": { + "description": "The metric values for the specified time window and timestep.", + "type": "array", + "items": { + "$ref": "#/definitions/MetricValue" + }, + "readOnly": true + } + } + }, + "MetricValue": { + "description": "A metric value.", + "type": "object", + "properties": { + "timeStamp": { + "format": "date-time", + "description": "The metric timestamp (ISO-8601 format).", + "type": "string", + "readOnly": true + }, + "average": { + "format": "double", + "description": "The average value of the metric.", + "type": "number", + "readOnly": true + }, + "minimum": { + "format": "double", + "description": "The min value of the metric.", + "type": "number", + "readOnly": true + }, + "maximum": { + "format": "double", + "description": "The max value of the metric.", + "type": "number", + "readOnly": true + }, + "total": { + "format": "double", + "description": "The total value of the metric.", + "type": "number", + "readOnly": true + }, + "count": { + "format": "int32", + "description": "The number of values for the metric.", + "type": "integer", + "readOnly": true + } + } + }, "ManagedInstanceListResult": { "description": "A list of managed instances.", "type": "object", @@ -83,6 +730,36 @@ } } }, + "Sku": { + "description": "An ARM Resource SKU.", + "required": [ + "name" + ], + "type": "object", + "properties": { + "name": { + "description": "The name of the SKU, typically, a letter + Number code, e.g. P3.", + "type": "string" + }, + "tier": { + "description": "The tier or edition of the particular SKU, e.g. Basic, Premium.", + "type": "string" + }, + "size": { + "description": "Size of the particular SKU", + "type": "string" + }, + "family": { + "description": "If the service has different generations of hardware, for the same SKU, then that can be captured here.", + "type": "string" + }, + "capacity": { + "format": "int32", + "description": "Capacity of the particular SKU.", + "type": "integer" + } + } + }, "ManagedInstanceProperties": { "description": "The properties of a managed instance.", "type": "object", @@ -250,6 +927,28 @@ "x-ms-client-flatten": true } } + }, + "ManagedInstanceUpdate": { + "description": "An update request for an Azure SQL Database managed instance.", + "type": "object", + "properties": { + "sku": { + "$ref": "../../../common/v1/types.json#/definitions/Sku", + "description": "Managed instance sku" + }, + "properties": { + "$ref": "#/definitions/ManagedInstanceProperties", + "description": "Resource properties.", + "x-ms-client-flatten": true + }, + "tags": { + "description": "Resource tags.", + "type": "object", + "additionalProperties": { + "type": "string" + } + } + } } }, "parameters": { From e744411f25bfdb4783f1b3a9721fcfd7b68e031f Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Thu, 20 Jun 2019 09:47:55 -0700 Subject: [PATCH 08/11] Updating managed instances swagger, removing examples not used --- .../ManagedInstancesListMetricsMax.json | 148 ----- .../ManagedInstancesListMetricsMin.json | 556 ------------------ .../2018-06-01-preview/managedInstances.json | 90 ++- 3 files changed, 85 insertions(+), 709 deletions(-) delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMax.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMin.json diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMax.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMax.json deleted file mode 100644 index efcc74487186..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMax.json +++ /dev/null @@ -1,148 +0,0 @@ -{ - "parameters":{ - "subscriptionId":"00000000-1111-2222-3333-444444444444", - "resourceGroupName":"Test1", - "managedInstanceName":"managedInstance", - "metric":"avg_cpu_percent", - "timespan":"2018-03-01T00:00:00Z/2018-03-03T18:00:00Z", - "aggregation":"average", - "interval":"PT5M", - "api-version":"2018-06-01-preview" - }, - "responses":{ - "200":{ - "body":{ - "value":[ - { - "name":{ - "value":"avg_cpu_percent", - "localizedValue":"Average CPU percentage" - }, - "unit":"Percent", - "timeGrain":"PT5M", - "startTime":"3/1/2018 1:00:00 AM", - "endTime":"3/3/2018 7:00:00 PM", - "timeseries":[ - { - "data":[ - { - "timeStamp":"2018-03-02T13:30:01Z", - "average":1.881666, - "minimum":0.13, - "maximum":7.06, - "count":12 - }, - { - "timeStamp":"2018-03-02T13:35:01Z", - "average":0.8755, - "minimum":0.12, - "maximum":4.22, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:40:01Z", - "average":0.4665, - "minimum":0.14, - "maximum":2.31, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:45:01Z", - "average":0.3545, - "minimum":0.13, - "maximum":1.72, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:50:01Z", - "average":0.3505, - "minimum":0.13, - "maximum":1.38, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:55:01Z", - "average":0.3535, - "minimum":0.13, - "maximum":1.39, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:00:01Z", - "average":0.418, - "minimum":0.13, - "maximum":1.54, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:05:01Z", - "average":0.35, - "minimum":0.15, - "maximum":1.44, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:10:01Z", - "average":0.3525, - "minimum":0.14, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:15:01Z", - "average":0.352, - "minimum":0.15, - "maximum":1.56, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:20:01Z", - "average":0.3495, - "minimum":0.16, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:25:01Z", - "average":0.368, - "minimum":0.15, - "maximum":1.31, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:30:01Z", - "average":0.438, - "minimum":0.15, - "maximum":2.69, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:35:01Z", - "average":0.3895, - "minimum":0.16, - "maximum":1.29, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:40:01Z", - "average":0.3515, - "minimum":0.12, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:45:01Z", - "average":0.405263, - "minimum":0.12, - "maximum":2.17, - "count":19 - } - ] - } - ] - } - ] - } - } - } - } \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMin.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMin.json deleted file mode 100644 index 49f4fcbb3dfe..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricsMin.json +++ /dev/null @@ -1,556 +0,0 @@ -{ - "parameters":{ - "subscriptionId":"00000000-1111-2222-3333-444444444444", - "resourceGroupName":"Test1", - "managedInstanceName":"managedInstance", - "api-version":"2018-06-01-preview" - }, - "responses":{ - "200":{ - "body":{ - "value":[ - { - "name":{ - "value":"avg_cpu_percent", - "localizedValue":"Average CPU percentage" - }, - "unit":"Percent", - "timeGrain":"PT5M", - "startTime":"3/1/2018 2:54:05 PM", - "endTime":"3/2/2018 2:54:05 PM", - "timeseries":[ - { - "data":[ - { - "timeStamp":"2018-03-02T13:30:01Z", - "average":1.881666, - "minimum":0.13, - "maximum":7.06, - "count":12 - }, - { - "timeStamp":"2018-03-02T13:35:01Z", - "average":0.8755, - "minimum":0.12, - "maximum":4.22, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:40:01Z", - "average":0.4665, - "minimum":0.14, - "maximum":2.31, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:45:01Z", - "average":0.3545, - "minimum":0.13, - "maximum":1.72, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:50:01Z", - "average":0.3505, - "minimum":0.13, - "maximum":1.38, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:55:01Z", - "average":0.3535, - "minimum":0.13, - "maximum":1.39, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:00:01Z", - "average":0.418, - "minimum":0.13, - "maximum":1.54, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:05:01Z", - "average":0.35, - "minimum":0.15, - "maximum":1.44, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:10:01Z", - "average":0.3525, - "minimum":0.14, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:15:01Z", - "average":0.352, - "minimum":0.15, - "maximum":1.56, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:20:01Z", - "average":0.3495, - "minimum":0.16, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:25:01Z", - "average":0.368, - "minimum":0.15, - "maximum":1.31, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:30:01Z", - "average":0.438, - "minimum":0.15, - "maximum":2.69, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:35:01Z", - "average":0.3895, - "minimum":0.16, - "maximum":1.29, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:40:01Z", - "average":0.3515, - "minimum":0.12, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:45:01Z", - "average":0.402, - "minimum":0.12, - "maximum":2.17, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:50:01Z", - "average":0.47, - "minimum":0.13, - "maximum":2.17, - "count":11 - } - ] - } - ] - }, - { - "name":{ - "value":"virtual_core_count", - "localizedValue":"Virtual core count" - }, - "unit":"Count", - "timeGrain":"PT5M", - "startTime":"3/1/2018 2:54:05 PM", - "endTime":"3/2/2018 2:54:05 PM", - "timeseries":[ - { - "data":[ - { - "timeStamp":"2018-03-02T13:30:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":12 - }, - { - "timeStamp":"2018-03-02T13:35:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:40:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:45:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:50:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:55:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:00:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:05:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:10:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:15:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:20:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:25:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:30:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:35:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:40:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:45:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:50:01Z", - "average":8.0, - "minimum":8.0, - "maximum":8.0, - "count":11 - } - ] - } - ] - }, - { - "name":{ - "value":"reserved_storage_mb", - "localizedValue":"Storage space reserved" - }, - "unit":"Bytes", - "timeGrain":"PT5M", - "startTime":"3/1/2018 2:54:05 PM", - "endTime":"3/2/2018 2:54:05 PM", - "timeseries":[ - { - "data":[ - { - "timeStamp":"2018-03-02T13:30:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":12 - }, - { - "timeStamp":"2018-03-02T13:35:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:40:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:45:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:50:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:55:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:00:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:05:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:10:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:15:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:20:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:25:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:30:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:35:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:40:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:45:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:50:01Z", - "average":32768.0, - "minimum":32768.0, - "maximum":32768.0, - "count":11 - } - ] - } - ] - }, - { - "name":{ - "value":"storage_space_used_mb", - "localizedValue":"Storage space used" - }, - "unit":"Bytes", - "timeGrain":"PT5M", - "startTime":"3/1/2018 2:54:05 PM", - "endTime":"3/2/2018 2:54:05 PM", - "timeseries":[ - { - "data":[ - { - "timeStamp":"2018-03-02T13:30:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":12 - }, - { - "timeStamp":"2018-03-02T13:35:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:40:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:45:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:50:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:55:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:00:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:05:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:10:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:15:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:20:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:25:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:30:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:35:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:40:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:45:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:50:01Z", - "average":230.0, - "minimum":230.0, - "maximum":230.0, - "count":11 - } - ] - } - ] - } - ] - } - } - } -} \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json index 7d8f704a460d..abc89f0443df 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json @@ -730,6 +730,35 @@ } } }, + "ResourceIdentity": { + "description": "Azure Active Directory identity configuration for a resource.", + "type": "object", + "properties": { + "principalId": { + "format": "uuid", + "description": "The Azure Active Directory principal id.", + "type": "string", + "readOnly": true + }, + "type": { + "description": "The identity type. Set this to 'SystemAssigned' in order to automatically create and assign an Azure Active Directory principal for the resource.", + "enum": [ + "SystemAssigned" + ], + "type": "string", + "x-ms-enum": { + "name": "IdentityType", + "modelAsString": true + } + }, + "tenantId": { + "format": "uuid", + "description": "The Azure Active Directory tenant id.", + "type": "string", + "readOnly": true + } + } + }, "Sku": { "description": "An ARM Resource SKU.", "required": [ @@ -897,6 +926,57 @@ } } }, + "Resource": { + "description": "ARM resource.", + "type": "object", + "properties": { + "id": { + "description": "Resource ID.", + "type": "string", + "readOnly": true + }, + "name": { + "description": "Resource name.", + "type": "string", + "readOnly": true + }, + "type": { + "description": "Resource type.", + "type": "string", + "readOnly": true + } + }, + "x-ms-azure-resource": true + }, + "TrackedResource": { + "description": "ARM tracked top level resource.", + "required": [ + "location" + ], + "type": "object", + "allOf": [ + { + "$ref": "#/definitions/Resource" + } + ], + "properties": { + "location": { + "description": "Resource location.", + "type": "string", + "x-ms-mutability": [ + "read", + "create" + ] + }, + "tags": { + "description": "Resource tags.", + "type": "object", + "additionalProperties": { + "type": "string" + } + } + } + }, "ManagedInstance": { "description": "An Azure SQL managed instance.", "required": [ @@ -905,12 +985,12 @@ "type": "object", "allOf": [ { - "$ref": "../../../common/v1/types.json#/definitions/TrackedResource" + "$ref": "#/definitions/TrackedResource" } ], "properties": { "identity": { - "$ref": "../../../common/v1/types.json#/definitions/ResourceIdentity", + "$ref": "#/definitions/ResourceIdentity", "description": "The Azure Active Directory identity of the managed instance.", "x-ms-mutability": [ "read", @@ -918,7 +998,7 @@ ] }, "sku": { - "$ref": "../../../common/v1/types.json#/definitions/Sku", + "$ref": "#/definitions/Sku", "description": "Managed instance SKU. Allowed values for sku.name: GP_Gen4, GP_Gen5, BC_Gen4, BC_Gen5" }, "properties": { @@ -933,7 +1013,7 @@ "type": "object", "properties": { "sku": { - "$ref": "../../../common/v1/types.json#/definitions/Sku", + "$ref": "#/definitions/Sku", "description": "Managed instance sku" }, "properties": { @@ -1047,4 +1127,4 @@ } } } -} +} \ No newline at end of file From 068332877deddeb775f528038e37342b956bedf9 Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Thu, 20 Jun 2019 10:03:32 -0700 Subject: [PATCH 09/11] update to common typed definitions --- .../2018-06-01-preview/managedInstances.json | 98 +------------------ 1 file changed, 5 insertions(+), 93 deletions(-) diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json index abc89f0443df..d4fc80603526 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json @@ -730,65 +730,6 @@ } } }, - "ResourceIdentity": { - "description": "Azure Active Directory identity configuration for a resource.", - "type": "object", - "properties": { - "principalId": { - "format": "uuid", - "description": "The Azure Active Directory principal id.", - "type": "string", - "readOnly": true - }, - "type": { - "description": "The identity type. Set this to 'SystemAssigned' in order to automatically create and assign an Azure Active Directory principal for the resource.", - "enum": [ - "SystemAssigned" - ], - "type": "string", - "x-ms-enum": { - "name": "IdentityType", - "modelAsString": true - } - }, - "tenantId": { - "format": "uuid", - "description": "The Azure Active Directory tenant id.", - "type": "string", - "readOnly": true - } - } - }, - "Sku": { - "description": "An ARM Resource SKU.", - "required": [ - "name" - ], - "type": "object", - "properties": { - "name": { - "description": "The name of the SKU, typically, a letter + Number code, e.g. P3.", - "type": "string" - }, - "tier": { - "description": "The tier or edition of the particular SKU, e.g. Basic, Premium.", - "type": "string" - }, - "size": { - "description": "Size of the particular SKU", - "type": "string" - }, - "family": { - "description": "If the service has different generations of hardware, for the same SKU, then that can be captured here.", - "type": "string" - }, - "capacity": { - "format": "int32", - "description": "Capacity of the particular SKU.", - "type": "integer" - } - } - }, "ManagedInstanceProperties": { "description": "The properties of a managed instance.", "type": "object", @@ -948,35 +889,6 @@ }, "x-ms-azure-resource": true }, - "TrackedResource": { - "description": "ARM tracked top level resource.", - "required": [ - "location" - ], - "type": "object", - "allOf": [ - { - "$ref": "#/definitions/Resource" - } - ], - "properties": { - "location": { - "description": "Resource location.", - "type": "string", - "x-ms-mutability": [ - "read", - "create" - ] - }, - "tags": { - "description": "Resource tags.", - "type": "object", - "additionalProperties": { - "type": "string" - } - } - } - }, "ManagedInstance": { "description": "An Azure SQL managed instance.", "required": [ @@ -985,12 +897,12 @@ "type": "object", "allOf": [ { - "$ref": "#/definitions/TrackedResource" + "$ref": "../../../common/v1/types.json#/definitions/TrackedResource" } ], "properties": { "identity": { - "$ref": "#/definitions/ResourceIdentity", + "$ref": "../../../common/v1/types.json#/definitions/ResourceIdentity", "description": "The Azure Active Directory identity of the managed instance.", "x-ms-mutability": [ "read", @@ -998,7 +910,7 @@ ] }, "sku": { - "$ref": "#/definitions/Sku", + "$ref": "../../../common/v1/types.json#/definitions/Sku", "description": "Managed instance SKU. Allowed values for sku.name: GP_Gen4, GP_Gen5, BC_Gen4, BC_Gen5" }, "properties": { @@ -1013,7 +925,7 @@ "type": "object", "properties": { "sku": { - "$ref": "#/definitions/Sku", + "$ref": "../../../common/v1/types.json#/definitions/Sku", "description": "Managed instance sku" }, "properties": { @@ -1127,4 +1039,4 @@ } } } -} \ No newline at end of file +} From 163211e5590c31b6bd69ee68be5e997aecbbb0af Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Thu, 20 Jun 2019 11:07:37 -0700 Subject: [PATCH 10/11] Fix readme.md, no duplicate apis for managedInstances --- specification/sql/resource-manager/readme.md | 3 --- 1 file changed, 3 deletions(-) diff --git a/specification/sql/resource-manager/readme.md b/specification/sql/resource-manager/readme.md index dc8b2f8389a0..0988ac15e0cd 100644 --- a/specification/sql/resource-manager/readme.md +++ b/specification/sql/resource-manager/readme.md @@ -73,7 +73,6 @@ input-file: - Microsoft.Sql/preview/2015-05-01-preview/databaseAutomaticTuning.json - Microsoft.Sql/preview/2015-05-01-preview/encryptionProtectors.json - Microsoft.Sql/preview/2015-05-01-preview/failoverGroups.json -- Microsoft.Sql/preview/2015-05-01-preview/managedInstances.json - Microsoft.Sql/preview/2015-05-01-preview/operations.json - Microsoft.Sql/preview/2015-05-01-preview/serverKeys.json - Microsoft.Sql/preview/2015-05-01-preview/servers.json @@ -167,7 +166,6 @@ input-file: - Microsoft.Sql/preview/2015-05-01-preview/databaseAutomaticTuning.json - Microsoft.Sql/preview/2015-05-01-preview/encryptionProtectors.json - Microsoft.Sql/preview/2015-05-01-preview/failoverGroups.json -- Microsoft.Sql/preview/2015-05-01-preview/managedInstances.json - Microsoft.Sql/preview/2015-05-01-preview/operations.json - Microsoft.Sql/preview/2015-05-01-preview/serverKeys.json - Microsoft.Sql/preview/2015-05-01-preview/servers.json @@ -253,7 +251,6 @@ input-file: - Microsoft.Sql/preview/2015-05-01-preview/databaseAutomaticTuning.json - Microsoft.Sql/preview/2015-05-01-preview/encryptionProtectors.json - Microsoft.Sql/preview/2015-05-01-preview/failoverGroups.json -- Microsoft.Sql/preview/2015-05-01-preview/managedInstances.json - Microsoft.Sql/preview/2015-05-01-preview/operations.json - Microsoft.Sql/preview/2015-05-01-preview/serverKeys.json - Microsoft.Sql/preview/2015-05-01-preview/servers.json From f9c8641259eb7e807495304c2d0bf4eff387c85b Mon Sep 17 00:00:00 2001 From: John Paul Kee Date: Thu, 20 Jun 2019 12:19:04 -0700 Subject: [PATCH 11/11] remove managed instance metrics from swagger --- ...ManagedInstancesListMetricDefinitions.json | 132 ------ .../examples/ManagedInstancesListMetrics.json | 148 ------- .../2018-06-01-preview/managedInstances.json | 402 ------------------ 3 files changed, 682 deletions(-) delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json delete mode 100644 specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json deleted file mode 100644 index 9e7825a8cd9b..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetricDefinitions.json +++ /dev/null @@ -1,132 +0,0 @@ -{ - "parameters":{ - "subscriptionId":"00000000-1111-2222-3333-444444444444", - "resourceGroupName":"Test1", - "managedInstanceName":"managedInstance", - "api-version":"2018-06-01-preview" - }, - "responses":{ - "200":{ - "body":{ - "value":[ - { - "name":{ - "value":"reserved_storage_mb", - "localizedValue":"Storage space reserved" - }, - "unit":"Bytes", - "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", - "primaryAggregationType":"Average", - "supportedAggregationTypes":[ - "Average", - "Minimum", - "Maximum", - "Count" - ], - "metricAvailabilities":[ - { - "timeGrain":"PT5M", - "retention":"P14D" - }, - { - "timeGrain":"PT1H", - "retention":"P14D" - }, - { - "timeGrain":"P1D", - "retention":"P14D" - } - ] - }, - { - "name":{ - "value":"storage_space_used_mb", - "localizedValue":"Storage space used" - }, - "unit":"Bytes", - "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", - "primaryAggregationType":"Average", - "supportedAggregationTypes":[ - "Average", - "Minimum", - "Maximum", - "Count" - ], - "metricAvailabilities":[ - { - "timeGrain":"PT5M", - "retention":"P14D" - }, - { - "timeGrain":"PT1H", - "retention":"P14D" - }, - { - "timeGrain":"P1D", - "retention":"P14D" - } - ] - }, - { - "name":{ - "value":"avg_cpu_percent", - "localizedValue":"Average CPU percentage" - }, - "unit":"Percent", - "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", - "primaryAggregationType":"Average", - "supportedAggregationTypes":[ - "Average", - "Minimum", - "Maximum", - "Count" - ], - "metricAvailabilities":[ - { - "timeGrain":"PT5M", - "retention":"P14D" - }, - { - "timeGrain":"PT1H", - "retention":"P14D" - }, - { - "timeGrain":"P1D", - "retention":"P14D" - } - ] - }, - { - "name":{ - "value":"virtual_core_count", - "localizedValue":"Virtual core count" - }, - "unit":"Count", - "resourceId":"/subscriptions/932e64b2-e71f-4873-8b1c-6cb6b41768c7/resourceGroups/testrg/providers/Microsoft.Sql/managedInstances/testcl", - "primaryAggregationType":"Average", - "supportedAggregationTypes":[ - "Average", - "Minimum", - "Maximum", - "Count" - ], - "metricAvailabilities":[ - { - "timeGrain":"PT5M", - "retention":"P14D" - }, - { - "timeGrain":"PT1H", - "retention":"P14D" - }, - { - "timeGrain":"P1D", - "retention":"P14D" - } - ] - } - ] - } - } - } - } \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json deleted file mode 100644 index efcc74487186..000000000000 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/examples/ManagedInstancesListMetrics.json +++ /dev/null @@ -1,148 +0,0 @@ -{ - "parameters":{ - "subscriptionId":"00000000-1111-2222-3333-444444444444", - "resourceGroupName":"Test1", - "managedInstanceName":"managedInstance", - "metric":"avg_cpu_percent", - "timespan":"2018-03-01T00:00:00Z/2018-03-03T18:00:00Z", - "aggregation":"average", - "interval":"PT5M", - "api-version":"2018-06-01-preview" - }, - "responses":{ - "200":{ - "body":{ - "value":[ - { - "name":{ - "value":"avg_cpu_percent", - "localizedValue":"Average CPU percentage" - }, - "unit":"Percent", - "timeGrain":"PT5M", - "startTime":"3/1/2018 1:00:00 AM", - "endTime":"3/3/2018 7:00:00 PM", - "timeseries":[ - { - "data":[ - { - "timeStamp":"2018-03-02T13:30:01Z", - "average":1.881666, - "minimum":0.13, - "maximum":7.06, - "count":12 - }, - { - "timeStamp":"2018-03-02T13:35:01Z", - "average":0.8755, - "minimum":0.12, - "maximum":4.22, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:40:01Z", - "average":0.4665, - "minimum":0.14, - "maximum":2.31, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:45:01Z", - "average":0.3545, - "minimum":0.13, - "maximum":1.72, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:50:01Z", - "average":0.3505, - "minimum":0.13, - "maximum":1.38, - "count":20 - }, - { - "timeStamp":"2018-03-02T13:55:01Z", - "average":0.3535, - "minimum":0.13, - "maximum":1.39, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:00:01Z", - "average":0.418, - "minimum":0.13, - "maximum":1.54, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:05:01Z", - "average":0.35, - "minimum":0.15, - "maximum":1.44, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:10:01Z", - "average":0.3525, - "minimum":0.14, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:15:01Z", - "average":0.352, - "minimum":0.15, - "maximum":1.56, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:20:01Z", - "average":0.3495, - "minimum":0.16, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:25:01Z", - "average":0.368, - "minimum":0.15, - "maximum":1.31, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:30:01Z", - "average":0.438, - "minimum":0.15, - "maximum":2.69, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:35:01Z", - "average":0.3895, - "minimum":0.16, - "maximum":1.29, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:40:01Z", - "average":0.3515, - "minimum":0.12, - "maximum":1.41, - "count":20 - }, - { - "timeStamp":"2018-03-02T14:45:01Z", - "average":0.405263, - "minimum":0.12, - "maximum":2.17, - "count":19 - } - ] - } - ] - } - ] - } - } - } - } \ No newline at end of file diff --git a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json index d4fc80603526..4539d772bff7 100644 --- a/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json +++ b/specification/sql/resource-manager/Microsoft.Sql/preview/2018-06-01-preview/managedInstances.json @@ -16,118 +16,6 @@ "application/json" ], "paths": { - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/metricDefinitions": { - "get": { - "tags": [ - "ManagedInstances" - ], - "description": "Gets a list of managed instance metric definitions.", - "operationId": "ManagedInstances_ListMetricDefinitions", - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupParameter" - }, - { - "$ref": "#/parameters/ManagedInstanceNameParameter" - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully retrieved the list of metric definitions for managed instance.", - "schema": { - "$ref": "#/definitions/MetricDefinitionListResult" - } - }, - "default": { - "description": "*** Error Responses: ***\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 404 ServerNotFound - The requested server was not found.\n\n * 405 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "List metric definitions by managed instance": { - "$ref": "./examples/ManagedInstancesListMetricDefinitions.json" - } - } - } - }, - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances/{managedInstanceName}/metrics": { - "get": { - "tags": [ - "ManagedInstances" - ], - "description": "Gets a list of managed instance metrics.", - "operationId": "ManagedInstances_ListMetrics", - "parameters": [ - { - "$ref": "#/parameters/ResourceGroupParameter" - }, - { - "$ref": "#/parameters/ManagedInstanceNameParameter" - }, - { - "name": "metric", - "in": "query", - "description": "Name of the metrics to get.", - "required": false, - "type": "string" - }, - { - "name": "timespan", - "in": "query", - "description": "The timespan for the metric.", - "required": false, - "type": "string" - }, - { - "name": "aggregation", - "in": "query", - "description": "The aggregation type to use.", - "required": false, - "type": "string" - }, - { - "name": "interval", - "in": "query", - "description": "The time step to be used to summarize the metric values.", - "required": false, - "type": "string" - }, - { - "$ref": "#/parameters/SubscriptionIdParameter" - }, - { - "$ref": "#/parameters/ApiVersionParameter" - } - ], - "responses": { - "200": { - "description": "Successfully retrieved the list of databases.", - "schema": { - "$ref": "#/definitions/MetricListResult" - } - }, - "default": { - "description": "*** Error Responses: ***\n\n * 400 InvalidParameterValue - An invalid value was given to a parameter.\n\n * 404 ServerNotFound - The requested server was not found.\n\n * 405 ManagementServiceFeatureDisabled - User attempted to use a feature which is disabled.\n\n * 429 SubscriptionTooManyCreateUpdateRequests - Requests beyond max requests that can be processed by available resources.\n\n * 429 SubscriptionTooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 503 TooManyRequests - Requests beyond max requests that can be processed by available resources.\n\n * 504 RequestTimeout - Service request exceeded the allowed timeout." - } - }, - "x-ms-pageable": { - "nextLinkName": "nextLink" - }, - "x-ms-examples": { - "List metrics by managed instance": { - "$ref": "./examples/ManagedInstancesListMetrics.json" - } - } - } - }, "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Sql/managedInstances": { "get": { "tags": [ @@ -443,274 +331,6 @@ } }, "definitions": { - "MetricDefinitionListResult": { - "description": "A list of metric definition resources.", - "type": "object", - "properties": { - "value": { - "description": "Array of results.", - "type": "array", - "items": { - "$ref": "#/definitions/MetricDefinition" - }, - "readOnly": true - }, - "nextLink": { - "description": "Link to retrieve next page of results.", - "type": "string", - "readOnly": true - } - } - }, - "MetricDefinition": { - "description": "A metric definition resource.", - "type": "object", - "properties": { - "name": { - "$ref": "#/definitions/MetricName", - "description": "Name of the metric.", - "readOnly": true - }, - "unit": { - "description": "The unit of the metric.", - "enum": [ - "Count", - "Bytes", - "Seconds", - "Percent", - "CountPerSecond", - "BytesPerSecond" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "UnitType", - "modelAsString": true - } - }, - "resourceId": { - "description": "The uri of the resource that the metric describes.", - "type": "string", - "readOnly": true - }, - "primaryAggregationType": { - "description": "The primary aggregation type defining how metric values are displayed.", - "enum": [ - "None", - "Average", - "Count", - "Minimum", - "Maximum", - "Total" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "PrimaryAggregationType", - "modelAsString": true - } - }, - "supportedAggregationTypes": { - "description": "The supported aggregation types defining how metric values are displayed.", - "type": "array", - "items": { - "type": "string" - }, - "readOnly": true - }, - "metricAvailabilities": { - "description": "The list of metric availabilities for the metric.", - "type": "array", - "items": { - "$ref": "#/definitions/MetricAvailability" - }, - "readOnly": true - } - } - }, - "MetricName": { - "description": "A managed instance metric name.", - "type": "object", - "properties": { - "value": { - "description": "The name of the database metric.", - "type": "string", - "readOnly": true - }, - "localizedValue": { - "description": "The friendly name of the database metric.", - "type": "string", - "readOnly": true - } - } - }, - "MetricAvailability": { - "description": "A metric availability value.", - "type": "object", - "properties": { - "timeGrain": { - "description": "The granularity of the database metric.", - "enum": [ - "PT5M", - "PT1H", - "P1D" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "TimeGrainType", - "modelAsString": true - } - }, - "retention": { - "description": "The length of retention for the database metric.", - "enum": [ - "P14D" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "RetentionType", - "modelAsString": true - } - } - } - }, - "MetricListResult": { - "description": "A list of metric resources.", - "type": "object", - "properties": { - "value": { - "description": "Array of results.", - "type": "array", - "items": { - "$ref": "#/definitions/Metric" - }, - "readOnly": true - }, - "nextLink": { - "description": "Link to retrieve next page of results.", - "type": "string", - "readOnly": true - } - } - }, - "Metric": { - "description": "A metric resource.", - "type": "object", - "properties": { - "name": { - "$ref": "#/definitions/MetricName", - "description": "The name information for the metric.", - "readOnly": true - }, - "unit": { - "description": "The unit of the metric.", - "enum": [ - "Count", - "Bytes", - "Seconds", - "Percent", - "CountPerSecond", - "BytesPerSecond" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "UnitType", - "modelAsString": true - } - }, - "timeGrain": { - "description": "The time step to be used to summarize the metric values.", - "enum": [ - "PT5M", - "PT1H", - "P1D" - ], - "type": "string", - "readOnly": true, - "x-ms-enum": { - "name": "TimeGrainType", - "modelAsString": true - } - }, - "startTime": { - "description": "The start time for the metric (ISO-8601 format).", - "type": "string", - "readOnly": true - }, - "endTime": { - "description": "The end time for the metric (ISO-8601 format).", - "type": "string", - "readOnly": true - }, - "timeseries": { - "description": "The metric timeseries for the specified time window and timestep.", - "type": "array", - "items": { - "$ref": "#/definitions/MetricTimeseries" - }, - "readOnly": true - } - } - }, - "MetricTimeseries": { - "description": "A metric timeseries.", - "type": "object", - "properties": { - "data": { - "description": "The metric values for the specified time window and timestep.", - "type": "array", - "items": { - "$ref": "#/definitions/MetricValue" - }, - "readOnly": true - } - } - }, - "MetricValue": { - "description": "A metric value.", - "type": "object", - "properties": { - "timeStamp": { - "format": "date-time", - "description": "The metric timestamp (ISO-8601 format).", - "type": "string", - "readOnly": true - }, - "average": { - "format": "double", - "description": "The average value of the metric.", - "type": "number", - "readOnly": true - }, - "minimum": { - "format": "double", - "description": "The min value of the metric.", - "type": "number", - "readOnly": true - }, - "maximum": { - "format": "double", - "description": "The max value of the metric.", - "type": "number", - "readOnly": true - }, - "total": { - "format": "double", - "description": "The total value of the metric.", - "type": "number", - "readOnly": true - }, - "count": { - "format": "int32", - "description": "The number of values for the metric.", - "type": "integer", - "readOnly": true - } - } - }, "ManagedInstanceListResult": { "description": "A list of managed instances.", "type": "object", @@ -867,28 +487,6 @@ } } }, - "Resource": { - "description": "ARM resource.", - "type": "object", - "properties": { - "id": { - "description": "Resource ID.", - "type": "string", - "readOnly": true - }, - "name": { - "description": "Resource name.", - "type": "string", - "readOnly": true - }, - "type": { - "description": "Resource type.", - "type": "string", - "readOnly": true - } - }, - "x-ms-azure-resource": true - }, "ManagedInstance": { "description": "An Azure SQL managed instance.", "required": [