blob: 5de84ff1a6e4d66ff548fe971de279b17c1c2f40 [file] [log] [blame]
Yuxuan 'fishy' Wang4f5ad9d2016-05-03 16:18:58 -07001= Release notes for Gerrit 2.0.21
Shawn O. Pearcec20e2832010-02-17 09:16:26 -08002
3Gerrit 2.0.21 is now available in the usual location:
4
Shawn Pearce6d7ebc62015-06-12 16:34:42 -07005link:https://www.gerritcodereview.com/download/index.html[https://www.gerritcodereview.com/download/index.html]
Shawn O. Pearcec20e2832010-02-17 09:16:26 -08006
7
Yuxuan 'fishy' Wang4f5ad9d2016-05-03 16:18:58 -07008== Schema Change
Shawn O. Pearcec20e2832010-02-17 09:16:26 -08009
10*WARNING: This version contains a schema change* (since 2.0.19)
11
12* The schema change may be difficult to undo once applied.
13+
14Downgrading could be very difficult once the upgrade has been
15started. Going back to 2.0.20 may not be possible.
16
17* Do not run the schema change while the server is running.
18+
19This upgrade changes the primary key of a table, an operation
20which shouldn't occur while end-users are able to make
21modifications to the database. I _strongly_ suggest a full
22shutdown, schema upgrade, then startup approach for this release.
23
24* There may be some duplicate keys
25+
26This upgrade removes a column from the primary key of a table,
27which may result in duplicates being found. You can search
28for these duplicates before updating:
29{{{
30SELECT account_id,external_id FROM account_external_ids e
31WHERE e.external_id IN (SELECT external_id
32FROM account_external_ids
33GROUP BY external_id
34HAVING COUNT(*) > 1);
35}}}
36Resolving duplicates is left up to the administrator, in
37general though you will probably want to remove one of the
38duplicate records. E.g. in one case I had 3 users with the
39same mailing list email address registered. I just deleted
40those and sent private email asking the users to use their
41personal/work address instead of a mailing list.
42Apply the database specific schema script:
43----
44 java -jar gerrit.war --cat sql/upgrade017_018_postgres.sql | psql reviewdb
45 java -jar gerrit.war --cat sql/upgrade017_018_mysql.sql | mysql reviewdb
46----
47
48
Yuxuan 'fishy' Wang4f5ad9d2016-05-03 16:18:58 -070049== Important Notices
Shawn O. Pearcec20e2832010-02-17 09:16:26 -080050
51* Prior User Sessions
52+
53The cookie used to identify a signed-in user has been changed.
54Again. All users will be automatically signed-out during
55this upgrade, and will need to sign-in again after the upgrade
56is complete. The new schema has more room for extensions, so
57this might be the last time we will need to invalidate sessions.
58
59* Harmless error on first startup
60+
61Starting 2.0.21 on an instance which previously had the diff
62cache stored on disk will result in the following non-fatal error
63in the server logs during the first launch of .21 on that system:
64----
652009-09-02 18:50:07,446::INFO : com.google.gerrit.server.cache.CachePool - Enabling disk cache /home/gerrit2/android_codereview/disk_cache
66Sep 2, 2009 6:50:07 PM net.sf.ehcache.store.DiskStore readIndex
67SEVERE: Class loading problem reading index. Creating new index. Initial cause was com.google.gerrit.server.patch.DiffCacheKey
68java.lang.ClassNotFoundException: com.google.gerrit.server.patch.DiffCacheKey
69 at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
70 at java.security.AccessController.doPrivileged(Native Method)
71 at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
72...
73----
74 This error can be safely ignored. It is caused by a change
75 in the diff cache's on disk schema, invalidating all existing
76 cache entries.
77
78* Significantly larger "diff" cache
79+
80The diff cache schema change noted above changed the element
81stored in the cache from per-file to per-patchset. That is,
82a patch set which modifies 500 files will now occupy only 1
83element in the diff cache, rather than 500 distinct elements.
84Accordingly, the default `cache.diff.memoryLimit` setting has
85been reduced to 128.
86
87* Removed configuration settings
88+
89The following configuration settings are no longer honored:
90`cache.maxAge`, `cache.memoryLimit`, `cache.diskLimit`, and
91`cache.diskBuffer`. These settings may now only be set on a
92per-cache basis (e.g. `cache.diff.maxAge`).
93
94* Connection pool recommendation: Apache Commons DBCP
95+
96All of the servers I run now use Apache Commons DBCP instead
97of c3p0 for their connection pools, and the setup guide and
98sample jetty_gerrit.xml reference DBCP now.
99We've run into problems with c3p0 under high loads, or when
100the connection pool is completely exhausted. DBCP seems to
101fail more gracefully, and seems to give us less trouble.
102Changing pool implementations is not required, c3p0 is still
103a supported provider. I just want to make it clear that I no
104longer recommend it in production.
105
Yuxuan 'fishy' Wang4f5ad9d2016-05-03 16:18:58 -0700106== New Features
Shawn O. Pearcec20e2832010-02-17 09:16:26 -0800107
108* GERRIT-189 Show approval status in account dashboards
109+
110Account dashboards now show a summary of the approval status on
111each change. Unreviewed changes are now highlighted to bring
112the reviewer's attention to them. Tooltips when hovering over
113a cell will bring up slightly more detailed information.
114
115* GERRIT-276 Allow users to see what groups they are members of
116+
117Under Settings > Groups a user can now view what groups Gerrit
118has placed them into. This may help administrators to debug
119a user's access problems, as they can ask the user to verify
120Gerrit is seeing what they expect.
121
122* GERRIT-276 Show simple properties of an LDAP group
123+
124If auth.type is HTTP_LDAP, groups which are marked as automatic
125membership now show non-repeating LDAP attributes below their
126description under Admin > Groups. This display should help an
127administrator to verify that Gerrit has mapped an LDAP group
128correctly.
129
130* Move Patch entity out of database and store in cache
131+
132The `patches` database table has been deleted, Gerrit now makes
133the list of affected files on the fly and stores it within the
134diff cache. This change is part of a long-running series to
135remove redundant information from the database before we switch
136to a pure Git backed data storage system.
137
138* Only copy blocking negative votes to replacement patch
139+
140Previously Gerrit copied any negative vote in any approval
141category whenever a replacement patch set was uploaded to
142a change. Now Gerrit only copies "Code Review -2".
143This change should make it easier for reviewers (and scripts
144scanning `patch_set_approvals`) to identify updated changes
145which might require a new review.
146Adminstrators who have created their own categories and want to
147copy the blocking negative vote should set `copy_min_score = 'Y'`
148in the corresponding approval_categories records.
149
150* show-caches: Make output more concise
151+
152Instead of showing ~12 lines of output per cache, each cache is
153displayed as one line of a table.
154
155* Handle multiple accountBase and groupBase
156+
157ldap.accountBase and ldap.groupBase may now be specified multiple
158times in gerrit.config, to search more than one subtree within
159the directory.
160
161* Summarize collapsed comments
162+
163Collapsed comments (both inline on a file and on the change
164itself) now show a short summary of the comment message, making
165it faster to locate the relevant comment to expand for more
166detailed reading.
167
168* Edit inline drafts on Publish Comments screen
169+
170Inline comment drafts may now be directly edited on the Publish
171Comments screen, which can be useful for fixing up a minor typo
172prior to publication.
173
174* Less toggly thingies on change screen
175+
176The change description and the approvals are no longer nested
177inside of a foldy block. Most users never collapse these, but
178instead just scroll the page to locate the information they are
179looking for.
180
181* Restore Enter/o to toggle collapse state of comments
182+
183Enter and 'o' now expand or collapse an inline comment on the
184the current row of a file.
185
186* Display abbreviated hexy Change-Id in screen titles
187* Use hexy Change-Id in emails sent from Gerrit
188+
David Pursehouse4d7ac772013-06-25 17:14:30 +0900189Change-Id abbreviations are now used through more of the UI,
Shawn O. Pearcec20e2832010-02-17 09:16:26 -0800190including emails sent by Gerrit and window/page titles. This
191change breaks email threading for any existing review emails.
192That is comments on a change created before the upgrade will
193not appear under the original change notification thread.
194
195* Add sendemail.from to control setting From header
196+
197Gerrit no longer forges the From header in notification emails.
198To enable the prior forging behavior, set `sendemail.from`
199to `USER` in gerrit.config. For more details see
Chad Horohoefa084bb2012-09-04 12:35:40 -0400200link:http://gerrit.googlecode.com/svn/documentation/2.0/config-gerrit.html#sendemail.from[sendemail.from]
Shawn O. Pearcec20e2832010-02-17 09:16:26 -0800201
Yuxuan 'fishy' Wang4f5ad9d2016-05-03 16:18:58 -0700202== Bug Fixes
Shawn O. Pearcec20e2832010-02-17 09:16:26 -0800203
204* Fix ReviewDb to actually be per-request scoped
205+
206When we switched to Guice a misconfiguration allowed Guice to
207give out multiple database connections per web or SSH request.
208This could exhaust the connection pool faster than expected.
209
210* Send no-cache headers during HTTP login
211+
212An oversight in the HTTP login code path may have allowed a proxy
213server between the user's browser and the Gerrit server to cache
214a user's session cookie. Fixed by sending the correct no-cache
215headers, disallowing any caching of the authentication response.
216
217* Fix project owner permissions
218+
219Folks reported on repo-discuss that a project owner also had to
220have READ permission to use the Branches tab of their project.
221This was a regression introduced when we refactored some of the
222code when adding Guice to the project. Fixed.
223
224* GERRIT-277 Fix hyperlinks in messages
225+
226Hyperlinks in commit messages such as "<http://foo>" were
227including the trailing > in the URL, making the link broken.
228The trailing > is now properly not included in the URL.
229
230* GERRIT-266 Fix web session cookie refresh time
231+
232In 2.0.19 we introduced web sessions stored in Ehcache, but the
233logic was causing sessions to expire roughly half-way through the
234`cache.web_sessions.maxAge` time. At the default setting, active
235sessions were expiring after 6 hours. The cache management has
236been refactored to make this a lot less likely.
237
238* Cleanup not signed in error to be more user friendly
239+
240The error message which comes up when your session is expired
241is now much more useful. From the dialog you can restart your
242session by clicking the "Sign-In" button, and return to the
243screen you are currently on.
244
245* Fix commit-msg hook to work with commit -v option
246+
247The commit-msg hook was buggy and did not handle `git commit -v`
248correctly. It also did some bad insertions, placing the magic
249`Change-Id: I...` line at the wrong position in the commit
250message. The updated hook resolves most of these problems,
251but must be recopied to individual Git repositories by end-users.
252
253* Identify PGP configuration errors during startup
254+
255If the encrypted contact store is enabled, the required encryption
256algorithms are checked at startup to ensure they are enabled
257in the underlying JVM. This is necessary in case the JVM is
258updated and the administrator forgot to install the unlimited
259strength policy file in the new runtime directory. Recently
260review.source.android.com was bitten by just such an upgrade.
261
262* GERRIT-278 Fix missing reply comments on old patch set
263+
264Some comments were not visible because they were replies made
265to a comment on say patch set 1 while looking at the difference
266between patch set 1 and patch set 2 of a change. Fixed.
267
268* Make external_id primary key of account_external_ids
269+
270The database schema incorrectly allowed two user accounts to have
271the same email address, or to have the same OpenID auth token.
272Fixed by asserting a unique constraint on the column.
273
Yuxuan 'fishy' Wang4f5ad9d2016-05-03 16:18:58 -0700274== Other Changes
Shawn O. Pearcec20e2832010-02-17 09:16:26 -0800275* Start 2.0.21 development
276* Support cleaning up a Commons DBCP connection pool
277* Clarify which Factory we are importing in ApproveComma...
278* Avoid loading Patch object in /cat/ servlet
279* Remove unnecessary reference of patch key in save draft
280* GERRIT-266 Tweak cache defaults to be more reasonable
281* Merge change I131e6c4c
282* Bring back the "No Differences" message when files are...
283* Pick up gwtorm 1.1.2-SNAPSHOT
284* Refactor GroupListScreen's inner table for reuse
285* Do not normalize approval scores on closed changes in ...
286* Don't obtain 0 approvals or submit approvals in dashbo...
287* Update JGit to 0.5.0-93-g5b89a2c
288* Add tests for Change-Id generating commit-msg hook
289* Add test for commit-msg with commit -v
290* Fix formatting error in ApprovalCategory
291* Fix typo in change table column header "Last Update"
292* Fix reference to the All Projects broken when we remov...
293* Use category abbreviations in the dashboard approval c...
294* Format approvals columns in change tables with minimal...
295* Shrink the Last Updated column in dashboards and chang...
296* Highlight changes which need to be reviewed by this us...
297* Fix typo in ChangeTable comment
298* Reduce the window used for "Mon dd" vs. "Mon dd yyyy" ...
299* Don't assume "Anonymous Users" and "Registered Users" ...
300* Log encrypted contact store failures
301* Identify PGP configuration errors during startup
302* Take the change description block out of the disclosure...
303* Move the approval table out of a disclosure panel
304* Explicitly show what value is needed to submit
305* Modernize the display of comments on a change
306* Modernize the display of inline comments on a file
307* Fix "Publish Comments" when there are no inline drafts
308* Merge change 11666
309* Fix display of "Gerrit Code Review" authored comments
310* Fix source code formatting error in FormatUtil
311* Remove unnecessary fake author on inline comments
312* Auto expand all drafts on publish comments screen
313* Remove unused local variable in PublishCommentsScreen
314* Remove unused import from PublishCommentsScreen
315* Use gwtorm, gwtexpui release versions
316* Add javadoc for Change.getKey
317* Updated documentation for eclipse development.
318* Merge change 11698
319* Merge change 11699
320* Merge change 11700
321* Merge change 11703
322* Merge change 11705
323* Moved creation of GerritPersonIdent to a separate provi...
324* Remove unused dependency on GerritServer.
325* Renamed GerritServert to GitRepositoryManager and moved...
326* Remove declaration of OrmException that is never thrown.
327* Increase margin space between buttons of comment editors
328* Simplify GerritCallback error handling
329* Correct comment documenting SignInDialog
330* Remove unused CSS class gerrit-ErrorDialog-ErrorMessage
331* Clarify become any account servlet errors
332* Fix anchor in sshd.reuseAddress documentation
333* Extract parametrized string formatting out of LdapQuery
334* Make cache APIs interfaces for mocking
335* Add easymock 2.5.1 to our test dependencies
336* Add sendemail.from to control setting From header
337* gerrit 2.0.21