Azure portal でこれらのクエリを使用する方法については、 Log Analytics のチュートリアルを参照してください。 REST API については、「 Query」を参照してください。
通話あたりの参加者数
通話あたりの参加者の平均数を計算します。
ACSCallSummaryUpdates
// Get the distinct participants in a call
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, ParticipantId, EndpointId
// Count the participants and distinct calls
| summarize num_participants=count(), num_calls=dcount(CorrelationId)
// Calculate the average number of distinct participants per call
| extend avg_participants = toreal(num_participants) / toreal(num_calls)
| project num_participants, num_calls, avg_participants
参加者の電話番号
通話の参加者の電話番号を一覧表示します。 (電話番号は ACSBillingUsage テーブルから取得されます)。
ACSCallSummaryUpdates
// Get the calls with CallType as Group
| where CallType == 'Group'
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, ParticipantId, ParticipantStartTime, ParticipantDuration, EndpointType, CallType, CallStartTime, PstnParticipantCallType
| project CorrelationId, ParticipantId, ParticipantStartTime, ParticipantDuration, EndpointType, CallType, CallStartTime, PstnParticipantCallType
// Join with ACSBillingUsage data on ParticipantId
| join kind=leftouter (ACSBillingUsage
| where isnotempty(ParticipantId)
| project ParticipantId, UserIdA, UserIdB, StartTime, Quantity)
on ParticipantId
// Combine with calls of CallType P2P
| union (ACSCallSummaryUpdates
| where CallType == 'P2P'
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, ParticipantId, ParticipantStartTime, ParticipantDuration, EndpointType, CallType, CallStartTime, PstnParticipantCallType
| project CorrelationId, ParticipantId, ParticipantStartTime, ParticipantDuration, EndpointType, CallType, CallStartTime, PstnParticipantCallType
// Join with ACSBillingUsage data on CorrelationId
| join kind=leftouter (ACSBillingUsage
| where isnotempty(ParticipantId)
| project CorrelationId, ParticipantId, UserIdA, UserIdB, StartTime, Quantity)
on CorrelationId)
| order by CallStartTime, ParticipantStartTime
グループ通話あたりの参加者数
グループ呼び出しの参加者数のヒストグラムを生成します。
ACSCallSummaryUpdates
// Filter out all P2P calls to calculate only participants in Group calls
| where CallType == 'Group'
// Get the distinct participants in a call
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, ParticipantId
// Count the number of participants per call
| summarize num_participants=count() by CorrelationId
// Aggregate the numbers of participants per call (e.g. if there are three calls
// with 5 participants, this will produce a row [num_participants=5, participant_counts=3])
| summarize participant_counts=count() by num_participants
| order by num_participants asc
| render columnchart with (xcolumn = num_participants, title="Number of participants per group call")
通話の種類の比率
呼び出しの種類 (P2P 呼び出しとグループ呼び出し) の割合の円グラフを生成します。
ACSCallSummaryUpdates
// Count distinct calls (dcount(CorrelationId)) per call type
| summarize call_types=dcount(CorrelationId) by CallType
| render piechart title="Call Type Ratio"
通話期間ヒストグラム
呼び出し期間のヒストグラムを秒単位で生成します。
ACSCallSummaryUpdates
// Get the distinct combinations of CorrelationId, CallDuration
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, CallDuration
// Count call duration bins (60 second intervals)
| summarize duration_counts=count() by bin(CallDuration, 60)
| order by CallDuration asc
| render columnchart with (xcolumn = CallDuration, title="Call duration histogram")
通話時間パーセンタイル
平均通話時間を秒単位で計算し、50%、90%、99% の呼び出し期間パーセンタイルを計算します。
ACSCallSummaryUpdates
// Get the distinct combinations of CorrelationId, CallDuration
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, CallDuration
// Calculate average and percentiles (50%, 90%, and 99%) of call durations (in seconds)
| summarize avg(CallDuration), percentiles(CallDuration, 50, 90, 99)
毎日の通話
過去 1 週間に 1 日に行われた呼び出しのヒストグラムを生成します。
ACSCallSummaryUpdates
// To filter out calls made over a week ago, uncomment the next line
// | where CallStartTime > ago(7d)
// Get the distinct combinations of CorrelationId and CallStartTime
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, CallStartTime
// Adds a new column with the call start day
| extend day = floor(CallStartTime, 1d)
// Count the number of calls per day
| summarize event_count=count() by day
| sort by day asc
| render columnchart title="Number of calls per day"
時間あたりの通話
最後の日に 1 時間あたりに行われた呼び出しのヒストグラムを生成します。
ACSCallSummaryUpdates
// Get the distinct combinations of CorrelationId and CallStartTime
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, CallStartTime
// Adds a new column with the call start hour
| extend hour = floor(CallStartTime, 1h)
// Count the number of calls per hour
| summarize event_count=count() by hour
| sort by hour asc
| render columnchart title="Number of calls per hour in last day"
呼び出しあたりのエンドポイント数
呼び出しあたりの個別のエンドポイントの平均数を計算します。
ACSCallSummaryUpdates
// Get the distinct combinations of CorrelationId and EndpointId
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, EndpointId
// Count all endpoints and distinct calls
| summarize num_endpoints=count(), num_calls=dcount(CorrelationId)
// Calculate the average number of distinct endpoints per call
| extend avg_endpoints = toreal(num_endpoints) / toreal(num_calls)
| project num_endpoints, num_calls, avg_endpoints
SDK のバージョン比率
参加者が使用する SDK バージョンの割合の円グラフを生成します。
ACSCallSummaryUpdates
// Get the distinct participants in a call
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, ParticipantId, EndpointId, SdkVersion
// Count participants that are using a particular SDK
| summarize sdk_counts=count() by SdkVersion
| order by SdkVersion asc
| render piechart title="SDK Version Ratio"
OS バージョンの比率
参加者が使用する OS バージョンの割合の円グラフを作成します。
ACSCallSummaryUpdates
// Get the distinct participants in a call
| summarize arg_max(CallUpdatesVersion, *) by CorrelationId, ParticipantId, EndpointId, OsVersion
// Simplified OS version name by searching for a specific OS keyword
// and performs a different string split operation per OS type
| extend simple_os = case( indexof(OsVersion, "Android") != -1, tostring(split(OsVersion, ";")[0]),
indexof(OsVersion, "Darwin") != -1, tostring(split(OsVersion, ":")[0]),
indexof(OsVersion, "Windows") != -1, tostring(split(OsVersion, ".")[0]),
OsVersion
)
// Count the participants that are using a particular OS version
| summarize os_counts=count() by simple_os
| order by simple_os asc
| render piechart title="OS Version Ratio"
通話あたりのストリーム数
呼び出しあたりのストリームの平均数を計算します。
ACSCallDiagnosticsUpdates
// Count the streams and distinct calls
| summarize num_streams=count(), num_calls=dcount(CorrelationId)
// Calculate the average number of streams per call
| extend avg_streams = toreal(num_streams) / toreal(num_calls)
通話ごとのストリーム数のヒストグラム
呼び出しごとにストリームの数のヒストグラムを生成します。
ACSCallDiagnosticsUpdates
// Counts the number of streams per call
| summarize streams_per_call=count() by CorrelationId
// Aggregates the numbers of streams per call (e.g. if there are 7 calls that have 6 streams,
// this will produce a row [streams_per_call=6, stream_counts=7])
| summarize stream_counts=count() by streams_per_call
| order by streams_per_call asc
| render columnchart title="Streams per call histogram"