Clusters - Update
Updates an existing cluster. The request body can contain one or several properties from the cluster definition.
PATCH https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/{clusterName}?api-version=2023-03-02-preview
URI Parameters
| Name | In | Required | Type | Description |
|---|---|---|---|---|
|
cluster
|
path | True |
string minLength: 3maxLength: 40 pattern: ^(?![0-9]+$)(?!-)[a-z0-9-]{3,40}(? |
The name of the cluster. |
|
resource
|
path | True |
string minLength: 1maxLength: 90 |
The name of the resource group. The name is case insensitive. |
|
subscription
|
path | True |
string (uuid) |
The ID of the target subscription. The value must be an UUID. |
|
api-version
|
query | True |
string minLength: 1 |
The API version to use for this operation. |
Request Body
| Name | Type | Description |
|---|---|---|
| identity |
Describes the identity of the cluster. |
|
| properties.administratorLoginPassword |
string (password) |
The password of the administrator login. Each cluster is created with pre-defined administrative role called ‘citus’. |
| properties.citusVersion |
string |
The Citus extension version on all cluster servers. |
| properties.coordinatorEnablePublicIpAccess |
boolean |
If public access is enabled on coordinator. |
| properties.coordinatorServerEdition |
string |
The edition of the coordinator (default: GeneralPurpose). |
| properties.coordinatorStorageQuotaInMb |
integer (int32) |
The storage of the coordinator in MB. |
| properties.coordinatorVCores |
integer (int32) |
The vCores count of the coordinator (max: 96). |
| properties.enableHa |
boolean |
If high availability (HA) is enabled or not for the cluster. |
| properties.enableShardsOnCoordinator |
boolean |
If distributed tables are placed on coordinator or not. Should be set to 'true' on single node clusters. Requires shard rebalancing after value is changed. |
| properties.maintenanceWindow |
Maintenance window of a cluster. |
|
| properties.nodeCount |
integer (int32) |
Worker node count of the cluster. When node count is 0, it represents a single node configuration with the ability to create distributed tables on that node. 2 or more worker nodes represent multi-node configuration. Node count value cannot be 1. |
| properties.nodeServerEdition |
string |
The edition of a node (default: MemoryOptimized). |
| properties.nodeStorageQuotaInMb |
integer (int32) |
The storage in MB on each worker node. |
| properties.nodeVCores |
integer (int32) |
The compute in vCores on each worker node (max: 104). |
| properties.postgresqlVersion |
string |
The major PostgreSQL version on all cluster servers. |
| properties.preferredPrimaryZone |
string |
Preferred primary availability zone (AZ) for all cluster servers. |
| tags |
object |
Application-specific metadata in the form of key-value pairs. |
Responses
| Name | Type | Description |
|---|---|---|
| 200 OK |
Azure operation completed successfully. |
|
| 202 Accepted |
The request has been accepted for processing, but processing has not yet completed. Headers
|
|
| Other Status Codes |
An unexpected error response. |
Security
azure_auth
Azure Active Directory OAuth2 Flow.
Type:
oauth2
Flow:
implicit
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize
Scopes
| Name | Description |
|---|---|
| user_impersonation | impersonate your user account |
Examples
| Scale compute up or down |
| Scale out: Add new worker nodes |
| Scale up storage |
| Update multiple configuration settings of the cluster |
| Update or define maintenance window |
Scale compute up or down
Sample request
PATCH https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster?api-version=2023-03-02-preview
{
"properties": {
"nodeVCores": 16
}
}
Sample response
{
"name": "testcluster",
"type": "Microsoft.DBforPostgreSQL/serverGroupsv2",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster",
"location": "westus",
"properties": {
"aadAuthEnabled": "disabled",
"administratorLogin": "citus",
"citusVersion": "11.1",
"coordinatorEnablePublicIpAccess": true,
"coordinatorServerEdition": "GeneralPurpose",
"coordinatorStorageQuotaInMb": 2097152,
"coordinatorVCores": 16,
"dataEncryption": {
"type": "SystemManaged"
},
"databaseName": "citus",
"earliestRestoreTime": "2020-09-14T00:00:37.467Z",
"enableHa": false,
"enableShardsOnCoordinator": false,
"maintenanceWindow": {
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"nodeCount": 3,
"nodeEnablePublicIpAccess": false,
"nodeServerEdition": "MemoryOptimized",
"nodeStorageQuotaInMb": 2097152,
"nodeVCores": 16,
"passwordEnabled": "enabled",
"postgresqlVersion": "14",
"preferredPrimaryZone": "1",
"privateEndpointConnections": [],
"provisioningState": "Succeeded",
"readReplicas": [],
"serverNames": [
{
"name": "testcluster1-c",
"fullyQualifiedDomainName": "testcluster1-c.postgres.database.azure.com"
},
{
"name": "testcluster1-w0",
"fullyQualifiedDomainName": "testcluster1-w0.postgres.database.azure.com"
},
{
"name": "testcluster1-w1",
"fullyQualifiedDomainName": "testcluster1-w1.postgres.database.azure.com"
},
{
"name": "testcluster1-w2",
"fullyQualifiedDomainName": "testcluster1-w2.postgres.database.azure.com"
}
],
"sourceResourceId": null,
"state": "Ready"
},
"systemData": {
"createdAt": "2020-01-01T17:18:19.1234567Z",
"createdBy": "user1",
"createdByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User"
}
}
Azure-AsyncOperation: https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/providers/Microsoft.DBforPostgreSQL/locations/westus/azureAsyncOperation/e276a03a-1770-4549-86f5-0edffae8997c?api-version=2023-03-02-preview
Location: https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/providers/Microsoft.DBforPostgreSQL/locations/westus/operationResults/e276a03a-1770-4549-86f5-0edffae8997c?api-version=2023-03-02-preview
{
"name": "testcluster",
"type": "Microsoft.DBforPostgreSQL/serverGroupsv2",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster",
"location": "westus",
"properties": {
"aadAuthEnabled": "disabled",
"administratorLogin": "citus",
"citusVersion": "11.1",
"coordinatorEnablePublicIpAccess": true,
"coordinatorServerEdition": "GeneralPurpose",
"coordinatorStorageQuotaInMb": 2097152,
"coordinatorVCores": 16,
"dataEncryption": {
"type": "SystemManaged"
},
"databaseName": "citus",
"earliestRestoreTime": "2020-09-14T00:00:37.467Z",
"enableHa": false,
"enableShardsOnCoordinator": false,
"maintenanceWindow": {
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"nodeCount": 3,
"nodeEnablePublicIpAccess": false,
"nodeServerEdition": "MemoryOptimized",
"nodeStorageQuotaInMb": 2097152,
"nodeVCores": 16,
"passwordEnabled": "enabled",
"postgresqlVersion": "14",
"preferredPrimaryZone": "1",
"privateEndpointConnections": [],
"provisioningState": "Succeeded",
"readReplicas": [],
"serverNames": [
{
"name": "testcluster1-c",
"fullyQualifiedDomainName": "testcluster1-c.postgres.database.azure.com"
},
{
"name": "testcluster1-w0",
"fullyQualifiedDomainName": "testcluster1-w0.postgres.database.azure.com"
},
{
"name": "testcluster1-w1",
"fullyQualifiedDomainName": "testcluster1-w1.postgres.database.azure.com"
},
{
"name": "testcluster1-w2",
"fullyQualifiedDomainName": "testcluster1-w2.postgres.database.azure.com"
}
],
"sourceResourceId": null,
"state": "Ready"
},
"systemData": {
"createdAt": "2020-01-01T17:18:19.1234567Z",
"createdBy": "user1",
"createdByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User"
}
}
Scale out: Add new worker nodes
Sample request
PATCH https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster?api-version=2023-03-02-preview
{
"properties": {
"nodeCount": 2
}
}
Sample response
{
"name": "testcluster",
"type": "Microsoft.DBforPostgreSQL/serverGroupsv2",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster",
"location": "westus",
"properties": {
"aadAuthEnabled": "disabled",
"citusVersion": "11.1",
"coordinatorEnablePublicIpAccess": true,
"coordinatorServerEdition": "GeneralPurpose",
"coordinatorStorageQuotaInMb": 524288,
"coordinatorVCores": 4,
"dataEncryption": {
"type": "SystemManaged"
},
"databaseName": "citus",
"earliestRestoreTime": null,
"enableGeoBackup": false,
"enableHa": true,
"enableShardsOnCoordinator": false,
"maintenanceWindow": {
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"nodeCount": 2,
"nodeEnablePublicIpAccess": false,
"nodeServerEdition": "MemoryOptimized",
"nodeStorageQuotaInMb": 524288,
"nodeVCores": 8,
"passwordEnabled": "enabled",
"postgresqlVersion": "15",
"preferredPrimaryZone": "1",
"privateEndpointConnections": [],
"provisioningState": "Provisioning",
"readReplicas": [],
"serverNames": [
{
"name": "testcluster-c",
"fullyQualifiedDomainName": "c.testcluster.postgres.database.azure.com"
},
{
"name": "testcluster-w0",
"fullyQualifiedDomainName": "w0.testcluster.postgres.database.azure.com"
},
{
"name": "testcluster-w1",
"fullyQualifiedDomainName": "w1.testcluster.postgres.database.azure.com"
}
],
"sourceResourceId": null,
"state": "Provisioning"
},
"systemData": {
"createdAt": "2020-01-01T17:18:19.1234567Z",
"createdBy": "user1",
"createdByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User"
}
}
Azure-AsyncOperation: https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/providers/Microsoft.DBforPostgreSQL/locations/westus/azureAsyncOperation/e276a03a-1770-4549-86f5-0edffae8997c?api-version=2023-03-02-preview
Location: https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/providers/Microsoft.DBforPostgreSQL/locations/westus/operationResults/e276a03a-1770-4549-86f5-0edffae8997c?api-version=2023-03-02-preview
{
"name": "testcluster",
"type": "Microsoft.DBforPostgreSQL/serverGroupsv2",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster",
"location": "westus",
"properties": {
"aadAuthEnabled": "disabled",
"citusVersion": "11.1",
"coordinatorEnablePublicIpAccess": true,
"coordinatorServerEdition": "GeneralPurpose",
"coordinatorStorageQuotaInMb": 524288,
"coordinatorVCores": 4,
"dataEncryption": {
"type": "SystemManaged"
},
"databaseName": "citus",
"earliestRestoreTime": null,
"enableGeoBackup": false,
"enableHa": true,
"enableShardsOnCoordinator": false,
"maintenanceWindow": {
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"nodeCount": 2,
"nodeEnablePublicIpAccess": false,
"nodeServerEdition": "MemoryOptimized",
"nodeStorageQuotaInMb": 524288,
"nodeVCores": 8,
"passwordEnabled": "enabled",
"postgresqlVersion": "15",
"preferredPrimaryZone": "1",
"privateEndpointConnections": [],
"provisioningState": "Provisioning",
"readReplicas": [],
"serverNames": [
{
"name": "testcluster-c",
"fullyQualifiedDomainName": "c.testcluster.postgres.database.azure.com"
},
{
"name": "testcluster-w0",
"fullyQualifiedDomainName": "w0.testcluster.postgres.database.azure.com"
},
{
"name": "testcluster-w1",
"fullyQualifiedDomainName": "w1.testcluster.postgres.database.azure.com"
}
],
"sourceResourceId": null,
"state": "Provisioning"
},
"systemData": {
"createdAt": "2020-01-01T17:18:19.1234567Z",
"createdBy": "user1",
"createdByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User"
}
}
Scale up storage
Sample request
PATCH https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster?api-version=2023-03-02-preview
{
"properties": {
"nodeStorageQuotaInMb": 2097152
}
}
Sample response
{
"name": "testcluster",
"type": "Microsoft.DBforPostgreSQL/serverGroupsv2",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster",
"location": "westus",
"properties": {
"aadAuthEnabled": "disabled",
"administratorLogin": "citus",
"citusVersion": "11.1",
"coordinatorEnablePublicIpAccess": true,
"coordinatorServerEdition": "GeneralPurpose",
"coordinatorStorageQuotaInMb": 2097152,
"coordinatorVCores": 16,
"dataEncryption": {
"type": "SystemManaged"
},
"databaseName": "citus",
"earliestRestoreTime": "2020-09-14T00:00:37.467Z",
"enableHa": false,
"enableShardsOnCoordinator": false,
"maintenanceWindow": {
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"nodeCount": 3,
"nodeEnablePublicIpAccess": false,
"nodeServerEdition": "MemoryOptimized",
"nodeStorageQuotaInMb": 2097152,
"nodeVCores": 16,
"passwordEnabled": "enabled",
"postgresqlVersion": "14",
"preferredPrimaryZone": "1",
"privateEndpointConnections": [],
"provisioningState": "Succeeded",
"readReplicas": [],
"serverNames": [
{
"name": "testcluster1-c",
"fullyQualifiedDomainName": "testcluster1-c.postgres.database.azure.com"
},
{
"name": "testcluster1-w0",
"fullyQualifiedDomainName": "testcluster1-w0.postgres.database.azure.com"
},
{
"name": "testcluster1-w1",
"fullyQualifiedDomainName": "testcluster1-w1.postgres.database.azure.com"
},
{
"name": "testcluster1-w2",
"fullyQualifiedDomainName": "testcluster1-w2.postgres.database.azure.com"
}
],
"sourceResourceId": null,
"state": "Ready"
},
"systemData": {
"createdAt": "2020-01-01T17:18:19.1234567Z",
"createdBy": "user1",
"createdByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User"
}
}
Azure-AsyncOperation: https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/providers/Microsoft.DBforPostgreSQL/locations/westus/azureAsyncOperation/e276a03a-1770-4549-86f5-0edffae8997c?api-version=2023-03-02-preview
Location: https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/providers/Microsoft.DBforPostgreSQL/locations/westus/operationResults/e276a03a-1770-4549-86f5-0edffae8997c?api-version=2023-03-02-preview
{
"name": "testcluster",
"type": "Microsoft.DBforPostgreSQL/serverGroupsv2",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster",
"location": "westus",
"properties": {
"aadAuthEnabled": "disabled",
"administratorLogin": "citus",
"citusVersion": "11.1",
"coordinatorEnablePublicIpAccess": true,
"coordinatorServerEdition": "GeneralPurpose",
"coordinatorStorageQuotaInMb": 2097152,
"coordinatorVCores": 16,
"dataEncryption": {
"type": "SystemManaged"
},
"databaseName": "citus",
"earliestRestoreTime": "2020-09-14T00:00:37.467Z",
"enableHa": false,
"enableShardsOnCoordinator": false,
"maintenanceWindow": {
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"nodeCount": 3,
"nodeEnablePublicIpAccess": false,
"nodeServerEdition": "MemoryOptimized",
"nodeStorageQuotaInMb": 2097152,
"nodeVCores": 16,
"passwordEnabled": "enabled",
"postgresqlVersion": "14",
"preferredPrimaryZone": "1",
"privateEndpointConnections": [],
"provisioningState": "Succeeded",
"readReplicas": [],
"serverNames": [
{
"name": "testcluster1-c",
"fullyQualifiedDomainName": "testcluster1-c.postgres.database.azure.com"
},
{
"name": "testcluster1-w0",
"fullyQualifiedDomainName": "testcluster1-w0.postgres.database.azure.com"
},
{
"name": "testcluster1-w1",
"fullyQualifiedDomainName": "testcluster1-w1.postgres.database.azure.com"
},
{
"name": "testcluster1-w2",
"fullyQualifiedDomainName": "testcluster1-w2.postgres.database.azure.com"
}
],
"sourceResourceId": null,
"state": "Ready"
},
"systemData": {
"createdAt": "2020-01-01T17:18:19.1234567Z",
"createdBy": "user1",
"createdByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User"
}
}
Update multiple configuration settings of the cluster
Sample request
PATCH https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster?api-version=2023-03-02-preview
{
"properties": {
"administratorLoginPassword": "newpassword",
"coordinatorVCores": 16,
"nodeCount": 4,
"nodeVCores": 16
}
}
Sample response
{
"name": "testcluster1",
"type": "Microsoft.DBforPostgreSQL/serverGroupsv2",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster1",
"location": "westus",
"properties": {
"aadAuthEnabled": "disabled",
"administratorLogin": "citus",
"citusVersion": "11.1",
"coordinatorEnablePublicIpAccess": true,
"coordinatorServerEdition": "GeneralPurpose",
"coordinatorStorageQuotaInMb": 2097152,
"coordinatorVCores": 16,
"dataEncryption": {
"type": "SystemManaged"
},
"databaseName": "citus",
"earliestRestoreTime": "2020-09-14T00:00:37.467Z",
"enableHa": false,
"enableShardsOnCoordinator": false,
"maintenanceWindow": {
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"nodeCount": 4,
"nodeEnablePublicIpAccess": false,
"nodeServerEdition": "MemoryOptimized",
"nodeStorageQuotaInMb": 2097152,
"nodeVCores": 16,
"passwordEnabled": "enabled",
"postgresqlVersion": "14",
"preferredPrimaryZone": "1",
"privateEndpointConnections": [],
"provisioningState": "Succeeded",
"readReplicas": [
"/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBForPostgreSQL/serverGroupsv2/testreadreplica-01",
"/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBForPostgreSQL/serverGroupsv2/testreadreplica-02"
],
"serverNames": [
{
"name": "testcluster1-c",
"fullyQualifiedDomainName": "testcluster1-c.postgres.database.azure.com"
},
{
"name": "testcluster1-w0",
"fullyQualifiedDomainName": "testcluster1-w0.postgres.database.azure.com"
},
{
"name": "testcluster1-w1",
"fullyQualifiedDomainName": "testcluster1-w1.postgres.database.azure.com"
},
{
"name": "testcluster1-w2",
"fullyQualifiedDomainName": "testcluster1-w2.postgres.database.azure.com"
},
{
"name": "testcluster1-w3",
"fullyQualifiedDomainName": "testcluster1-w2.postgres.database.azure.com"
}
],
"sourceResourceId": null,
"state": "Ready"
},
"systemData": {
"createdAt": "2020-01-01T17:18:19.1234567Z",
"createdBy": "user1",
"createdByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User"
},
"tags": {
"additionalProp1": "string",
"additionalProp2": "string",
"additionalProp3": "string"
}
}
Azure-AsyncOperation: https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/providers/Microsoft.DBforPostgreSQL/locations/westus/azureAsyncOperation/e276a03a-1770-4549-86f5-0edffae8997c?api-version=2023-03-02-preview
Location: https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/providers/Microsoft.DBforPostgreSQL/locations/westus/operationResults/e276a03a-1770-4549-86f5-0edffae8997c?api-version=2023-03-02-preview
{
"name": "testcluster1",
"type": "Microsoft.DBforPostgreSQL/serverGroupsv2",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster1",
"location": "westus",
"properties": {
"aadAuthEnabled": "disabled",
"administratorLogin": "citus",
"citusVersion": "11.1",
"coordinatorEnablePublicIpAccess": true,
"coordinatorServerEdition": "GeneralPurpose",
"coordinatorStorageQuotaInMb": 2097152,
"coordinatorVCores": 16,
"dataEncryption": {
"type": "SystemManaged"
},
"databaseName": "citus",
"earliestRestoreTime": "2020-09-14T00:00:37.467Z",
"enableHa": false,
"enableShardsOnCoordinator": false,
"maintenanceWindow": {
"customWindow": "Disabled",
"dayOfWeek": 0,
"startHour": 0,
"startMinute": 0
},
"nodeCount": 4,
"nodeEnablePublicIpAccess": false,
"nodeServerEdition": "MemoryOptimized",
"nodeStorageQuotaInMb": 2097152,
"nodeVCores": 16,
"passwordEnabled": "enabled",
"postgresqlVersion": "14",
"preferredPrimaryZone": "1",
"privateEndpointConnections": [],
"provisioningState": "Succeeded",
"readReplicas": [
"/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBForPostgreSQL/serverGroupsv2/testreadreplica-01",
"/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/testrg/providers/Microsoft.DBForPostgreSQL/serverGroupsv2/testreadreplica-02"
],
"serverNames": [
{
"name": "testcluster1-c",
"fullyQualifiedDomainName": "testcluster1-c.postgres.database.azure.com"
},
{
"name": "testcluster1-w0",
"fullyQualifiedDomainName": "testcluster1-w0.postgres.database.azure.com"
},
{
"name": "testcluster1-w1",
"fullyQualifiedDomainName": "testcluster1-w1.postgres.database.azure.com"
},
{
"name": "testcluster1-w2",
"fullyQualifiedDomainName": "testcluster1-w2.postgres.database.azure.com"
},
{
"name": "testcluster1-w3",
"fullyQualifiedDomainName": "testcluster1-w2.postgres.database.azure.com"
}
],
"sourceResourceId": null,
"state": "Ready"
},
"systemData": {
"createdAt": "2020-01-01T17:18:19.1234567Z",
"createdBy": "user1",
"createdByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User"
},
"tags": {
"additionalProp1": "string",
"additionalProp2": "string",
"additionalProp3": "string"
}
}
Update or define maintenance window
Sample request
PATCH https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster?api-version=2023-03-02-preview
{
"properties": {
"maintenanceWindow": {
"customWindow": "Enabled",
"dayOfWeek": 0,
"startHour": 8,
"startMinute": 0
}
}
}
Sample response
{
"name": "testcluster",
"type": "Microsoft.DBforPostgreSQL/serverGroupsv2",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster",
"location": "westus",
"properties": {
"aadAuthEnabled": "disabled",
"administratorLogin": "citus",
"citusVersion": "11.1",
"coordinatorEnablePublicIpAccess": true,
"coordinatorServerEdition": "GeneralPurpose",
"coordinatorStorageQuotaInMb": 2097152,
"coordinatorVCores": 16,
"dataEncryption": {
"type": "SystemManaged"
},
"databaseName": "citus",
"earliestRestoreTime": "2020-09-14T00:00:37.467Z",
"enableHa": false,
"enableShardsOnCoordinator": false,
"maintenanceWindow": {
"customWindow": "Enabled",
"dayOfWeek": 0,
"startHour": 8,
"startMinute": 0
},
"nodeCount": 2,
"nodeEnablePublicIpAccess": false,
"nodeServerEdition": "MemoryOptimized",
"nodeStorageQuotaInMb": 2097152,
"nodeVCores": 16,
"passwordEnabled": "enabled",
"postgresqlVersion": "14",
"preferredPrimaryZone": "1",
"privateEndpointConnections": [],
"provisioningState": "Succeeded",
"readReplicas": [],
"serverNames": [
{
"name": "testcluster1-c",
"fullyQualifiedDomainName": "testcluster1-c.postgres.database.azure.com"
},
{
"name": "testcluster1-w0",
"fullyQualifiedDomainName": "testcluster1-w0.postgres.database.azure.com"
},
{
"name": "testcluster1-w1",
"fullyQualifiedDomainName": "testcluster1-w1.postgres.database.azure.com"
}
],
"sourceResourceId": null,
"state": "Ready"
},
"systemData": {
"createdAt": "2020-01-01T17:18:19.1234567Z",
"createdBy": "user1",
"createdByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User"
}
}
Azure-AsyncOperation: https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/providers/Microsoft.DBforPostgreSQL/locations/westus/azureAsyncOperation/e276a03a-1770-4549-86f5-0edffae8997c?api-version=2023-03-02-preview
Location: https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/providers/Microsoft.DBforPostgreSQL/locations/westus/operationResults/e276a03a-1770-4549-86f5-0edffae8997c?api-version=2023-03-02-preview
{
"name": "testcluster",
"type": "Microsoft.DBforPostgreSQL/serverGroupsv2",
"id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestResourceGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster",
"location": "westus",
"properties": {
"aadAuthEnabled": "disabled",
"administratorLogin": "citus",
"citusVersion": "11.1",
"coordinatorEnablePublicIpAccess": true,
"coordinatorServerEdition": "GeneralPurpose",
"coordinatorStorageQuotaInMb": 2097152,
"coordinatorVCores": 16,
"dataEncryption": {
"type": "SystemManaged"
},
"databaseName": "citus",
"earliestRestoreTime": "2020-09-14T00:00:37.467Z",
"enableHa": false,
"enableShardsOnCoordinator": false,
"maintenanceWindow": {
"customWindow": "Enabled",
"dayOfWeek": 0,
"startHour": 8,
"startMinute": 0
},
"nodeCount": 2,
"nodeEnablePublicIpAccess": false,
"nodeServerEdition": "MemoryOptimized",
"nodeStorageQuotaInMb": 2097152,
"nodeVCores": 16,
"passwordEnabled": "enabled",
"postgresqlVersion": "14",
"preferredPrimaryZone": "1",
"privateEndpointConnections": [],
"provisioningState": "Succeeded",
"readReplicas": [],
"serverNames": [
{
"name": "testcluster1-c",
"fullyQualifiedDomainName": "testcluster1-c.postgres.database.azure.com"
},
{
"name": "testcluster1-w0",
"fullyQualifiedDomainName": "testcluster1-w0.postgres.database.azure.com"
},
{
"name": "testcluster1-w1",
"fullyQualifiedDomainName": "testcluster1-w1.postgres.database.azure.com"
}
],
"sourceResourceId": null,
"state": "Ready"
},
"systemData": {
"createdAt": "2020-01-01T17:18:19.1234567Z",
"createdBy": "user1",
"createdByType": "User",
"lastModifiedAt": "2020-01-02T17:18:19.1234567Z",
"lastModifiedBy": "user2",
"lastModifiedByType": "User"
}
}
Definitions
| Name | Description |
|---|---|
|
Aad |
Indicates whether the cluster was created using AAD authentication. |
|
Active |
|
|
Auth |
Authentication configuration of a cluster. |
| Cluster |
Represents a cluster. |
|
Cluster |
Represents a cluster for update. |
|
created |
The type of identity that created the resource. |
|
Data |
The data encryption properties of a cluster. |
|
Data |
|
|
Error |
The resource management error additional info. |
|
Error |
The error detail. |
|
Error |
Error response |
|
Identity |
Describes the identity of the cluster. |
|
Identity |
|
|
Maintenance |
Schedule settings for regular cluster updates. |
|
Password |
|
|
Password |
Indicates whether the cluster was created with a password or using AAD authentication. |
|
Private |
Property to represent resource id of the private endpoint. |
|
Private |
The private endpoint connection status. |
|
Private |
A collection of information about the state of the connection between service consumer and provider. |
|
Server |
The name object for a server. |
|
Simple |
A private endpoint connection. |
|
system |
Metadata pertaining to creation and last modification of the resource. |
|
User |
User assigned identity properties |
AadEnabledEnum
Indicates whether the cluster was created using AAD authentication.
| Value | Description |
|---|---|
| enabled | |
| disabled |
ActiveDirectoryAuth
| Value | Description |
|---|---|
| enabled | |
| disabled |
AuthConfig
Authentication configuration of a cluster.
| Name | Type | Description |
|---|---|---|
| activeDirectoryAuth | ||
| passwordAuth |
Cluster
Represents a cluster.
| Name | Type | Description |
|---|---|---|
| id |
string (arm-id) |
Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}" |
| identity |
Describes the identity of the cluster. |
|
| location |
string |
The geo-location where the resource lives |
| name |
string |
The name of the resource |
| properties.aadAuthEnabled |
Indicates whether the cluster was created using AAD authentication. |
|
| properties.administratorLogin |
string |
The administrator's login name of the servers in the cluster. |
| properties.administratorLoginPassword |
string (password) |
The password of the administrator login. Required for creation. |
| properties.authConfig |
Authentication configuration of a cluster. |
|
| properties.citusVersion |
string |
The Citus extension version on all cluster servers. |
| properties.coordinatorEnablePublicIpAccess |
boolean |
If public access is enabled on coordinator. |
| properties.coordinatorServerEdition |
string |
The edition of a coordinator server (default: GeneralPurpose). Required for creation. |
| properties.coordinatorStorageQuotaInMb |
integer (int32) |
The storage of a server in MB. Required for creation. See https://free.blessedness.top/azure/cosmos-db/postgresql/resources-compute for more information. |
| properties.coordinatorVCores |
integer (int32) |
The vCores count of a server (max: 96). Required for creation. See https://free.blessedness.top/azure/cosmos-db/postgresql/resources-compute for more information. |
| properties.dataEncryption |
The data encryption properties of a cluster. |
|
| properties.databaseName |
string |
The database name of the cluster. Only one database per cluster is supported. |
| properties.earliestRestoreTime |
string (date-time) |
The earliest restore point time (ISO8601 format) for the cluster. |
| properties.enableGeoBackup |
boolean |
If cluster backup is stored in another Azure region in addition to the copy of the backup stored in the cluster's region. Enabled only at the time of cluster creation. |
| properties.enableHa |
boolean |
If high availability (HA) is enabled or not for the cluster. |
| properties.enableShardsOnCoordinator |
boolean |
If distributed tables are placed on coordinator or not. Should be set to 'true' on single node clusters. Requires shard rebalancing after value is changed. |
| properties.maintenanceWindow |
Maintenance window of a cluster. |
|
| properties.nodeCount |
integer (int32) |
Worker node count of the cluster. When node count is 0, it represents a single node configuration with the ability to create distributed tables on that node. 2 or more worker nodes represent multi-node configuration. Node count value cannot be 1. Required for creation. |
| properties.nodeEnablePublicIpAccess |
boolean |
If public access is enabled on worker nodes. |
| properties.nodeServerEdition |
string |
The edition of a node server (default: MemoryOptimized). |
| properties.nodeStorageQuotaInMb |
integer (int32) |
The storage in MB on each worker node. See https://free.blessedness.top/azure/cosmos-db/postgresql/resources-compute for more information. |
| properties.nodeVCores |
integer (int32) |
The compute in vCores on each worker node (max: 104). See https://free.blessedness.top/azure/cosmos-db/postgresql/resources-compute for more information. |
| properties.passwordEnabled |
Indicates whether the cluster was created with a password or using AAD authentication. |
|
| properties.pointInTimeUTC |
string (date-time) |
Date and time in UTC (ISO8601 format) for cluster restore. |
| properties.postgresqlVersion |
string |
The major PostgreSQL version on all cluster servers. |
| properties.preferredPrimaryZone |
string |
Preferred primary availability zone (AZ) for all cluster servers. |
| properties.privateEndpointConnections |
The private endpoint connections for a cluster. |
|
| properties.provisioningState |
string |
Provisioning state of the cluster |
| properties.readReplicas |
string[] |
The array of read replica clusters. |
| properties.serverNames |
The list of server names in the cluster |
|
| properties.sourceLocation |
string |
The Azure region of source cluster for read replica clusters. |
| properties.sourceResourceId |
string |
The resource id of source cluster for read replica clusters. |
| properties.state |
string |
A state of a cluster/server that is visible to user. |
| systemData |
Azure Resource Manager metadata containing createdBy and modifiedBy information. |
|
| tags |
object |
Resource tags. |
| type |
string |
The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" |
ClusterForUpdate
Represents a cluster for update.
| Name | Type | Description |
|---|---|---|
| identity |
Describes the identity of the cluster. |
|
| properties.administratorLoginPassword |
string (password) |
The password of the administrator login. Each cluster is created with pre-defined administrative role called ‘citus’. |
| properties.citusVersion |
string |
The Citus extension version on all cluster servers. |
| properties.coordinatorEnablePublicIpAccess |
boolean |
If public access is enabled on coordinator. |
| properties.coordinatorServerEdition |
string |
The edition of the coordinator (default: GeneralPurpose). |
| properties.coordinatorStorageQuotaInMb |
integer (int32) |
The storage of the coordinator in MB. |
| properties.coordinatorVCores |
integer (int32) |
The vCores count of the coordinator (max: 96). |
| properties.enableHa |
boolean |
If high availability (HA) is enabled or not for the cluster. |
| properties.enableShardsOnCoordinator |
boolean |
If distributed tables are placed on coordinator or not. Should be set to 'true' on single node clusters. Requires shard rebalancing after value is changed. |
| properties.maintenanceWindow |
Maintenance window of a cluster. |
|
| properties.nodeCount |
integer (int32) |
Worker node count of the cluster. When node count is 0, it represents a single node configuration with the ability to create distributed tables on that node. 2 or more worker nodes represent multi-node configuration. Node count value cannot be 1. |
| properties.nodeEnablePublicIpAccess |
boolean |
If public access is enabled on worker nodes. |
| properties.nodeServerEdition |
string |
The edition of a node (default: MemoryOptimized). |
| properties.nodeStorageQuotaInMb |
integer (int32) |
The storage in MB on each worker node. |
| properties.nodeVCores |
integer (int32) |
The compute in vCores on each worker node (max: 104). |
| properties.postgresqlVersion |
string |
The major PostgreSQL version on all cluster servers. |
| properties.preferredPrimaryZone |
string |
Preferred primary availability zone (AZ) for all cluster servers. |
| tags |
object |
Application-specific metadata in the form of key-value pairs. |
createdByType
The type of identity that created the resource.
| Value | Description |
|---|---|
| User | |
| Application | |
| ManagedIdentity | |
| Key |
DataEncryption
The data encryption properties of a cluster.
| Name | Type | Description |
|---|---|---|
| primaryKeyUri |
string |
URI for the key in keyvault for data encryption of the primary server. |
| primaryUserAssignedIdentityId |
string |
Resource Id for the User assigned identity to be used for data encryption of the primary server. |
| type |
DataEncryptionType
| Value | Description |
|---|---|
| AzureKeyVault | |
| SystemAssigned |
ErrorAdditionalInfo
The resource management error additional info.
| Name | Type | Description |
|---|---|---|
| info |
object |
The additional info. |
| type |
string |
The additional info type. |
ErrorDetail
The error detail.
| Name | Type | Description |
|---|---|---|
| additionalInfo |
The error additional info. |
|
| code |
string |
The error code. |
| details |
The error details. |
|
| message |
string |
The error message. |
| target |
string |
The error target. |
ErrorResponse
Error response
| Name | Type | Description |
|---|---|---|
| error |
The error object. |
IdentityProperties
Describes the identity of the cluster.
| Name | Type | Description |
|---|---|---|
| type | ||
| userAssignedIdentities |
<string,
User |
The set of user assigned identities associated with the resource. The userAssignedIdentities dictionary keys will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}. The dictionary values can be empty objects ({}) in requests. |
IdentityType
| Value | Description |
|---|---|
| UserAssigned | |
| SystemAssigned |
MaintenanceWindow
Schedule settings for regular cluster updates.
| Name | Type | Description |
|---|---|---|
| customWindow |
string |
Indicates whether custom maintenance window is enabled or not. |
| dayOfWeek |
integer (int32) |
Preferred day of the week for maintenance window. |
| startHour |
integer (int32) |
Start hour within preferred day of the week for maintenance window. |
| startMinute |
integer (int32) |
Start minute within the start hour for maintenance window. |
PasswordAuth
| Value | Description |
|---|---|
| enabled | |
| disabled |
PasswordEnabledEnum
Indicates whether the cluster was created with a password or using AAD authentication.
| Value | Description |
|---|---|
| enabled | |
| disabled |
PrivateEndpointProperty
Property to represent resource id of the private endpoint.
| Name | Type | Description |
|---|---|---|
| id |
string |
Resource id of the private endpoint. |
PrivateEndpointServiceConnectionStatus
The private endpoint connection status.
| Value | Description |
|---|---|
| Pending | |
| Approved | |
| Rejected |
PrivateLinkServiceConnectionState
A collection of information about the state of the connection between service consumer and provider.
| Name | Type | Description |
|---|---|---|
| actionsRequired |
string |
A message indicating if changes on the service provider require any updates on the consumer. |
| description |
string |
The reason for approval/rejection of the connection. |
| status |
Indicates whether the connection has been Approved/Rejected/Removed by the owner of the service. |
ServerNameItem
The name object for a server.
| Name | Type | Description |
|---|---|---|
| fullyQualifiedDomainName |
string |
The fully qualified domain name of a server. |
| name |
string |
The name of a server. |
SimplePrivateEndpointConnection
A private endpoint connection.
| Name | Type | Description |
|---|---|---|
| id |
string (arm-id) |
Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}" |
| name |
string |
The name of the resource |
| properties.groupIds |
string[] |
Group ids of the private endpoint connection. |
| properties.privateEndpoint |
Private endpoint which the connection belongs to. |
|
| properties.privateLinkServiceConnectionState |
A collection of information about the state of the connection between service consumer and provider. |
|
| systemData |
Azure Resource Manager metadata containing createdBy and modifiedBy information. |
|
| type |
string |
The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts" |
systemData
Metadata pertaining to creation and last modification of the resource.
| Name | Type | Description |
|---|---|---|
| createdAt |
string (date-time) |
The timestamp of resource creation (UTC). |
| createdBy |
string |
The identity that created the resource. |
| createdByType |
The type of identity that created the resource. |
|
| lastModifiedAt |
string (date-time) |
The timestamp of resource last modification (UTC) |
| lastModifiedBy |
string |
The identity that last modified the resource. |
| lastModifiedByType |
The type of identity that last modified the resource. |
UserAssignedIdentity
User assigned identity properties
| Name | Type | Description |
|---|---|---|
| clientId |
string (uuid) |
The client ID of the assigned identity. |
| principalId |
string (uuid) |
The principal ID of the assigned identity. |