Update git submodules
* Update plugins/replication from branch 'master'
to 7ad27c7ac49731e70dd5ad3691b0b410492792f0
- Merge branch 'stable-3.2' into master
* stable-3.2:
ReplicationTasksStorage: Remove synchronized from list* methods
TasksStorage: Add unit tests for reset() and resetAll()
TasksStorage: Add canStartDifferentUris unit test
ReplicationIT: Use streams to simplify
ReplicationIT: Use PushOne.ALL_REFS constant
ReplicationTasksStorageTest: Add a test for start()
ReplicationTasksStorage: Remove test-only list* methods
Fix synopsis in replication start cmd documentation
TaskStorage: Fix assertContainsExactly
TaskStorage: Rename unit tests with 'persist' in their names
Don't wait for pending events to process on startup
ReplicateRefUpdate: Drop awkward constructor
TasksStorage: Replace delete() with start()+finish() in tests
ReplicationTasksStorage.Task: Add unit tests
ReplicationTasksStorage: Add unit tests
Change-Id: I2ebe8f3bf299a806726b2feba704750dc2edf239
- Merge branch 'stable-3.1' into stable-3.2
* stable-3.1:
ReplicationTasksStorage: Remove synchronized from list* methods
TasksStorage: Add unit tests for reset() and resetAll()
TasksStorage: Add canStartDifferentUris unit test
ReplicationIT: Use streams to simplify
ReplicationIT: Use PushOne.ALL_REFS constant
ReplicationTasksStorageTest: Add a test for start()
ReplicationTasksStorage: Remove test-only list* methods
Fix synopsis in replication start cmd documentation
TaskStorage: Fix assertContainsExactly
TaskStorage: Rename unit tests with 'persist' in their names
Don't wait for pending events to process on startup
ReplicateRefUpdate: Drop awkward constructor
TasksStorage: Replace delete() with start()+finish() in tests
ReplicationTasksStorage.Task: Add unit tests
ReplicationTasksStorage: Add unit tests
Change-Id: I3f9ec778fdfa2e8565e0a5fb0f85c67a0420e131
- Merge "Merge branch 'stable-3.0' into stable-3.1" into stable-3.1
- ReplicationTasksStorage: Remove synchronized from list* methods
These synchronized statements were added to make the tests pass.
However, they have undesirable behavior when considering production
systems (such as the concern raised in [1]).
[1] https://gerrit-review.googlesource.com/c/plugins/replication/+/280357/comment/757c5227_0de2800d/
Change-Id: I5556ea318aed400eb43c60fdbda41106dd4a17ff
- Merge branch 'stable-3.0' into stable-3.1
* stable-3.0:
Fix synopsis in replication start cmd documentation
Don't wait for pending events to process on startup
Change-Id: Icea01fdde4004a358698cc853cf46a78e2ce1e54
- Merge branch 'stable-2.16' into stable-3.0
* stable-2.16:
Fix synopsis in replication start cmd documentation
Don't wait for pending events to process on startup
Change-Id: If4bc69761a19a0137301535759dc8a317ea04186
- Merge changes I3a1c33a4,I66f9fd6c into stable-3.1
* changes:
TasksStorage: Add unit tests for reset() and resetAll()
TasksStorage: Add canStartDifferentUris unit test
- TasksStorage: Add unit tests for reset() and resetAll()
Change-Id: I3a1c33a4257ec02069bfc4dad21479fc0b18f879
- TasksStorage: Add canStartDifferentUris unit test
Change-Id: I66f9fd6cb7afb849b0468deeec78bfc1a8860de0
- ReplicationIT: Use streams to simplify
Replace a couple for loops with stream.forEach().
Change-Id: I7408bd24c1323737ed3d83b53ecb24a0b2db95c4
- ReplicationIT: Use PushOne.ALL_REFS constant
Instead of using a handcrafted string, exactly match the expected value.
Change-Id: I5262c5954afbf8211752c93c30f8082c5b2d677a
- ReplicationTasksStorageTest: Add a test for start()
Also add missing asserts in the
instancesOfTheSameStorageHaveTheSameElements() test.
Change-Id: I68f533b2158326c9bfd035778d750c5cf5c35665
- ReplicationTasksStorage: Remove test-only list* methods
Tests should be accurate enough to list from the correct storage areas.
If tests aren't accurate enough when doing so, then the tests should be
improved to provide that accuracy.
The updated ReplicationIT and ReplicationFanoutIT tests should be
investigated in a follow up as tests that currently have an ambiguous
expected state for tasks. For now, they're worked around by considering
both running and waiting tasks. As integration tests, these tests
should be fixed to test behavior, not the specific implementation of
the storage layer.
Partially reverts Ie164b03579cc917f1095cfde6d77cab630f77759.
Change-Id: I021ad40e35e9f1c9d7076bb6984c864743be829f
- Fix synopsis in replication start cmd documentation
--url is usable with --all or projects and on its own. Update the
usage to reflect this.
Change-Id: Id3637f7bf61b7f65348b19ec0616808ef3f44ccf
- TaskStorage: Fix assertContainsExactly
Update private helper assertContainsExactly() to ensure that we
have exactly one element in the list and also make it generic so
that it can be used against any list, for example listWaiting()
or listRunning()
Change-Id: I93b9f220dd865decbf8fd18240e5a47fb2042115
- TaskStorage: Rename unit tests with 'persist' in their names
Stop using 'persist' in test names as the persist() method no longer
exists in ReplicationTasksStorage. The test names should have been
updated during merge when the API changed. In test names, where
'persist' is an action, use 'create'. When 'persist' is a state, use
appropriate state, i.e 'waiting' or 'running'.
Change-Id: I4e4683e0692695452b6ec6ae9765210db11a165e
- Don't wait for pending events to process on startup
Previously, on large Gerrit installations with many projects and/or many
replication destinations, the replication plugin could take very long
periods of time to startup. This was particularly a problem if the
pending(persisted) event count was large as they all were rescheduled
before the plugin finished initializing. Change this behavior so that
startup merely begins the process of scheduling the pending events, but
does not wait for them to complete.
Bug: Issue 12769
Change-Id: I224c2ce2a35f987af2343089b9bb00a7fcb7e3be
- ReplicateRefUpdate: Drop awkward constructor
A constructor taking an object with a set of refs and also one of those
refs is an awkward pattern. Remove that code by using a small helper in
the UriUpdates interface.
Change-Id: I999e57b405d009307bca023e5b9aa7f40c71fb58
- TasksStorage: Replace delete() with start()+finish() in tests
During the merge of stable-3.0, the delete() method was re-added [1]
to fix a test that relied upon it. Instead, that test should have been
updated to use the start() and finish() methods that are part of the
public API for ReplicationTasksStorage.
To facilitate that update, modify the start(), reset(), and finish()
methods to not require a PushOne object. These methods can instead
use a new interface that PushOne already can implement without
functional changes. This interface avoids duplicate code in
ReplicationTasksStorage.
[1] https://gerrit-review.googlesource.com/c/plugins/replication/+/273660/-1..4/src/main/java/com/googlesource/gerrit/plugins/replication/ReplicationTasksStorage.java
Change-Id: Id82d2ec3125075832134c8dbe56b342e5a874bbc
- ReplicationTasksStorage.Task: Add unit tests
Change-Id: Ia3a2cefa55d59e5ee96ccd2bf14c9f669a9bb9d1
- Merge branch 'stable-3.0' into stable-3.1
* stable-3.0:
ReplicationTasksStorage: Add unit tests
Change-Id: Ic4d28918223e8b4f3b0d8a83b1c987be22d8db45
- Merge branch 'stable-2.16' into stable-3.0
* stable-2.16:
ReplicationTasksStorage: Add unit tests
Change-Id: I8095d012b5cfa497267b6ef027f697c7e8369533
- ReplicationTasksStorage: Add unit tests
Change-Id: I164426e70937bc3c4ac426be3056a01e9229746b
diff --git a/plugins/replication b/plugins/replication
index 9a07d19..7ad27c7 160000
--- a/plugins/replication
+++ b/plugins/replication
@@ -1 +1 @@
-Subproject commit 9a07d19326cab1dccbab5696c31f89dc8cb2e8a6
+Subproject commit 7ad27c7ac49731e70dd5ad3691b0b410492792f0