Merge changes Ida91cf7a,I34e51849
* changes:
RefAdvertisementIT: Remove comment about enabled NoteDb
RefAdvertisementIT: Simplify some tests
diff --git a/Documentation/access-control.txt b/Documentation/access-control.txt
index 1d1f17e..c514321 100644
--- a/Documentation/access-control.txt
+++ b/Documentation/access-control.txt
@@ -834,7 +834,7 @@
[[category_view_private_changes]]
=== View Private Changes
-This category permits users to view all private changes.
+This category permits users to view all private changes and all change edit refs.
The change owner and any explicitly added reviewers can always see
private changes (even without having the `View Private Changes` access
diff --git a/Documentation/dev-contributing.txt b/Documentation/dev-contributing.txt
index a1342d3..6dce1e6 100644
--- a/Documentation/dev-contributing.txt
+++ b/Documentation/dev-contributing.txt
@@ -321,16 +321,44 @@
[[process]]
== Process
+[[dev-in-stable-branches]]
+=== Development in stable branches
+
+As their name suggests stable branches are intended to be stable. This means that generally
+only bug-fixes should be done on stable branches, however this is not strictly enforced and
+exceptions may apply:
+
+ * When a stable branch is initially created to prepare a new release the Gerrit community
+ discusses on the mailing list if there are pending features which should still make it into the
+ release. Those features are blocking the release and should be implemented on the stable
+ branch before the first release candidate is created.
+ * To stabilize the code before doing a major release several release candidates are created. Once
+ the first release candidate was done no more features should be accepted on the stable branch.
+ If more features are found to be required they should be discussed with the Gerrit maintainers
+ and should only be allowed if the risk of breaking things is considered to be low.
+ * Once a major release is done only bug-fixes and documentation updates should be done on the
+ stable branch. These updates will be included in the next minor release.
+ * For minor releases new features are only acceptable if they are important to the Gerrit
+ community, if they are backwards compatible and the risk of breaking things is low and if there
+ are no objections from the Gerrit community.
+ * In cases of doubt it's the responsibility of the release maintainer to evaluate the risk of new
+ features and make a decision based on these rules and opinions from the Gerrit community.
+ * The older a stable branch is the more stable it should be. This means old stable branches
+ should only receive bug-fixes that are either important or low risk. Security fixes, including
+ security updates for third party dependencies, are always considered as important and hence can
+ always be done on stable branches.
+
=== Backporting to stable branches
From time to time bug fix releases are made for existing stable branches.
-Developers concerned with stable branches are encouraged to backport or push
-patchsets to these branches, even if no new release is planned.
+Developers concerned with stable branches are encouraged to backport or push fixes to these
+branches, even if no new release is planned. Backporting features is only possible in compliance
+with the rules link:#dev-in-stable-branches[above].
-Fixes that are known to be needed for a particular release should be pushed
-for review on that release's stable branch. It will then be included in
-the master branch when the stable branch is merged back.
+Fixes that are known to be needed for a particular release should be pushed for review on that
+release's stable branch. They will then be included into the master branch when the stable branch
+is merged back.
=== Finding starter projects to work on
@@ -363,20 +391,21 @@
developers can agree and rely on.
General process:
-* Make sure that the feature (e.g. a field on the API) is not needed anymore or blocks
- further development or improvement. If in doubt, consult the mailing list.
-* If you can provide a schema migration that moves users to a comparable feature, do
- so and stop here.
-* Mark the feature as deprecated in the documentation and release notes.
-* If possible, mark the feature deprecated in any user-visible interface. For example,
- if you are deprecating a Git push option, add a message to the Git response if
- the user provided the option informing them about deprecation.
-* Annotate the code with `@Deprecated` and `@RemoveAfter(x.xx)` if applicable.
- Alternatively, use `// DEPRECATED, remove after x.xx` (where x.xx is the version
- number that has to be branched off before removing the feature)
-* Gate the feature behind a config that is off by default (forcing admins to turn
- the deprecated feature on explicitly).
-* After the next release was branched off, remove any code that backed the feature.
+
+ * Make sure that the feature (e.g. a field on the API) is not needed anymore or blocks
+ further development or improvement. If in doubt, consult the mailing list.
+ * If you can provide a schema migration that moves users to a comparable feature, do
+ so and stop here.
+ * Mark the feature as deprecated in the documentation and release notes.
+ * If possible, mark the feature deprecated in any user-visible interface. For example,
+ if you are deprecating a Git push option, add a message to the Git response if
+ the user provided the option informing them about deprecation.
+ * Annotate the code with `@Deprecated` and `@RemoveAfter(x.xx)` if applicable.
+ Alternatively, use `// DEPRECATED, remove after x.xx` (where x.xx is the version
+ number that has to be branched off before removing the feature)
+ * Gate the feature behind a config that is off by default (forcing admins to turn
+ the deprecated feature on explicitly).
+ * After the next release was branched off, remove any code that backed the feature.
You can optionally consult the mailing list to ask if there are users of the feature you
wish to deprecate. If there are no major users, you can remove the feature without
diff --git a/polygerrit-ui/app/elements/shared/gr-js-api-interface/gr-js-api-interface_test.html b/polygerrit-ui/app/elements/shared/gr-js-api-interface/gr-js-api-interface_test.html
index 78fba83..e0c7c37 100644
--- a/polygerrit-ui/app/elements/shared/gr-js-api-interface/gr-js-api-interface_test.html
+++ b/polygerrit-ui/app/elements/shared/gr-js-api-interface/gr-js-api-interface_test.html
@@ -441,11 +441,11 @@
test('installing preloaded plugin', () => {
let plugin;
- window.ASSETS_PATH = 'http://blips.com/chitz';
+ window.ASSETS_PATH = 'http://blips.com/chitz/';
Gerrit.install(p => { plugin = p; }, '0.1', 'preloaded:foo');
assert.strictEqual(plugin.getPluginName(), 'foo');
assert.strictEqual(plugin.url('/some/thing.html'),
- 'http://blips.com/chitz/plugins/foo/some/thing.html');
+ 'http://blips.com/plugins/foo/some/thing.html');
delete window.ASSETS_PATH;
});
diff --git a/polygerrit-ui/app/elements/shared/gr-js-api-interface/gr-public-js-api.js b/polygerrit-ui/app/elements/shared/gr-js-api-interface/gr-public-js-api.js
index 8bf4a2d..36a428d 100644
--- a/polygerrit-ui/app/elements/shared/gr-js-api-interface/gr-public-js-api.js
+++ b/polygerrit-ui/app/elements/shared/gr-js-api-interface/gr-public-js-api.js
@@ -217,14 +217,9 @@
};
Plugin.prototype.url = function(opt_path) {
- const relPath = '/plugins/' + this._name + (opt_path || '/');
- if (window.location.origin === this._url.origin) {
- // Plugin loaded from the same origin as gr-app, getBaseUrl in effect.
- return this._url.origin + Gerrit.BaseUrlBehavior.getBaseUrl() + relPath;
- } else {
- // Plugin loaded from assets bundle, expect assets placed along with it.
- return this._url.href.split('/plugins/' + this._name)[0] + relPath;
- }
+ const base = Gerrit.BaseUrlBehavior.getBaseUrl();
+ return this._url.origin + base + '/plugins/' +
+ this._name + (opt_path || '/');
};
Plugin.prototype.screenUrl = function(opt_screenName) {