Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(421)

Side by Side Diff: milo/appengine/logdog/logDogBuild.go

Issue 2250263005: Milo: Prefetch logs that are failures (Closed) Base URL: https://chromium.googlesource.com/external/github.com/luci/luci-go@master
Patch Set: URL fix Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2016 The LUCI Authors. All rights reserved. 1 // Copyright 2016 The LUCI Authors. All rights reserved.
2 // Use of this source code is governed under the Apache License, Version 2.0 2 // Use of this source code is governed under the Apache License, Version 2.0
3 // that can be found in the LICENSE file. 3 // that can be found in the LICENSE file.
4 4
5 package logdog 5 package logdog
6 6
7 import ( 7 import (
8 "fmt" 8 "fmt"
9 "time" 9 "time"
10 10
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 default: 70 default:
71 comp.Status = resp.NotRun 71 comp.Status = resp.NotRun
72 } 72 }
73 73
74 if !(buildCompletedTime.IsZero() || comp.Status.Terminal()) { 74 if !(buildCompletedTime.IsZero() || comp.Status.Terminal()) {
75 // The build has completed, but this step has not. Mark it as an 75 // The build has completed, but this step has not. Mark it as an
76 // infrastructure failure. 76 // infrastructure failure.
77 comp.Status = resp.InfraFailure 77 comp.Status = resp.InfraFailure
78 } 78 }
79 79
80 » // Hide the unimportant steps. 80 » // Hide the unimportant steps, highlight the interesting ones.
81 » if comp.Status == resp.Success { 81 » switch comp.Status {
82 » case resp.Success:
82 if _, ok := builtIn[anno.Name]; ok { 83 if _, ok := builtIn[anno.Name]; ok {
83 comp.Verbosity = resp.Hidden 84 comp.Verbosity = resp.Hidden
84 } 85 }
86 case resp.InfraFailure, resp.Failure:
87 comp.Verbosity = resp.Interesting
85 } 88 }
86 89
87 // Main link is a link to the stdout. 90 // Main link is a link to the stdout.
88 var stdoutLink *miloProto.Link 91 var stdoutLink *miloProto.Link
89 if anno.StdoutStream != nil { 92 if anno.StdoutStream != nil {
90 stdoutLink = &miloProto.Link{ 93 stdoutLink = &miloProto.Link{
91 Label: "stdout", 94 Label: "stdout",
92 Value: &miloProto.Link_LogdogStream{ 95 Value: &miloProto.Link_LogdogStream{
93 LogdogStream: anno.StdoutStream, 96 LogdogStream: anno.StdoutStream,
94 }, 97 },
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
186 for _, prop := range mainAnno.Property { 189 for _, prop := range mainAnno.Property {
187 propGroup.Property = append(propGroup.Property, &resp.Property{ 190 propGroup.Property = append(propGroup.Property, &resp.Property{
188 Key: prop.Name, 191 Key: prop.Name,
189 Value: prop.Value, 192 Value: prop.Value,
190 }) 193 })
191 } 194 }
192 build.PropertyGroup = append(build.PropertyGroup, propGroup) 195 build.PropertyGroup = append(build.PropertyGroup, propGroup)
193 196
194 return 197 return
195 } 198 }
OLDNEW
« no previous file with comments | « milo/appengine/frontend/templates/buildbot/pages/build.html ('k') | milo/appengine/swarming/expectations/build-canceled.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698