зеркало из https://github.com/mozilla/treeherder.git
adding machine_name and failure_classification_id to job endpoint
This commit is contained in:
Родитель
278e5b02af
Коммит
af3aff99f3
|
@ -229,6 +229,8 @@
|
|||
"sql":"SELECT
|
||||
j.id,
|
||||
j.`option_collection_hash`,
|
||||
j.failure_classification_id,
|
||||
m.`name` as machine_name,
|
||||
mp.`platform` as platform,
|
||||
jt.`name` as job_type_name,
|
||||
jt.`symbol` as job_type_symbol,
|
||||
|
@ -238,6 +240,8 @@
|
|||
j.`result`,
|
||||
j.`state`
|
||||
FROM `job` as j
|
||||
LEFT JOIN `REP0`.`machine` as m
|
||||
ON j.`machine_id` = m.id
|
||||
LEFT JOIN `REP0`.`machine_platform` as mp
|
||||
ON j.`machine_platform_id` = mp.id
|
||||
LEFT JOIN `REP0`.`job_type` as jt
|
||||
|
@ -256,13 +260,14 @@
|
|||
j.`job_coalesced_to_guid`,
|
||||
j.`build_platform_id`,
|
||||
j.`option_collection_hash`,
|
||||
j.failure_classification_id,
|
||||
m.`name` as machine_name,
|
||||
mp.`platform` as platform,
|
||||
mp.`os_name` as machine_platform_os,
|
||||
mp.`architecture` as machine_platform_architecture,
|
||||
bp.`platform` as build_platform,
|
||||
bp.`os_name` as build_os,
|
||||
bp.`architecture` as build_architecture,
|
||||
m.`name` as machine_name,
|
||||
jt.`name` as job_type_name,
|
||||
jt.`symbol` as job_type_symbol,
|
||||
jt.`description` as job_type_description,
|
||||
|
@ -430,6 +435,8 @@
|
|||
"sql":"SELECT
|
||||
j.`id`,
|
||||
j.`option_collection_hash`,
|
||||
j.failure_classification_id,
|
||||
m.`name` as machine_name,
|
||||
mp.`platform` as platform,
|
||||
jt.`name` as job_type_name,
|
||||
jt.`symbol` as job_type_symbol,
|
||||
|
@ -460,13 +467,14 @@
|
|||
j.`job_coalesced_to_guid`,
|
||||
j.`build_platform_id`,
|
||||
j.`option_collection_hash`,
|
||||
j.failure_classification_id,
|
||||
m.`name` as machine_name,
|
||||
mp.`platform` as platform,
|
||||
mp.`os_name` as machine_platform_os,
|
||||
mp.`architecture` as machine_platform_architecture,
|
||||
bp.`platform` as build_platform,
|
||||
bp.`os_name` as build_os,
|
||||
bp.`architecture` as build_architecture,
|
||||
m.`name` as machine_name,
|
||||
jt.`name` as job_type_name,
|
||||
jt.`symbol` as job_type_symbol,
|
||||
jt.`description` as job_type_description,
|
||||
|
|
|
@ -103,7 +103,7 @@ CREATE TABLE `job` (
|
|||
`option_collection_hash` varchar(64) COLLATE utf8_bin DEFAULT NULL,
|
||||
`job_type_id` int(10) unsigned NOT NULL,
|
||||
`product_id` int(10) unsigned DEFAULT NULL,
|
||||
`failure_classification_id` int(10) unsigned DEFAULT 1,
|
||||
`failure_classification_id` int(10) unsigned DEFAULT NULL,
|
||||
`who` varchar(50) COLLATE utf8_bin NOT NULL,
|
||||
`reason` varchar(125) COLLATE utf8_bin NOT NULL,
|
||||
`result` varchar(25) COLLATE utf8_bin DEFAULT NULL,
|
||||
|
|
|
@ -504,6 +504,7 @@ class ResultSetViewSet(viewsets.ViewSet):
|
|||
del(job["result_set_id"])
|
||||
del(job["option_collection_hash"])
|
||||
|
||||
job["platform_option"] = platform_option
|
||||
job["resource_uri"] = reverse("jobs-detail",
|
||||
kwargs={"project": jm.project, "pk": job["id"]})
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче