blob: efba52027a23a3ec11f462e862b10506e4a672a9 [file] [log] [blame]
Marco Miller660f3532020-02-06 17:38:24 -05001:linkattrs:
Edwin Kempin099a5ec2019-04-25 16:15:14 +02002= Gerrit Code Review - Design Docs
3
4For the link:dev-contributing.html#design-driven-contribution-process[
5design-driven contribution process] it is required to specify features
6upfront in a design doc.
7
Edwin Kempin78ae6852019-08-01 15:27:44 +02008[[structure]]
9== Design Doc Structure
10
11A design doc should discuss the following aspects:
12
13* Use-Cases:
14 The interactions between a user and a system to attain particular
15 goals.
Edwin Kempinfa0610f2022-03-04 11:33:46 +010016* Acceptance Criteria:
Edwin Kempin78ae6852019-08-01 15:27:44 +020017 Conditions that must be satisfied to consider the feature as done.
18* Background:
19 Stuff one needs to know to understand the use-cases (e.g. motivating
20 examples, previous versions and problems, links to related
21 changes/design docs, etc.)
22* Possible Solutions:
23 Possible solutions with the pros and cons, and explanation of
24 implementation details.
25* Conclusion:
26 Which decision was made and what were the reasons for it.
27
28[[collaboration]]
29As community we want to collaborate on design docs as much as possible
30and write them together, in an iterative manner. To make this work well
31design docs are split into multiple files that can be written and
32refined by several persons in parallel:
33
34* `index.md`:
35 Entry file that links to the files below (also see
36 'dev-design-doc-index-template.md').
37* `use-cases.md`:
38 Describes the use-cases, acceptance criteria and background (also see
39 'dev-design-doc-use-cases-template.md').
40* `solution-<n>.md`:
41 Each possible solution (with the pros and cons, and implementation
42 details) is described in a separate file (also see
43 'dev-design-doc-solution-template.md').
44* `conclusion.md`:
45 Describes the conclusion of the design discussion (also see
46 'dev-design-doc-conclusion-template.md').
47
48[[expectation]]
49It is expected that:
50
51* An agreement on the use-cases is achieved before solutions are being
52 discussed in detail.
53* Anyone who has ideas for an alternative solution uploads a change
54 with a `solution-<n>.md` that describes their solution. In case of
55 doubt whether an idea is a refinement of an existing solution or an
56 alternative solution, it's up to the owner of the discussed solution
57 to decide if the solution should be updated, or if the proposer
58 should start a new alternative solution.
59* All possible solutions are fairly discussed with their pros and cons,
60 and treated equally until a conclusion is made.
61* Unrelated issues (judged by the design doc owner) that are identified
Marco Miller75162ac2020-02-10 13:26:02 -050062 during discussions may be extracted into new design docs (initially
63 consisting only of an `index.md` and a `use-cases.md` file). Doing so
64 is optional yet can be done by either the design owner or reviewers.
Edwin Kempin78ae6852019-08-01 15:27:44 +020065* Changes making iterative improvements can be submitted frequently
66 (e.g. additional uses-cases can be added later, solutions can be
67 submitted without describing implementation details, etc.).
68* After a conclusion has been approved contributors are expected to
69 keep the design doc updated and fill in gaps while they go forward
70 with the implementation.
71
Edwin Kempin099a5ec2019-04-25 16:15:14 +020072[[propose]]
73== How to propose a new design?
74
Edwin Kempin78ae6852019-08-01 15:27:44 +020075To propose a new design, upload a change to the
76link:https://gerrit-review.googlesource.com/admin/repos/homepage[
Marian Harbach34253372019-12-10 18:01:31 +010077homepage,role=external,window=_blank] repository that adds a new folder under `pages/design-docs/`
Edwin Kempin78ae6852019-08-01 15:27:44 +020078which contains at least an `index.md` and a `uses-cases.md` file (see
79link:#structure[design doc structure] above).
Edwin Kempin099a5ec2019-04-25 16:15:14 +020080
81Pushing a design doc for review requires to be a
82link:dev-roles.html#contributor[contributor].
83
84When contributing design docs, contributors should make clear whether
85they are committed to do the implementation. It is possible to
86contribute designs without having resources to do the implementation,
87but in this case the implementation is only done if someone volunteers
88to do it (which is not guaranteed to happen).
89
Ben Rohlfs78718c52019-10-08 14:42:03 +020090Only very few maintainers actively watch out for uploaded design docs.
91To raise awareness you may want to send a notification to the
Marian Harbach34253372019-12-10 18:01:31 +010092link:https://groups.google.com/d/forum/repo-discuss[repo-discuss,role=external,window=_blank]
Ben Rohlfs78718c52019-10-08 14:42:03 +020093mailing list about your uploaded design doc. But the discussion should
94not take place on the mailing list, comments should be made by reviewing
95the change in Gerrit.
96
Edwin Kempin099a5ec2019-04-25 16:15:14 +020097[[review]]
98== Design doc review
99
100Everyone in the link:dev-roles.html[Gerrit community] is welcome to
Marco Miller9e0d2992020-02-10 12:28:48 -0500101take part in the design review and comment on the design. As such, every
102design reviewer is expected to respect the community
Marco Miller67f4f532020-02-11 15:10:33 -0500103link:https://www.gerritcodereview.com/codeofconduct.html[Code of Conduct,role=external,window=_blank].
Edwin Kempin099a5ec2019-04-25 16:15:14 +0200104
Edwin Kempin06ef4a72019-12-03 13:25:56 +0100105Positive `Code-Review` votes on changes that add/modify design docs are
106sticky. This means any `Code-Review+1` and `Code-Review+2` vote is
107preserved when a new patch set is uploaded. If a new patch set makes
108significant changes, the uploader of the new patch set must start a new
109review round by removing all positive `Code-Review` votes from the
110change manually.
111
Edwin Kempin78ae6852019-08-01 15:27:44 +0200112Ideas for alternative solutions should be uploaded as a change that
Marco Millereb3a00c2020-02-10 15:21:11 -0500113describes the solution (see link:#collaboration[above]). This should be
114done as early as possible during the review process, so that related
115comment threads stop there and do not clutter the current review. It is up
116to the alternative reviews to then host their related comments.
Edwin Kempin099a5ec2019-04-25 16:15:14 +0200117
Marco Miller41160a02020-02-11 16:11:16 -0500118Verification should be based on the generated `jekyll` site using the
119local `docker`, rather than via the rendering in `gitiles` (via
120`gerrit-review`).
121
Edwin Kempin78ae6852019-08-01 15:27:44 +0200122Changes which make a conclusion on a design (changes that add/change
123the `conclusion.md` file, see link:#structure[Design Doc Structure])
124should stay open for a minimum of 10 calendar days so that everyone has
125a fair chance to see them. It is important that concerns regarding a
126feature are raised during this time frame since once a conclusion is
127approved and submitted the implementation may start immediately.
Edwin Kempin099a5ec2019-04-25 16:15:14 +0200128
Edwin Kempin78ae6852019-08-01 15:27:44 +0200129Other design doc changes can and should be submitted quickly so that
130collaboration and iterative refinements work smoothly (see
131link:#collaboration[above]).
132
133For proposed features the contributor should hear back from the
134link:dev-processes.html#steering-committee[engineering steering
Edwin Kempinc507dbb2020-06-08 11:53:56 +0200135committee] within 30 calendar days whether the proposed feature is in
Edwin Kempin78ae6852019-08-01 15:27:44 +0200136scope of the project and if it can be accepted.
Edwin Kempin099a5ec2019-04-25 16:15:14 +0200137
Marco Miller40def8b2020-08-04 16:48:44 -0400138[[meetings]]
139=== Meeting discussions
140
141If the Gerrit review doesn't start efficiently enough, stalls, gets off-track
142too much or becomes overly complex, one can use a meeting to refocus it. From
143that review thread, the organizer can volunteer oneself, or be proposed (even
144requested) by a reviewer. link:https://www.gerritcodereview.com/members.html#community-managers[
Thomas Draebing4c3d2bb2020-08-06 10:37:27 +0200145Community managers,role=external,window=_blank] may help facilitate that if
146ultimately necessary.
Marco Miller40def8b2020-08-04 16:48:44 -0400147
Edwin Kempin099a5ec2019-04-25 16:15:14 +0200148[[watch-designs]]
149== How to get notified for new design docs?
150
151. Go to the
152 link:https://gerrit-review.googlesource.com/settings/#Notifications[
Marian Harbach34253372019-12-10 18:01:31 +0100153 notification settings,role=external,window=_blank]
Edwin Kempin78ae6852019-08-01 15:27:44 +0200154. Add a project watch for the `homepage` repository with the following
155 query: `dir:pages/design-docs`
Edwin Kempin099a5ec2019-04-25 16:15:14 +0200156
157GERRIT
158------
159Part of link:index.html[Gerrit Code Review]
160
161SEARCHBOX
162---------