OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Package alerts contains structs defined to implement the json format: | 5 // Package alerts contains structs defined to implement the json format: |
6 // https://docs.google.com/document/d/10MESGzRy9uAy3Y3-PxUcjiuF3BD3FGGmCNvCjqm3W
QQ/preview | 6 // https://docs.google.com/document/d/10MESGzRy9uAy3Y3-PxUcjiuF3BD3FGGmCNvCjqm3W
QQ/preview |
7 | 7 |
8 package messages | 8 package messages |
9 | 9 |
10 import ( | 10 import ( |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
77 // BuildFailure is an Extension. | 77 // BuildFailure is an Extension. |
78 type BuildFailure struct { | 78 type BuildFailure struct { |
79 TreeCloser bool | 79 TreeCloser bool |
80 Builders []AlertedBuilder | 80 Builders []AlertedBuilder |
81 Reasons []Reason | 81 Reasons []Reason |
82 RegressionRanges []RegressionRange `json:"regression_ranges"` | 82 RegressionRanges []RegressionRange `json:"regression_ranges"` |
83 } | 83 } |
84 | 84 |
85 // AlertedBuilder represents an individual builder. | 85 // AlertedBuilder represents an individual builder. |
86 type AlertedBuilder struct { | 86 type AlertedBuilder struct { |
87 » Name string | 87 » Name string |
88 » URL string | 88 » URL string |
89 » FirstFailure EpochTime `json:"first_failure"` | 89 » // FirstFailure is the build number of first failure. |
90 » LatestFailure EpochTime `json:"latest_failure"` | 90 » FirstFailure int64 `json:"first_failure"` |
| 91 » // LatestFailure is the build number of latest failure. |
| 92 » LatestFailure int64 `json:"latest_failure"` |
91 } | 93 } |
92 | 94 |
93 // Reason contains information about why the Alert was triggered. | 95 // Reason contains information about why the Alert was triggered. |
94 type Reason struct { | 96 type Reason struct { |
95 TestName string | 97 TestName string |
96 Step string | 98 Step string |
97 URL string | 99 URL string |
98 } | 100 } |
99 | 101 |
100 // RegressionRange identifies the bounds of the location of a regression. | 102 // RegressionRange identifies the bounds of the location of a regression. |
101 type RegressionRange struct { | 103 type RegressionRange struct { |
102 Repo string | 104 Repo string |
103 URL string | 105 URL string |
104 Revisions []string | 106 Revisions []string |
105 } | 107 } |
OLD | NEW |