REST Resource: projects.histories.executions.steps.perfMetricsSummary

資源:PerfMetricsSummary

收集的性能指標和性能環境資訊的摘要

JSON 表示
{
  "projectId": string,
  "historyId": string,
  "executionId": string,
  "stepId": string,
  "perfMetrics": [
    enum (PerfMetricType)
  ],
  "perfEnvironment": {
    object (PerfEnvironment)
  },
  "appStartTime": {
    object (AppStartTime)
  },
  "graphicsStats": {
    object (GraphicsStats)
  }
}
領域
projectId

string

雲端專案

注意:此欄位僅在回應中使用。請求中指定的任何值都將被忽略。

historyId

string

工具結果歷史 ID。

注意:此欄位僅在回應中使用。請求中指定的任何值都將被忽略。

executionId

string

工具結果執行 ID。

注意:此欄位僅在回應中使用。請求中指定的任何值都將被忽略。

stepId

string

工具結果步驟 ID。

注意:此欄位僅在回應中使用。請求中指定的任何值都將被忽略。

perfMetrics[]

enum ( PerfMetricType )

收集的資源集

perfEnvironment

object ( PerfEnvironment )

描述收集性能指標的環境

appStartTime

object ( AppStartTime )

graphicsStats

object ( GraphicsStats )

整個運行的圖形統計。統計資料在運行開始時重置並在運行結束時收集。

效能環境

封裝性能環境資訊

JSON 表示
{
  "cpuInfo": {
    object (CPUInfo)
  },
  "memoryInfo": {
    object (MemoryInfo)
  }
}
領域
cpuInfo

object ( CPUInfo )

CPU相關環境資訊

memoryInfo

object ( MemoryInfo )

記憶體相關環境資訊

CPU資訊

JSON 表示
{
  "cpuProcessor": string,
  "cpuSpeedInGhz": number,
  "numberOfCores": integer
}
領域
cpuProcessor

string

裝置處理器的描述,即“1.8 GHz 六核心 64 位元 ARMv8-A”

cpuSpeedInGhz

number

CPU 時脈速度(GHz)

numberOfCores

integer

CPU核心數

記憶體資訊

JSON 表示
{
  "memoryTotalInKibibyte": string,
  "memoryCapInKibibyte": string
}
領域
memoryTotalInKibibyte

string ( int64 format)

裝置上可用的總記憶體(以 KiB 為單位)

memoryCapInKibibyte

string ( int64 format)

可以分配給進程的最大記憶體(以 KiB 為單位)

應用程式啟動時間

JSON 表示
{
  "initialDisplayTime": {
    object (Duration)
  },
  "fullyDrawnTime": {
    object (Duration)
  }
}
領域
initialDisplayTime

object ( Duration )

從應用程式啟動到繪製第一個顯示的 Activity 的時間,如 Logcat 中報告的那樣。請參閱https://developer.android.com/topic/performance/launch-time.html#time-initial

fullyDrawnTime

object ( Duration )

選修的。從應用程式啟動到達到開發人員報告的「完全繪製」時間的時間。只有當應用程式包含對 Activity.reportFullyDrawn() 的呼叫時才會儲存此資訊。請參閱https://developer.android.com/topic/performance/launch-time.html#time-full

圖形統計

應用程式的圖形統計。該資訊是從「adb shell dumpsys Graphicsstats」收集的。有關更多信息,請參閱: https://developer.android.com/training/testing/performance.html統計資訊僅適用於 API 23+。

JSON 表示
{
  "totalFrames": string,
  "jankyFrames": string,
  "p50Millis": string,
  "p90Millis": string,
  "p95Millis": string,
  "p99Millis": string,
  "missedVsyncCount": string,
  "highInputLatencyCount": string,
  "slowUiThreadCount": string,
  "slowBitmapUploadCount": string,
  "slowDrawCount": string,
  "buckets": [
    {
      object (Bucket)
    }
  ]
}
領域
totalFrames

string ( int64 format)

由包渲染的總幀數。

jankyFrames

string ( int64 format)

渲染時間較慢的總幀數。應 <= 總幀數。

p50Millis

string ( int64 format)

第 50 個百分位幀渲染時間(以毫秒為單位)。

p90Millis

string ( int64 format)

第 90 個百分位數的幀渲染時間(以毫秒為單位)。

p95Millis

string ( int64 format)

第 95 個百分點的幀渲染時間(以毫秒為單位)。

p99Millis

string ( int64 format)

第 99 個百分位數的幀渲染時間(以毫秒為單位)。

missedVsyncCount

string ( int64 format)

“錯過垂直同步”事件總數。

highInputLatencyCount

string ( int64 format)

“高輸入延遲”事件總數。

slowUiThreadCount

string ( int64 format)

“緩慢的 UI 執行緒”事件總數。

slowBitmapUploadCount

string ( int64 format)

“點陣圖上傳緩慢”事件總數。

slowDrawCount

string ( int64 format)

“緩慢繪製”事件總數。

buckets[]

object ( Bucket )

幀渲染時間的直方圖。應該有 154 個桶,範圍從 [5ms, 6ms) 到 [4950ms, 無窮大)

JSON 表示
{
  "renderMillis": string,
  "frameCount": string
}
領域
renderMillis

string ( int64 format)

渲染時間的下限(以毫秒為單位)。

frameCount

string ( int64 format)

桶中的幀數。

方法

create

建立 PerfMetricsSummary 資源。