Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
synapse
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Timo Ley
synapse
Commits
e541bb9e
Unverified
Commit
e541bb9e
authored
2 years ago
by
Patrick Cloke
Committed by
GitHub
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Rework stream token to stop caring about groups. (#12897)
parent
d0e40dfe
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
changelog.d/12897.removal
+1
-0
1 addition, 0 deletions
changelog.d/12897.removal
synapse/streams/events.py
+2
-2
2 additions, 2 deletions
synapse/streams/events.py
synapse/types.py
+5
-1
5 additions, 1 deletion
synapse/types.py
with
8 additions
and
3 deletions
changelog.d/12897.removal
0 → 100644
+
1
−
0
View file @
e541bb9e
Remove support for the non-standard groups/communities feature from Synapse.
This diff is collapsed.
Click to expand it.
synapse/streams/events.py
+
2
−
2
View file @
e541bb9e
...
@@ -54,7 +54,6 @@ class EventSources:
...
@@ -54,7 +54,6 @@ class EventSources:
push_rules_key
=
self
.
store
.
get_max_push_rules_stream_id
()
push_rules_key
=
self
.
store
.
get_max_push_rules_stream_id
()
to_device_key
=
self
.
store
.
get_to_device_stream_token
()
to_device_key
=
self
.
store
.
get_to_device_stream_token
()
device_list_key
=
self
.
store
.
get_device_stream_token
()
device_list_key
=
self
.
store
.
get_device_stream_token
()
groups_key
=
self
.
store
.
get_group_stream_token
()
token
=
StreamToken
(
token
=
StreamToken
(
room_key
=
self
.
sources
.
room
.
get_current_key
(),
room_key
=
self
.
sources
.
room
.
get_current_key
(),
...
@@ -65,7 +64,8 @@ class EventSources:
...
@@ -65,7 +64,8 @@ class EventSources:
push_rules_key
=
push_rules_key
,
push_rules_key
=
push_rules_key
,
to_device_key
=
to_device_key
,
to_device_key
=
to_device_key
,
device_list_key
=
device_list_key
,
device_list_key
=
device_list_key
,
groups_key
=
groups_key
,
# Groups key is unused.
groups_key
=
0
,
)
)
return
token
return
token
...
...
This diff is collapsed.
Click to expand it.
synapse/types.py
+
5
−
1
View file @
e541bb9e
...
@@ -639,7 +639,7 @@ class StreamToken:
...
@@ -639,7 +639,7 @@ class StreamToken:
6. `push_rules_key`: `541479`
6. `push_rules_key`: `541479`
7. `to_device_key`: `274711`
7. `to_device_key`: `274711`
8. `device_list_key`: `265584`
8. `device_list_key`: `265584`
9. `groups_key`: `1`
9. `groups_key`: `1`
(note that this key is now unused)
You can see how many of these keys correspond to the various
You can see how many of these keys correspond to the various
fields in a
"
/sync
"
response:
fields in a
"
/sync
"
response:
...
@@ -691,6 +691,7 @@ class StreamToken:
...
@@ -691,6 +691,7 @@ class StreamToken:
push_rules_key
:
int
push_rules_key
:
int
to_device_key
:
int
to_device_key
:
int
device_list_key
:
int
device_list_key
:
int
# Note that the groups key is no longer used and may have bogus values.
groups_key
:
int
groups_key
:
int
_SEPARATOR
=
"
_
"
_SEPARATOR
=
"
_
"
...
@@ -722,6 +723,9 @@ class StreamToken:
...
@@ -722,6 +723,9 @@ class StreamToken:
str
(
self
.
push_rules_key
),
str
(
self
.
push_rules_key
),
str
(
self
.
to_device_key
),
str
(
self
.
to_device_key
),
str
(
self
.
device_list_key
),
str
(
self
.
device_list_key
),
# Note that the groups key is no longer used, but it is still
# serialized so that there will not be confusion in the future
# if additional tokens are added.
str
(
self
.
groups_key
),
str
(
self
.
groups_key
),
]
]
)
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment