Event Hubs - List By Namespace
取得命名空間中的所有事件中樞。
GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/eventhubs?api-version=2024-01-01
GET https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.EventHub/namespaces/{namespaceName}/eventhubs?api-version=2024-01-01&$skip={$skip}&$top={$top}
URI 參數
名稱 | 位於 | 必要 | 類型 | Description |
---|---|---|---|---|
namespace
|
path | True |
string minLength: 6maxLength: 50 pattern: ^[a-zA-Z][a-zA-Z0-9-]{6,50}[a-zA-Z0-9]$ |
Namespace名稱 |
resource
|
path | True |
string minLength: 1maxLength: 90 |
Azure 訂用帳戶內的資源組名。 |
subscription
|
path | True |
string |
可唯一識別Microsoft Azure 訂用帳戶的訂用帳戶認證。 訂用帳戶標識碼會形成每個服務呼叫 URI 的一部分。 |
api-version
|
query | True |
string |
用戶端 API 版本。 |
$skip
|
query |
integer minimum: 0maximum: 1000 |
只有在先前的作業傳回部分結果時,才會使用Skip。 如果先前的回應包含 nextLink 元素,則 nextLink 元素的值會包含 skip 參數,指定要用於後續呼叫的起點。 |
|
$top
|
query |
integer minimum: 1maximum: 1000 |
可用來將結果數目限制為最新的 N usageDetails。 |
回應
名稱 | 類型 | Description |
---|---|---|
200 OK |
已成功擷取事件中樞清單。 |
|
Other Status Codes |
Eventhub 錯誤回應,描述作業失敗的原因。 |
安全性
azure_auth
Azure Active Directory OAuth2 Flow
類型:
oauth2
Flow:
implicit
授權 URL:
https://login.microsoftonline.com/common/oauth2/authorize
範圍
名稱 | Description |
---|---|
user_impersonation | 模擬您的用戶帳戶 |
範例
EventHubsListAll
範例要求
範例回覆
{
"value": [
{
"id": "/subscriptions/e2f361f0-3b27-4503-a9cc-21cfba380093/resourceGroups/Default-NotificationHubs-AustraliaEast/providers/Microsoft.EventHub/namespaces/sdk-Namespace-716/eventhubs/sdk-eventhub-10",
"name": "sdk-eventhub-10",
"type": "Microsoft.EventHub/Namespaces/EventHubs",
"properties": {
"messageRetentionInDays": 4,
"partitionCount": 4,
"status": "Active",
"createdAt": "2017-06-28T02:45:55.877Z",
"updatedAt": "2017-06-28T02:46:05.877Z",
"partitionIds": [
"0",
"1",
"2",
"3"
],
"captureDescription": {
"enabled": true,
"encoding": "Avro",
"destination": {
"name": "EventHubArchive.AzureBlockBlob",
"properties": {
"storageAccountResourceId": "/subscriptions/e2f361f0-3b27-4503-a9cc-21cfba380093/resourceGroups/Default-Storage-SouthCentralUS/providers/Microsoft.ClassicStorage/storageAccounts/arjunteststorage",
"blobContainer": "container",
"archiveNameFormat": "{Namespace}/{EventHub}/{PartitionId}/{Year}/{Month}/{Day}/{Hour}/{Minute}/{Second}"
}
},
"intervalInSeconds": 120,
"sizeLimitInBytes": 10485763
},
"retentionDescription": {
"cleanupPolicy": "Delete",
"retentionTimeInHours": 96,
"tombstoneRetentionTimeInHours": 1
}
}
}
]
}
定義
名稱 | Description |
---|---|
Capture |
設定 eventhub 擷取描述的屬性 |
Capture |
值,指出是否啟用擷取描述。 |
Capture |
Azure Active Directory 受控識別的類型。 |
Cleanup |
列舉清除原則的可能值 |
created |
建立資源的身分識別類型。 |
Destination |
擷取描述的擷取記憶體詳細 |
Encoding |
列舉擷取描述編碼格式的可能值。 注意:新 API 版本中將會淘汰 'AvroDeflate' |
Entity |
列舉事件中樞狀態的可能值。 |
Error |
資源管理錯誤其他資訊。 |
Error |
錯誤詳細數據。 |
Error |
錯誤回應指出事件中樞服務無法處理傳入要求。 錯誤訊息中會提供原因。 |
Eventhub |
清單或取得事件中樞作業中的單一專案 |
Event |
List EventHubs 作業的結果。 |
Retention |
設定 eventhub 保留設定的屬性 |
system |
與建立和上次修改資源相關的元數據。 |
CaptureDescription
設定 eventhub 擷取描述的屬性
名稱 | 類型 | Description |
---|---|---|
destination |
將儲存擷取之目的地的屬性。 (記憶體帳戶、Blob 名稱) |
|
enabled |
boolean |
值,指出是否啟用擷取描述。 |
encoding |
列舉擷取描述編碼格式的可能值。 注意:新 API 版本中將會淘汰 'AvroDeflate' |
|
intervalInSeconds |
integer (int32) |
時間範圍可讓您設定擷取至 Azure Blob 的頻率,值應介於 60 到 900 秒之間 |
sizeLimitInBytes |
integer (int32) |
大小視窗會在擷取作業之前定義事件中樞內建的數據量,值應該介於10485760到524288000個字節之間 |
skipEmptyArchives |
boolean |
值,指出是否略過空白封存 |
CaptureIdentity
值,指出是否啟用擷取描述。
名稱 | 類型 | Description |
---|---|---|
type |
Azure Active Directory 受控識別的類型。 |
|
userAssignedIdentity |
string |
受控用戶識別的 ARM 識別碼。 這是必要屬性,類型為UserAssignedIdentity。 如果類型為 SystemAssigned,則會使用與命名空間相關聯的系統指派身分識別。 |
CaptureIdentityType
Azure Active Directory 受控識別的類型。
值 | Description |
---|---|
SystemAssigned | |
UserAssigned |
CleanupPolicyRetentionDescription
列舉清除原則的可能值
值 | Description |
---|---|
Compact | |
Delete |
createdByType
建立資源的身分識別類型。
值 | Description |
---|---|
Application | |
Key | |
ManagedIdentity | |
User |
Destination
擷取描述的擷取記憶體詳細
名稱 | 類型 | Description |
---|---|---|
identity |
值,指出是否啟用擷取描述。 |
|
name |
string |
擷取目的地的名稱 |
properties.archiveNameFormat |
string |
封存的 Blob 命名慣例,例如 {Namespace}/{EventHub}/{PartitionId}/{Year}/{Month}/{Day}/{Hour}/{Minute}/{Second}。 在這裡,所有參數 (Namespace,EventHub .. 等) 都是強制性的,無論順序為何 |
properties.blobContainer |
string |
Blob 容器名稱 |
properties.dataLakeAccountName |
string |
擷取事件的 Azure Data Lake Store 名稱 |
properties.dataLakeFolderPath |
string |
所擷取事件的目的地資料夾路徑 |
properties.dataLakeSubscriptionId |
string (uuid) |
Azure Data Lake Store 的訂用帳戶標識碼 |
properties.storageAccountResourceId |
string |
要用來建立 Blob 的記憶體帳戶資源識別碼 |
EncodingCaptureDescription
列舉擷取描述編碼格式的可能值。 注意:新 API 版本中將會淘汰 'AvroDeflate'
值 | Description |
---|---|
Avro | |
AvroDeflate |
EntityStatus
列舉事件中樞狀態的可能值。
值 | Description |
---|---|
Active | |
Creating | |
Deleting | |
Disabled | |
ReceiveDisabled | |
Renaming | |
Restoring | |
SendDisabled | |
Unknown |
ErrorAdditionalInfo
資源管理錯誤其他資訊。
名稱 | 類型 | Description |
---|---|---|
info |
object |
其他資訊。 |
type |
string |
其他信息類型。 |
ErrorDetail
錯誤詳細數據。
名稱 | 類型 | Description |
---|---|---|
additionalInfo |
錯誤其他資訊。 |
|
code |
string |
錯誤碼。 |
details |
錯誤詳細數據。 |
|
message |
string |
錯誤訊息。 |
target |
string |
錯誤目標。 |
ErrorResponse
錯誤回應指出事件中樞服務無法處理傳入要求。 錯誤訊息中會提供原因。
名稱 | 類型 | Description |
---|---|---|
error |
error 物件。 |
Eventhub
清單或取得事件中樞作業中的單一專案
名稱 | 類型 | Description |
---|---|---|
id |
string |
資源的完整資源標識碼。 例如 - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName} |
location |
string |
資源所在的地理位置 |
name |
string |
資源的名稱 |
properties.captureDescription |
擷取描述的屬性 |
|
properties.createdAt |
string (date-time) |
建立事件中樞的確切時間。 |
properties.messageRetentionInDays |
integer (int64) minimum: 1 |
保留此事件中樞事件的天數,值應為 1 到 7 天 |
properties.partitionCount |
integer (int64) minimum: 1 |
為事件中樞建立的數據分割數目,允許的值是從 1 到 32 個數據分割。 |
properties.partitionIds |
string[] |
事件中樞上的目前分區數目。 |
properties.retentionDescription |
事件中樞保留設定 |
|
properties.status |
列舉事件中樞狀態的可能值。 |
|
properties.updatedAt |
string (date-time) |
訊息更新的確切時間。 |
properties.userMetadata |
string |
取得和設定使用者的元數據。 |
systemData |
與此資源相關的系統元數據。 |
|
type |
string |
資源的型別。 例如“Microsoft.EventHub/Namespaces” 或 “Microsoft.EventHub/Namespaces/EventHubs” |
EventHubListResult
List EventHubs 作業的結果。
名稱 | 類型 | Description |
---|---|---|
nextLink |
string |
連結到下一組結果。 如果 Value 包含 EventHubs 不完整的清單,則為空白。 |
value |
Eventhub[] |
List EventHubs 作業的結果。 |
RetentionDescription
設定 eventhub 保留設定的屬性
名稱 | 類型 | Description |
---|---|---|
cleanupPolicy |
列舉清除原則的可能值 |
|
retentionTimeInHours |
integer (int64) |
保留此事件中樞事件的時數。 只有在 cleanupPolicy 為 Delete 時,才會使用此值。 如果 cleanupPolicy 是 Compact,則此屬性的傳回值為 Long.MaxValue |
tombstoneRetentionTimeInHours |
integer (int32) |
保留壓縮事件中樞之墓碑標記的時數。 只有在 cleanupPolicy 為 Compact 時,才會使用此值。 如果取用者從起始位移開始,必須完成讀取此指定時間範圍內的墓碑標記,以確保取用者在壓縮事件中樞內為墓碑標記所描述的特定索引鍵取得有效的快照集 |
systemData
與建立和上次修改資源相關的元數據。
名稱 | 類型 | Description |
---|---|---|
createdAt |
string (date-time) |
資源建立的時間戳(UTC)。 |
createdBy |
string |
建立資源的身分識別。 |
createdByType |
建立資源的身分識別類型。 |
|
lastModifiedAt |
string (date-time) |
上次修改資源的身分識別類型。 |
lastModifiedBy |
string |
上次修改資源的身分識別。 |
lastModifiedByType |
上次修改資源的身分識別類型。 |