go.chromium.org/luci@v0.0.0-20240309015107-7cdc2e660f33/bisection/proto/config/project_config.proto (about) 1 // Copyright 2023 The LUCI Authors. 2 // 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 15 syntax = "proto3"; 16 17 package luci.bisection.config; 18 19 option go_package = "go.chromium.org/luci/bisection/proto/config;configpb"; 20 21 // ProjectConfig is the project-specific configuration data for LUCI Bisection. 22 message ProjectConfig { 23 // Configuration data for compile failure analysis. 24 CompileAnalysisConfig compile_analysis_config = 1; 25 // Configuration data for test failure analysis. 26 TestAnalysisConfig test_analysis_config = 2; 27 } 28 29 // CompileAnalysisConfig is the configuration data for compile failure bisection. 30 // Next available tag: 6. 31 message CompileAnalysisConfig { 32 // The build config to run compile analysis. 33 BuildConfig build_config = 4; 34 // Whether we should run culprit verification 35 bool culprit_verification_enabled = 1; 36 // Whether we should run nthsection analysis 37 bool nthsection_enabled = 2; 38 // Configuration data for Gerrit integration for compile failures. 39 GerritConfig gerrit_config = 3; 40 // Only compile failure which satisfies this filter will be ingested. 41 FailureIngestionFilter failure_ingestion_filter = 5; 42 } 43 44 // TestAnalysisConfig is the configuration data for test failure bisection. 45 // Next available tag: 10. 46 message TestAnalysisConfig { 47 reserved 1; 48 // The build config to run test analysis. 49 BuildConfig build_config = 9; 50 // Flag of whether test failure detector is enabled. 51 // Usually the flag is on for both dev and prod, but we may want to turn 52 // it off for the cases when the bisector is down and we don't want to 53 // create tasks when the bisector cannot run (in which case, the bisector 54 // will just mark the analysis as "DISABLED"). 55 // So in prod, if we need to turn the bisector off, we generally should turn 56 // the detector off as well. 57 bool detector_enabled = 2; 58 // Flag of whether test failure bisector is enabled. 59 // During the development of the test failure bisection feature, it should 60 // be on for dev and off for prod (as we are testing). When everything is 61 // up and running, it should be off for dev and on for prod, because we want 62 // to save resources (running bisection on dev will be expensive). 63 bool bisector_enabled = 3; 64 // The maximum number of test analyses to run in a day for each project. 65 // It only counts analyses that being created within 24 hours, with status different 66 // from "DISABLED" or "UNSUPPORTED". 67 // It allows us to slowly roll out bisection without consuming too much 68 // swarming capacity. 69 uint32 daily_limit = 4; 70 // The list of buildbucket buckets that we should not bisect on. 71 // For example, "reviver", "try", and "findit". 72 // TODO(beining@): deprecating, use failure_ingestion_filter.excluded_buckets instead. 73 repeated string excluded_buckets = 5; 74 // Configuration data for Gerrit integration for test failures. 75 GerritConfig gerrit_config = 6; 76 // The list of swarming test task pools that we want to exclude running bisection. 77 // For example, we want to exclude the "chromium.tests.gpu" pool (b/301523224) 78 // because there are limited resources in the pool. 79 // Note: this is not the pools that the builder run, but the swarming test task pool, 80 // which contains the bots that actually run the tests on swarming. 81 // TODO(beining@): deprecating, use failure_ingestion_filter.excluded_test_pools instead. 82 repeated string excluded_test_pools = 7; 83 // Only test failure which satisfies this filter will be ingested. 84 FailureIngestionFilter failure_ingestion_filter = 8; 85 } 86 87 // FailureIngestionFilter defines filtering rules for failures to be ingested. 88 // A failure needs to fulfill ALL rules. 89 message FailureIngestionFilter { 90 // The list of buildbucket buckets that we should not bisect on. 91 // For example, "reviver", "try", and "findit". 92 // Only applicable for test failure analysis. 93 repeated string excluded_buckets = 1; 94 // The list of swarming test task pools that we want to exclude running bisection. 95 // For example, we want to exclude the "chromium.tests.gpu" pool (b/301523224) 96 // because there are limited resources in the pool. 97 // Note: this is not the pools that the builder run, but the swarming test task pool, 98 // which contains the bots that actually run the tests on swarming. 99 // Only applicable for test failure analysis. 100 repeated string excluded_test_pools = 2; 101 // If this is specified, bisection will only run on failures 102 // from the builder groups in the list. 103 // An empty list means that failures from all builder groups can be ingested. 104 // Only applicable for test failure analysis. 105 repeated string allowed_builder_groups = 3; 106 // The list of builder groups that we should not run bisect on. 107 repeated string excluded_builder_groups = 4; 108 } 109 110 // GerritConfig is the configuration data for Gerrit integration 111 message GerritConfig { 112 // Whether Gerrit API actions are enabled 113 bool actions_enabled = 1; 114 115 // Settings for revert-related actions 116 message RevertActionSettings { 117 // Whether the action is enabled 118 bool enabled = 1; 119 120 // The maximum number of times the action can be performed per day 121 uint32 daily_limit = 2; 122 } 123 124 // Settings for creating reverts for culprit CLs 125 RevertActionSettings create_revert_settings = 2; 126 127 // Settings for submitting reverts for culprit CLs 128 RevertActionSettings submit_revert_settings = 3; 129 130 // Maximum age of a culprit (sec) for its revert to be eligible 131 // for the submit action. 132 // 133 // The age of a culprit is based on the time since the culprit was merged. 134 // If a culprit is older than this limit, LUCI Bisection will skip 135 // submitting its corresponding revert. 136 int64 max_revertible_culprit_age = 4; 137 138 // Settings for culprit actions for nthsection 139 message NthSectionSettings { 140 // Whether culprit action for nthsection culprit is enabled 141 bool enabled = 1; 142 // Whether we should perform actions on nthsection culprits even when 143 // culprit verification errored 144 bool action_when_verification_error = 2; 145 } 146 147 NthSectionSettings nthsection_settings = 5; 148 } 149 150 // BuildConfig contains configuration of how we run rerun builds. 151 message BuildConfig { 152 // The buildbucket builder. 153 Builder builder = 1; 154 } 155 156 // Builder specifies a buildbucket builder. 157 message Builder { 158 // The name of the project that the builder belongs to. 159 string project = 1; 160 // The name of the bucket that the builder belongs to. 161 string bucket = 2; 162 // The name of the builder. 163 string builder = 3; 164 }