다음을 통해 공유


ACSCallClientMediaStatsTimeSeries 테이블에 대한 쿼리

Azure Portal에서 이러한 쿼리를 사용하는 방법에 대한 자세한 내용은 Log Analytics 자습서를 참조하세요. REST API는 쿼리를 참조 하세요.

통화 중인 모든 참가자의 시계열 미디어 통계 가져오기

ACSCallClientMediaStatsTimeSeries 로그를 기반으로 지정된 호출에 있는 모든 참가자의 시계열 미디어 통계 가져오기

// Replace queryConditions_callId with the callId you want to investigate.
// Note this query is used in Call Diagnostics timeline page to get all the time series media metrics for all participants in the call.
declare query_parameters(queryConditions_callId:string = 'replace-with-your-callId');
ACSCallClientMediaStatsTimeSeries
| where CallId == queryConditions_callId
| extend lcMediaStreamType = tolower(MediaStreamType)
| extend lcMediaStreamDirection = tolower(MediaStreamDirection)
| extend isIncoming = case(
    lcMediaStreamDirection == 'recv', true,
    lcMediaStreamDirection == 'incoming', true, 
    false)
| extend isOutgoing = 
    case(lcMediaStreamDirection == 'send', true,
         lcMediaStreamDirection == 'outgoing', true,
        false)
| extend MediaStreamDirectionType = case(isIncoming == true, 'recv', "send")
| summarize hint.strategy = shuffle arg_max(OperationName, *) by CallClientTimeStamp, MetricName, MediaStreamDirection, MediaStreamType, MediaStreamDirectionType
| order by CallClientTimeStamp asc
| summarize hint.strategy = shuffle arg_max(OperationName, *), newAverage = avg(Average) by CallClientTimeStamp, MetricName, MediaStreamDirection, MediaStreamType, MediaStreamDirectionType  
| summarize hint.strategy = shuffle
    Timestamps = make_list(CallClientTimeStamp), 
    Values = make_list(newAverage), 
    MediaStreamCodec = make_list(MediaStreamCodec) by MetricName, ParticipantId, MediaStreamDirection, MediaStreamType, MediaStreamDirectionType     
| extend (Timestamps, Values, MediaStreamCodec) = array_sort_asc(Timestamps, Values, MediaStreamCodec)
| project Timestamps, Values, MediaStreamCodec, MetricName, ParticipantId, MediaStreamDirection, MediaStreamType, MediaStreamDirectionType

각 미디어 유형별 메트릭

각 미디어 스트림 유형에 대한 ACSCallClientMediaStatsTimeSeries 로그에 포함된 모든 미디어 메트릭을 나열합니다.

ACSCallClientMediaStatsTimeSeries
| distinct MetricName, MediaStreamType

미디어 유형 및 방향별 메트릭 히스토그램

callId, participantId, 미디어 유형 및 meida 방향별로 선택한 메트릭의 히스토그램을 그어 표시합니다.

let PlotMetricHistogram = (_MetricName: string, _ParticipantId: string = '', _CallId: string = '', _MediaStreamType: string = '', _MediaStreamDirection: string = '') {
    // _MetricName: the name of the metric. This must be set.
    // _ParticipantId: set this variable if want to just plot the metric value histogram for a specific partiticpant.
    // _CallId: set this variable if want to just plot the metric value histogram for a specific call.
    // _MediaStreamType: possible values can be: 'audio', 'video', 'screen'.
    // _MediaStreamDirection: possible values can be: 'recv', 'send'.
    ACSCallClientMediaStatsTimeSeries
    | where MetricName == _MetricName
    | where isempty(_ParticipantId) or ParticipantId == _ParticipantId
    | where isempty(_CallId) or CallId == _CallId
    | where isempty(_MediaStreamType) or MediaStreamType == _MediaStreamType
    | where isempty(_MediaStreamDirection) or MediaStreamDirection == _MediaStreamDirection
    | summarize count=count() by Average
    | render columnchart title=strcat(_MetricName, " Histogram")
};
// Below plots the histogram for jitter for all outbound audio streams
PlotMetricHistogram('JitterInMs', _MediaStreamType='audio', _MediaStreamDirection='send')