共用方式為


Servers - Get

取得叢集中伺服器的相關信息。

GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/{clusterName}/servers/{serverName}?api-version=2023-03-02-preview

URI 參數

名稱 位於 必要 類型 Description
clusterName
path True

string

minLength: 3
maxLength: 40
pattern: ^(?![0-9]+$)(?!-)[a-z0-9-]{3,40}(?

叢集的名稱。

resourceGroupName
path True

string

minLength: 1
maxLength: 90

資源群組的名稱。 名稱不區分大小寫。

serverName
path True

string

minLength: 1
maxLength: 90
pattern: ^[-\w\._]+$

伺服器的名稱。

subscriptionId
path True

string (uuid)

目標訂用帳戶的標識碼。 此值必須是 UUID。

api-version
query True

string

minLength: 1

要用於這項作業的 API 版本。

回應

名稱 類型 Description
200 OK

ClusterServer

還行

Other Status Codes

ErrorResponse

描述作業失敗原因的錯誤回應。

安全性

azure_auth

Azure Active Directory OAuth2 Flow

類型: oauth2
Flow: implicit
授權 URL: https://login.microsoftonline.com/common/oauth2/authorize

範圍

名稱 Description
user_impersonation 模擬您的用戶帳戶。

範例

Get the server of cluster

範例要求

GET https://management.azure.com/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster1/servers/testcluster1-c?api-version=2023-03-02-preview

範例回覆

{
  "id": "/subscriptions/ffffffff-ffff-ffff-ffff-ffffffffffff/resourceGroups/TestGroup/providers/Microsoft.DBforPostgreSQL/serverGroupsv2/testcluster1/servers/testcluster1-c",
  "name": "testcluster1-c",
  "type": "Microsoft.DBforPostgreSQL/serverGroupsv2/servers",
  "systemData": {
    "createdBy": "user1",
    "createdByType": "User",
    "createdAt": "2020-01-01T17:18:19.1234567Z",
    "lastModifiedBy": "user2",
    "lastModifiedByType": "User",
    "lastModifiedAt": "2020-01-02T17:18:19.1234567Z"
  },
  "properties": {
    "fullyQualifiedDomainName": "testcluster1-c.postgres.database.azure.com",
    "postgresqlVersion": "12",
    "citusVersion": "9.5",
    "availabilityZone": "1",
    "role": "Coordinator",
    "serverEdition": "MemoryOptimized",
    "storageQuotaInMb": 10000,
    "vCores": 4,
    "enableHa": true,
    "enablePublicIpAccess": true,
    "state": "Ready",
    "haState": "Healthy",
    "administratorLogin": "citus",
    "isReadOnly": false
  }
}

定義

名稱 Description
ClusterServer

表示叢集中的伺服器。

createdByType

建立資源的身分識別類型。

ErrorAdditionalInfo

資源管理錯誤其他資訊。

ErrorDetail

錯誤詳細數據。

ErrorResponse

錯誤回應

ServerRole

伺服器的角色。

systemData

與建立和上次修改資源相關的元數據。

ClusterServer

表示叢集中的伺服器。

名稱 類型 Description
id

string (arm-id)

資源的完整資源標識碼。 例如 “/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}”

name

string

資源的名稱

properties.administratorLogin

string

系統管理員在叢集中伺服器的登入名稱。

properties.availabilityZone

string

伺服器的可用性區域資訊。

properties.citusVersion

string

伺服器的 Citus 擴充功能版本。

properties.enableHa

boolean

如果已啟用或未啟用伺服器的高可用性 (HA)。

properties.enablePublicIpAccess

boolean

如果伺服器上已啟用公用存取。

properties.fullyQualifiedDomainName

string

伺服器的完整功能變數名稱。

properties.haState

string

叢集的HA功能狀態。

properties.isReadOnly

boolean

如果伺服器資料庫根據高磁碟空間使用量,依系統維護設定為唯讀。

properties.postgresqlVersion

string

伺服器的主要 PostgreSQL 版本。

properties.role

ServerRole

叢集中伺服器的角色。

properties.serverEdition

string

伺服器的版本。

properties.state

string

使用者可以看到的叢集/伺服器狀態。

properties.storageQuotaInMb

integer (int32)

以 MB 為單位的伺服器記憶體。

properties.vCores

integer (int32)

伺服器的虛擬核心計數。

systemData

systemData

包含 createdBy 和 modifiedBy 資訊的 Azure Resource Manager 元數據。

type

string

資源的型別。 例如“Microsoft.Compute/virtualMachines” 或 “Microsoft.Storage/storageAccounts”

createdByType

建立資源的身分識別類型。

Description
Application
Key
ManagedIdentity
User

ErrorAdditionalInfo

資源管理錯誤其他資訊。

名稱 類型 Description
info

object

其他資訊。

type

string

其他信息類型。

ErrorDetail

錯誤詳細數據。

名稱 類型 Description
additionalInfo

ErrorAdditionalInfo[]

錯誤其他資訊。

code

string

錯誤碼。

details

ErrorDetail[]

錯誤詳細數據。

message

string

錯誤訊息。

target

string

錯誤目標。

ErrorResponse

錯誤回應

名稱 類型 Description
error

ErrorDetail

error 物件。

ServerRole

伺服器的角色。

Description
Coordinator
Worker

systemData

與建立和上次修改資源相關的元數據。

名稱 類型 Description
createdAt

string (date-time)

資源建立的時間戳(UTC)。

createdBy

string

建立資源的身分識別。

createdByType

createdByType

建立資源的身分識別類型。

lastModifiedAt

string (date-time)

上次修改的資源時間戳 (UTC)

lastModifiedBy

string

上次修改資源的身分識別。

lastModifiedByType

createdByType

上次修改資源的身分識別類型。