共用方式為


New-AzPlatformTelemetryDataSourceObject

建立 PlatformTelemetryDataSource 的記憶體內部物件。

語法

New-AzPlatformTelemetryDataSourceObject
   -Stream <String[]>
   [-Name <String>]
   [<CommonParameters>]

Description

建立 PlatformTelemetryDataSource 的記憶體內部物件。

範例

範例 1:建立平臺遙測數據源物件

New-AzPlatformTelemetryDataSourceObject -Stream "Microsoft.Insights/autoscalesettings:Logs-AutoscaleEvaluations","Microsoft.Insights/autoscalesettings:Logs-AutoscaleScaleActions" -Name "myAutoScalePlatformTelemetryLogs"

Name                             Stream
----                             ------
myAutoScalePlatformTelemetryLogs {Microsoft.Insights/autoscalesettings:Logs-AutoscaleEvaluations, Microsoft.Insights/autoscalesettings:Logs-AutoscaleScaleActions}

此命令會使用 XPathQuery 建立平台遙測數據源物件。

參數

-Name

數據源的易記名稱。 此名稱在數據收集規則內的所有數據源中都應該是唯一的。不論類型為何。

類型:String
Position:Named
預設值:None
必要:False
接受管線輸入:False
接受萬用字元:False

-Stream

要收集的平臺遙測數據流清單。

類型:String[]
Position:Named
預設值:None
必要:True
接受管線輸入:False
接受萬用字元:False

輸出

PlatformTelemetryDataSource