blob: f27701935ab0344185a43805d57a3300ac07d96f [file] [log] [blame]
Robert Ly35f2fda2013-01-29 16:27:05 -08001page.title=Codelines, Branches, and Releases
2@jd:body
3
4<!--
Clay Murphy768b82a2013-11-12 11:32:41 -08005 Copyright 2013 The Android Open Source Project
Robert Ly35f2fda2013-01-29 16:27:05 -08006
7 Licensed under the Apache License, Version 2.0 (the "License");
8 you may not use this file except in compliance with the License.
9 You may obtain a copy of the License at
10
11 http://www.apache.org/licenses/LICENSE-2.0
12
13 Unless required by applicable law or agreed to in writing, software
14 distributed under the License is distributed on an "AS IS" BASIS,
15 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 See the License for the specific language governing permissions and
17 limitations under the License.
18-->
19<div id="qv-wrapper">
20 <div id="qv">
21 <h2>In this document</h2>
22 <ol id="auto-toc">
23 </ol>
24 </div>
25</div>
26
27<p>
Clay Murphy5d294092013-07-15 15:11:40 -070028 The Android Open Source Project (AOSP) maintains a complete software stack to be ported by
29 OEMs and other device implementors and run on their own hardware. To maintain the quality of
30 Android, Google has contributed full-time engineers, product managers, user interface designers,
31 quality assurance testers, and all the other roles required to bring modern devices to market.
Robert Ly35f2fda2013-01-29 16:27:05 -080032</p>
33
34<p>
35 Accordingly, we maintain a number of "code lines" to clearly separate the current stable
36 version of Android from unstable experimental work. We roll the open source administration
37 and maintenance of the Android code lines into the larger product development cycle.
38</p>
39
40<p>
41 The chart below depicts at a conceptual level how AOSP manages code and releases. We're
42 referring to these as "code lines" instead of "branches" simply because at any given moment
Clay Murphy5d294092013-07-15 15:11:40 -070043 there may be more than one branch for a given "code line". For instance, when a
44 release is cut, it may or may not become a new branch based on the needs of the moment.
Robert Ly35f2fda2013-01-29 16:27:05 -080045</p>
Clay Murphyf965cd72013-05-30 14:43:56 -070046<ol>
Robert Ly35f2fda2013-01-29 16:27:05 -080047 <li>
48 <p>
49 At any given moment, there is a current latest release of the Android platform. This
50 typically takes the form of a branch in the tree.
51 </p>
52 </li>
53 <li>
54 <p>
55 Device builders and contributors work with the current latest release, fixing bugs,
56 launching new devices, experimenting with new features, and so on.
57 </p>
58 </li>
59 <li>
60 <p>
61 In parallel, Google works internally on the next version of the Android platform and
Clay Murphy5d294092013-07-15 15:11:40 -070062 framework according to the product's needs and goals. We develop the next
Robert Ly35f2fda2013-01-29 16:27:05 -080063 version of Android by working with a device partner on a flagship device whose
64 specifications are chosen to push Android in the direction we believe it should go.
65 </p>
66 </li>
67 <li>
68 <p>
Clay Murphy5d294092013-07-15 15:11:40 -070069 When the "n+1"th version is ready, it will be published to the public source tree and
Robert Ly35f2fda2013-01-29 16:27:05 -080070 become the new latest release.
71 </p>
72 </li>
Clay Murphyf965cd72013-05-30 14:43:56 -070073</ol>
Robert Ly35f2fda2013-01-29 16:27:05 -080074<p>
75 <img src="{@docRoot}images/code-lines.png" alt="code-line diagram">
76</p>
77
Clay Murphy5d294092013-07-15 15:11:40 -070078<h2 id="terms-and-caveats">
79 Terms and Caveats
Robert Ly35f2fda2013-01-29 16:27:05 -080080</h2>
81<ul>
82 <li>
83 <p>
84 A <em>release</em> corresponds to a formal version of the Android platform, such as 1.5,
Clay Murphy5d294092013-07-15 15:11:40 -070085 2.1, and so on. Generally speaking, a release of the platform corresponds to the version in
86 the <code>SdkVersion</code> field of AndroidManifest.xml files and defined within
Robert Ly35f2fda2013-01-29 16:27:05 -080087 <code>frameworks/base/api</code> in the source tree.
88 </p>
89 </li>
90 <li>
91 <p>
92 An <em>upstream</em> project is an open-source project from which the Android stack is
Clay Murphy5d294092013-07-15 15:11:40 -070093 pulling code. These include obvious projects such as the Linux kernel and WebKit.
Clay Murphye4edda62014-10-16 19:00:15 -070094 Over time we are migrating some of the semi-autonomous Android projects (such as ART,
Robert Ly35f2fda2013-01-29 16:27:05 -080095 the Android SDK tools, Bionic, and so on) to work as "upstream" projects. Generally,
96 these projects are developed entirely in the public tree. For some upstream projects,
Clay Murphy5d294092013-07-15 15:11:40 -070097 development is done by contributing directly to the upstream project itself. See <a href=
Robert Ly35f2fda2013-01-29 16:27:05 -080098 "submit-patches.html#upstream-projects">Upstream Projects</a> for details. In both cases,
99 snapshots will be periodically pulled into releases.
100 </p>
101 </li>
102 <li>
103 <p>
Robert Ly35f2fda2013-01-29 16:27:05 -0800104 At all times, a release code-line (which may actually consist of more than one actual
105 branch in git) is considered the sole canonical source code for a given Android platform
106 version. OEMs and other groups building devices should pull only from a release branch.
107 </p>
108 </li>
109 <li>
110 <p>
Clay Murphy5d294092013-07-15 15:11:40 -0700111 "Experimental" code-lines are established to capture changes from the community so they can
112 be iterated on with an eye toward stability.
Robert Ly35f2fda2013-01-29 16:27:05 -0800113 </p>
114 </li>
115 <li>
116 <p>
Clay Murphy5d294092013-07-15 15:11:40 -0700117 Changes that prove stable will eventually be pulled into a release branch. Note this
118 applies only to bug fixes, application improvements, and other changes that do not affect the
Robert Ly35f2fda2013-01-29 16:27:05 -0800119 APIs of the platform.
120 </p>
121 </li>
122 <li>
123 <p>
124 Changes will be pulled into release branches from upstream projects (including the
125 Android "upstream" projects) as necessary.
126 </p>
127 </li>
128 <li>
129 <p>
130 The "n+1"th version (that is, next major version of the framework and platform APIs) will
Clay Murphy5d294092013-07-15 15:11:40 -0700131 be developed by Google internally. See <a href=
132 "#about-private-code-lines">About Private Codelines</a> for details.
Robert Ly35f2fda2013-01-29 16:27:05 -0800133 </p>
134 </li>
135 <li>
136 <p>
137 Changes will be pulled from upstream, release, and experimental branches into Google's
138 private branch as necessary.
139 </p>
140 </li>
141 <li>
142 <p>
143 When the platform APIs for the next version have stabilized and been fully tested, Google
144 will cut a release of the next platform version. (This specifically refers to a new
145 <code>SdkVersion</code>.) This will also correspond to the internal code-line being made
146 a public release branch, and the new current platform code-line.
147 </p>
148 </li>
149 <li>
150 <p>
151 When a new platform version is cut, a corresponding experimental code-line will be
152 created at the same time.
153 </p>
154 </li>
155</ul>
156
157<h2 id="about-private-code-lines">
158 About Private Codelines
159</h2>
160<p>
161 The source management strategy above includes a code-line that Google will keep private. The
162 reason for this is to focus attention on the current public version of Android.
163</p>
164<p>
165 OEMs and other device builders naturally want to ship devices with the latest version of
Clay Murphy5d294092013-07-15 15:11:40 -0700166 Android. Similarly, application developers don't want to deal with more platform
Robert Ly35f2fda2013-01-29 16:27:05 -0800167 versions than strictly necessary. Meanwhile, Google retains responsibility for the strategic
Clay Murphy5d294092013-07-15 15:11:40 -0700168 direction of Android as a platform and a product. Our approach focuses on a small number of
169 flagship devices to drive features while securing protections of Android-related intellectual
170 property.
Robert Ly35f2fda2013-01-29 16:27:05 -0800171</p>
172<p>
Clay Murphy5d294092013-07-15 15:11:40 -0700173 As a result, Google frequently has possession of confidential information from third parties.
174 And we must refrain from revealing sensitive features until we've secured the appropriate
175 protections. In addition, there are real risks to the platform arising from having too many
Robert Ly35f2fda2013-01-29 16:27:05 -0800176 platform versions extant at once. For these reasons, we have structured the open-source
177 project -- including third-party contributions -- to focus on the currently-public stable
178 version of Android. "Deep development" on the next version of the platform will happen in
Clay Murphy5d294092013-07-15 15:11:40 -0700179 private until it's ready to become an official release.
Robert Ly35f2fda2013-01-29 16:27:05 -0800180</p>
181<p>
Clay Murphy5d294092013-07-15 15:11:40 -0700182 We recognize many contributors will disagree with this approach. We respect others
183 may have a different point of view; however, this is the approach we feel is best, and
Robert Ly35f2fda2013-01-29 16:27:05 -0800184 the one we've chosen to implement.
Clay Murphyf965cd72013-05-30 14:43:56 -0700185</p>