• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/*
2 * Copyright (C) 2022 Huawei Device Co., Ltd.
3 * Licensed under the Apache License, Version 2.0 (the "License");
4 * you may not use this file except in compliance with the License.
5 * You may obtain a copy of the License at
6 *
7 *     http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS,
11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 * See the License for the specific language governing permissions and
13 * limitations under the License.
14 */
15export const dbName = "gp.db"
16
17export const dbVersion = 1
18
19export const sql_t_general_info =
20    "CREATE TABLE IF NOT EXISTS " + "t_general_info" + "(" +
21    "sessionId TEXT PRIMARY KEY, " +
22    "taskId TEXT NOT NULL," +
23    "appName TEXT," +
24    "appVersion TEXT," +
25    "packageName TEXT," +
26    "startTime TEXT," +
27    "endTime TEXT," +
28    "testDuration TEXT," +
29    "taskName TEXT," +
30    "testCase TEXT," +
31    "testType TEXT," +
32    "user TEXT," +
33    "userId TEXT," +
34    "projectId TEXT," +
35    "dataSource TEXT," +
36    "spVersion TEXT," +
37    "deviceTypeName TEXT," +
38    "brand TEXT," +
39    "deviceName TEXT," +
40    "board TEXT," +
41    "version TEXT," +
42    "plat TEXT," +
43    "cpuCluster TEXT," +
44    "sn TEXT," +
45    "resolution TEXT," +
46    "screenBrightness TEXT," +
47    "volume TEXT," +
48    "batteryVolume TEXT," +
49    "isOnline TEXT," +
50    "deviceNum TEXT," +
51    "roomNumber TEXT," +
52    "taskType TEXT" +
53    ")"
54
55export const sql_t_index_info = "CREATE TABLE IF NOT EXISTS " + "t_index_info" + "(" +
56"timestamp TEXT PRIMARY KEY, " +
57"taskId TEXT NOT NULL, " +
58"flag TEXT, " +
59"shellBackTemp TEXT," +
60"shellFrameTemp TEXT," +
61"shellFrontTemp TEXT," +
62"socThermalTemp TEXT," +
63"systemHTemp TEXT," +
64"gpuTemp TEXT," +
65"ambientTemp TEXT," +
66"batteryTemp TEXT," +
67"ddrFrequency TEXT," +
68"fps TEXT," +
69"fpsJitters TEXT," +
70"cpu0Frequency TEXT," +
71"cpu0Load TEXT," +
72"cpu1Frequency TEXT," +
73"cpu1Load TEXT," +
74"cpu2Frequency TEXT," +
75"cpu2Load TEXT," +
76"cpu3Frequency TEXT," +
77"cpu3Load TEXT," +
78"cpu4Frequency TEXT," +
79"cpu4Load TEXT," +
80"cpu5Frequency TEXT," +
81"cpu5Load TEXT," +
82"cpu6Frequency TEXT," +
83"cpu6Load TEXT," +
84"cpu7Frequency TEXT," +
85"cpu7Load TEXT," +
86"cpuLoad TEXT," +
87"gpuFrequency TEXT," +
88"gpuLoad TEXT," +
89"currentNow TEXT," +
90"capacity TEXT," +
91"enableHiz TEXT," +
92"status TEXT," +
93"voltageNow TEXT," +
94"pss TEXT," +
95"networkUpSpeed TEXT," +
96"networkDownSpeed TEXT" +
97")"
98
99export const task_powersensor_info =
100    "CREATE TABLE IF NOT EXISTS " + "task_powersensor_info" + "(" +
101    "id TEXT PRIMARY KEY," +
102    "taskId TEXT NOT NULL," +
103    "sensor TEXT," +
104    "power TEXT," +
105    "current TEXT," +
106    "percent TEXT" +
107    ")"
108
109export const task_powerapp_info =
110    "CREATE TABLE IF NOT EXISTS " + "task_powerapp_info" + "(" +
111    "id TEXT PRIMARY KEY," +
112    "taskId TEXT NOT NULL," +
113    "process TEXT," +
114    "energy TEXT," +
115    "percent TEXT" +
116    ")"
117