Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 1 | # Life of a Chrome commit on Chrome OS |
| 2 | |
Mike Frysinger | 05bebd5 | 2021-01-27 18:48:11 | [diff] [blame] | 3 | *** note |
| 4 | **Warning: This document is old & has moved. Please update any links:**<br> |
| 5 | https://chromium.googlesource.com/chromiumos/docs/+/HEAD/chrome_commit_pipeline.md |
| 6 | *** |
| 7 | |
Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 8 | This document provides a brief overview of how Chrome changes get committed |
| 9 | and tested on Chrome OS. |
| 10 | |
| 11 | For details on non-Chrome **Chrome OS** changes, see |
| 12 | [Life of a Chrome OS commit](cros_commit_pipeline.md). |
| 13 | |
| 14 | ## Create a Chrome change |
| 15 | |
| 16 | ### Make and upload changes |
| 17 | |
| 18 | See the section on [contributing code] at [chromium.org] |
| 19 | for how to create a branch and make changes. |
| 20 | |
| 21 | Once a change is completed and tested locally, upload it to [codereview]: |
| 22 | |
| 23 | ```git cl upload``` |
| 24 | |
| 25 | ### Have your change reviewed |
| 26 | |
Ben Pastene | 7ad5400 | 2020-02-07 00:46:18 | [diff] [blame] | 27 | Before submitting the code, use [Gerrit] to have it reviewed like any standard |
| 28 | Chrome OS CL. See [contributing code] for details. |
Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 29 | |
| 30 | ## The Chrome commit pipeline |
| 31 | |
| 32 | ### The Commit Queue and Tryservers |
| 33 | |
| 34 | The Chrome [commit queue] has a very large pool of builders that will apply |
Ben Pastene | 7ad5400 | 2020-02-07 00:46:18 | [diff] [blame] | 35 | individual changes to the master, build them, and test them. |
Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 36 | |
| 37 | #### Before the patch is approved |
| 38 | |
| 39 | A developer can click on 'Choose trybots' to select specific builders to run |
| 40 | (there are a lot of them). |
| 41 | |
| 42 | Alternately they can click 'CQ dry run' to run all of the builders that the |
| 43 | CQ will run in advance, without scheduling a commit. |
| 44 | |
| 45 | #### The commit queue |
| 46 | |
Ben Pastene | 7ad5400 | 2020-02-07 00:46:18 | [diff] [blame] | 47 | Once a change has been reviewed and approved, the developer can apply the CQ+2 |
| 48 | label, which marks the change ready for the CQ. |
Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 49 | |
Ben Pastene | 7ad5400 | 2020-02-07 00:46:18 | [diff] [blame] | 50 | Depending on what was changed, the CQ selects a suite of trybots for |
| 51 | [android], [cros], [linux/fuchsia], [mac/ios], and [win]. |
Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 52 | |
Ben Pastene | 7ad5400 | 2020-02-07 00:46:18 | [diff] [blame] | 53 | The [cros] trybots include: |
| 54 | - [linux-chromeos-rel]: a linux builder with `target_os = "chromeos"` that runs |
| 55 | `browser_tests` and `unit_tests` for Chrome on Chrome OS. |
| 56 | - [chromeos-amd64-generic-rel]: a Simple Chrome builder that runs telemetry and |
| 57 | dep:Chrome Tast tests in amd64-generic VMs. |
Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 58 | |
| 59 | If the CQ builders succeed then the change will be committed to the master. |
Ben Pastene | 7ad5400 | 2020-02-07 00:46:18 | [diff] [blame] | 60 | Otherwise the 'CQ+2' label will need to be reapplied once the failure is fixed |
| 61 | or determined to be unrelated to the change. |
Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 62 | |
| 63 | ### The chromium waterfall |
| 64 | |
| 65 | Once a change is committed on the master, it is picked up by the |
| 66 | [chromium waterfall]. This includes a very large number of builders that will |
Ben Pastene | 7ad5400 | 2020-02-07 00:46:18 | [diff] [blame] | 67 | thoroughly test the commit, including a number of [public Chrome OS builders] |
| 68 | and a few [private builders]. Their tests can run on linux-chromeos, Chrome OS |
| 69 | VMs, and Chrome OS DUTs (Device Under Test). |
Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 70 | |
| 71 | *Note: Due to lab limitations not every builder in the waterfall is included |
Ben Pastene | 7ad5400 | 2020-02-07 00:46:18 | [diff] [blame] | 72 | in the Commit Queue. For Chrome OS there are a few Debug and device testers that |
| 73 | only exist on the waterfall. Failures there are infrequent but possible, so keep |
| 74 | an eye out!* |
Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 75 | |
| 76 | ## The Chrome OS commit pipeline for Chrome changes |
| 77 | |
George Engelbrecht | b415400 | 2020-02-05 20:45:21 | [diff] [blame] | 78 | Once a Chrome change lands in the master, it needs to be landed via [PUpr] |
| 79 | uprev before it will be picked up by Chrome OS. PUpr watches chrome tags |
| 80 | as they are created each day and cuts a CL to the current gardener to land. |
| 81 | Changes are included in ChromeOS builds once the uprev CL makes it through |
| 82 | the ChromeOS CQ. There is a [PUpr Dashboard] that shows the current status |
| 83 | of the uprev CLs as well as the age of the current chrome version on ChromeOS. |
Steven Bennetts | 33ee0bd | 2017-03-24 21:06:06 | [diff] [blame] | 84 | |
Evan Benn | 6a6383b | 2019-10-31 23:01:07 | [diff] [blame] | 85 | [contributing code]: contributing.md |
Mike Frysinger | 9fc0fc0 | 2020-09-05 05:18:57 | [diff] [blame] | 86 | [commit queue]: https://chromium.googlesource.com/chromium/src/+/HEAD/infra/config/generated/cq-builders.md |
| 87 | [chromium.org]: https://www.chromium.org |
Ben Pastene | 7ad5400 | 2020-02-07 00:46:18 | [diff] [blame] | 88 | [Gerrit]: https://chromium-review.googlesource.com/ |
| 89 | [android]: https://ci.chromium.org/p/chromium/g/tryserver.chromium.android |
| 90 | [cros]: https://ci.chromium.org/p/chromium/g/tryserver.chromium.chromiumos |
| 91 | [mac/ios]: https://ci.chromium.org/p/chromium/g/tryserver.chromium.mac |
| 92 | [linux/fuchsia]: https://ci.chromium.org/p/chromium/g/tryserver.chromium.linux |
| 93 | [win]: https://ci.chromium.org/p/chromium/g/tryserver.chromium.win |
| 94 | [linux-chromeos-rel]: https://ci.chromium.org/p/chromium/builders/luci.chromium.try/linux-chromeos-rel |
| 95 | [chromeos-amd64-generic-rel]: https://ci.chromium.org/p/chromium/builders/luci.chromium.try/chromeos-amd64-generic-rel |
| 96 | [chromium waterfall]: https://ci.chromium.org/p/chromium/g/main/console |
| 97 | [public Chrome OS builders]: https://ci.chromium.org/p/chromium/g/chromium.chromiumos/builders |
| 98 | [private builders]: https://ci.chromium.org/p/chrome/g/chrome/builders |
George Engelbrecht | b415400 | 2020-02-05 20:45:21 | [diff] [blame] | 99 | [PUpr]: https://g3doc.corp.google.com/company/teams/chrome/ops/chromeos/continuous_integration/pupr.md?cl=head |
| 100 | [PUpr Dashboard]: http://go/chromeos-dash-pupr-chrome |