mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-03 18:44:51 -04:00
* Revert "Add experimental support for sharding event persister. (#8170)"
This reverts commit 82c1ee1c22
.
* Changelog
This commit is contained in:
parent
be16ee59a8
commit
9f8abdcc38
19 changed files with 78 additions and 206 deletions
|
@ -231,12 +231,8 @@ class MultiWriterIdGenerator:
|
|||
# gaps should be relatively rare it's still worth doing the book keeping
|
||||
# that allows us to skip forwards when there are gapless runs of
|
||||
# positions.
|
||||
#
|
||||
# We start at 1 here as a) the first generated stream ID will be 2, and
|
||||
# b) other parts of the code assume that stream IDs are strictly greater
|
||||
# than 0.
|
||||
self._persisted_upto_position = (
|
||||
min(self._current_positions.values()) if self._current_positions else 1
|
||||
min(self._current_positions.values()) if self._current_positions else 0
|
||||
)
|
||||
self._known_persisted_positions = [] # type: List[int]
|
||||
|
||||
|
@ -366,7 +362,9 @@ class MultiWriterIdGenerator:
|
|||
equal to it have been successfully persisted.
|
||||
"""
|
||||
|
||||
return self.get_persisted_upto_position()
|
||||
# Currently we don't support this operation, as it's not obvious how to
|
||||
# condense the stream positions of multiple writers into a single int.
|
||||
raise NotImplementedError()
|
||||
|
||||
def get_current_token_for_writer(self, instance_name: str) -> int:
|
||||
"""Returns the position of the given writer.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue