Erik Johnston
b32121a5d1
Unused import
2016-02-03 10:30:56 +00:00
Daniel Wagner-Hall
2df6114bc4
Log more diagnostics for unrecognised access tokens
2016-02-02 19:21:49 +00:00
Daniel Wagner-Hall
d83d004ccd
Fix flake8 warnings for new flake8
2016-02-02 17:18:50 +00:00
Erik Johnston
8a391e33ae
s/get_room_changes_for_user/get_membership_changes_for_user/
2016-02-02 16:12:10 +00:00
Erik Johnston
477b1ed6cf
Fetch events in a separate transaction.
...
This has a couple of benefits:
- It reduces the time of transactions, allowing other database requests
to run.
- Fetching events is given a dedicated database thread, and so can't
starve other database requests.
2016-02-02 15:58:14 +00:00
Erik Johnston
04ad93e6fd
Merge pull request #545 from matrix-org/erikj/sync
...
Move /sync state calculations from rest to handler
2016-02-02 15:28:43 +00:00
Erik Johnston
65e92eca49
Change the way we do public room list fetching
2016-02-02 15:21:10 +00:00
David Baker
69214ea671
Pass make_guest whne we autogen a user ID
2016-02-02 14:42:31 +00:00
Erik Johnston
b023995538
WARN if we get a topo token instead of stream.
2016-02-02 14:11:14 +00:00
David Baker
793369791a
Merge pull request #547 from matrix-org/dbkr/fix_guest_upgrade
...
Pull guest access token out of the auth session params
2016-02-02 09:47:30 +00:00
Erik Johnston
854ca32f10
Comments
2016-02-01 16:52:27 +00:00
David Baker
d7ac861d3b
Pull guest access token out of the auth session params, otherwise it will break if you open the email on a different device.
2016-02-01 16:33:19 +00:00
Erik Johnston
89b40b225c
Order things correctly
2016-02-01 16:32:46 +00:00
Erik Johnston
4bf448be25
Switch over /events to use per room caches
2016-02-01 16:26:51 +00:00
Erik Johnston
fa48020a52
Move state calculations from rest to handler
2016-02-01 15:59:40 +00:00
Erik Johnston
2d3837bec7
Merge pull request #543 from matrix-org/erikj/sync
...
Cache get_room_changes_for_user
2016-02-01 15:05:06 +00:00
Erik Johnston
ceb6b8680a
Only use room_ids if in get_room_events_stream if is_guest
2016-02-01 10:33:52 +00:00
Erik Johnston
d98a9f2583
Don't use before_token. Its wrong. Use actual limit.
2016-01-31 13:31:15 +00:00
Erik Johnston
25c311eaf6
Cache get_room_changes_for_user
2016-01-29 16:52:48 +00:00
Erik Johnston
cc9c97e0dc
Invalidate _account_data_stream_cache correctly
2016-01-29 16:41:51 +00:00
Erik Johnston
e70165039c
If stream pos is greater then earliest known key and entity hasn't changed, then entity hasn't changed
2016-01-29 16:41:32 +00:00
Erik Johnston
c1de91aca4
Merge pull request #540 from matrix-org/erikj/sync
...
Prefill stream change caches
2016-01-29 15:52:42 +00:00
Erik Johnston
b55b90bfb4
Merge pull request #541 from matrix-org/erikj/fixsomeofpush
...
Make /events always return a newer token, if one exists
2016-01-29 15:45:35 +00:00
Erik Johnston
8da95b6f1b
Comment. Remove superfluous order by
2016-01-29 15:39:17 +00:00
Erik Johnston
13724569ec
Deal with None limit
2016-01-29 15:33:44 +00:00
Erik Johnston
4a6eb5eb45
Make /events always return a newer token, if one exists
2016-01-29 15:22:17 +00:00
Mark Haines
6927d0e091
Add missing param to the log line
2016-01-29 15:01:26 +00:00
Erik Johnston
b5dbced938
Don't prefill account data
2016-01-29 14:53:59 +00:00
Erik Johnston
3d60686c0c
Actually use cache
2016-01-29 14:49:11 +00:00
Erik Johnston
45488e0ffa
Max is not a function
2016-01-29 14:42:01 +00:00
Erik Johnston
f67d60496a
Convert param style
2016-01-29 14:41:16 +00:00
Erik Johnston
18579534ea
Prefill stream change caches
2016-01-29 14:37:59 +00:00
Mark Haines
47374a33fc
Merge remote-tracking branch 'origin/develop' into markjh/3pid
2016-01-29 14:15:12 +00:00
Mark Haines
0fcafbece8
Add config option for setting the trusted id servers, disabling checking the ID server in integration tests
2016-01-29 14:12:26 +00:00
Erik Johnston
fd142c29d9
Merge branch 'develop' of github.com:matrix-org/synapse into release-v0.12.1
2016-01-29 13:52:12 +00:00
Erik Johnston
ebc5f00efe
Bump AccountDataAndTagsChangeCache size
2016-01-29 13:37:40 +00:00
Erik Johnston
ea320d3464
Don't work out unread_notifs_for_room_id unless needed
2016-01-29 13:34:48 +00:00
Mark Haines
5687a00e4e
Allow three_pid_creds as well as threePidCreds in /account/3pid
2016-01-29 13:26:15 +00:00
Erik Johnston
b18114e19e
Merge pull request #536 from matrix-org/erikj/sync
...
Make /sync "better".
2016-01-29 13:04:51 +00:00
Erik Johnston
02a9c3be6c
Merge pull request #538 from matrix-org/erikj/fix_lru_cache
...
Fix LruCache. Make TreeCache track its own size.
2016-01-29 11:53:55 +00:00
Erik Johnston
fb7299800f
Directly set self.value
2016-01-29 11:29:14 +00:00
Erik Johnston
c046630c33
Remove spurious self.size
2016-01-29 11:17:54 +00:00
Erik Johnston
a30364c1f9
Correctly bookkeep the size of TreeCache
2016-01-29 10:44:46 +00:00
Erik Johnston
766526e114
Make TreeCache keep track of its own size.
2016-01-29 10:11:21 +00:00
Erik Johnston
50e18938a9
Reset size on clear
2016-01-29 10:00:45 +00:00
Erik Johnston
467c27a1f9
Amalgamate tags and account data stream caches
2016-01-28 18:20:00 +00:00
Erik Johnston
3f5dd18bd4
If the same as the earliest key, assume nothing has changed.
2016-01-28 18:11:41 +00:00
Erik Johnston
40431251cb
Correctly update _entity_to_key
2016-01-28 18:05:43 +00:00
Erik Johnston
82cf3a8043
Fix inequalities
2016-01-28 17:44:04 +00:00
Erik Johnston
03b2c2577c
Don't use defer.returnValue
2016-01-28 17:29:24 +00:00
Erik Johnston
0663c5bd52
Include cache hits with has_entity_changed
2016-01-28 17:27:28 +00:00
Erik Johnston
35981c8b71
Fix test
2016-01-28 17:20:05 +00:00
Erik Johnston
8fe8951a8d
Cache filters
2016-01-28 17:09:09 +00:00
Erik Johnston
fdca8ec418
Add events index
2016-01-28 16:41:59 +00:00
Erik Johnston
45cf827c8f
Change name and doc has_entity_changed
2016-01-28 16:39:18 +00:00
Erik Johnston
00cb3eb24b
Cache tags and account data
2016-01-28 16:37:41 +00:00
Erik Johnston
c23a8c7833
Ensure keys to RoomStreamChangeCache are ints
2016-01-28 15:55:26 +00:00
Erik Johnston
e1941442d4
Invalidate caches properly. Remove unused arg
2016-01-28 15:02:41 +00:00
Daniel Wagner-Hall
0935802f1e
Pin pynacl to 0.3.0
...
Something has gone wrong in the packaging of 1.* which causes it not to
compile.
2016-01-28 14:47:03 +00:00
Erik Johnston
19fd425928
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/sync
2016-01-28 14:46:08 +00:00
Erik Johnston
167d1df699
Merge pull request #534 from matrix-org/erikj/setup
...
Add a Homeserver.setup method
2016-01-28 14:45:36 +00:00
Erik Johnston
7ed2bbeb11
Clean up a bit. Add comment
2016-01-28 14:32:05 +00:00
Erik Johnston
571a566399
Change load limit params
2016-01-28 14:11:16 +00:00
Erik Johnston
3c6518ddbf
Amalgamate incremental and full sync for user
2016-01-28 14:03:48 +00:00
Erik Johnston
4e7948b47a
Allow paginating backwards from stream token
2016-01-28 11:52:34 +00:00
Erik Johnston
ba8931829b
Return correct type of token
2016-01-28 11:34:17 +00:00
Erik Johnston
61eaa6ec64
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/sync
2016-01-28 10:50:57 +00:00
Erik Johnston
c5e7c0e436
Up get_rooms_for_user cache size
2016-01-28 09:58:45 +00:00
Richard van der Hoff
e26390ca46
Merge pull request #535 from matrix-org/rav/paginate_from_stream_token
...
Make it possible to paginate forwards from stream tokens
2016-01-28 09:49:46 +00:00
Erik Johnston
a6477d5933
Remove chdir
2016-01-28 09:19:55 +00:00
Richard van der Hoff
5cba88ea7c
Make it possible to paginate forwards from stream tokens
...
In order that we can fill the gap after a /sync, make it possible to paginate
forwards from a stream token.
2016-01-27 17:42:45 +00:00
Erik Johnston
5fc9b17518
No chdir
2016-01-27 17:39:20 +00:00
Erik Johnston
fa90c180ee
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/setup
2016-01-27 17:37:33 +00:00
Erik Johnston
5610880003
Merge pull request #530 from matrix-org/erikj/server_refactor
...
Remove redundant BaseHomeServer
2016-01-27 17:36:31 +00:00
Erik Johnston
e7febf4fbb
PEP8
2016-01-27 17:33:27 +00:00
Erik Johnston
aca3193efb
Use the same path for incremental with gap or without gap
2016-01-27 17:33:27 +00:00
Erik Johnston
b97f6626b6
Add cache to room stream
2016-01-27 17:33:26 +00:00
Erik Johnston
f93ecf8783
Don't turn on profiling
2016-01-27 17:33:26 +00:00
Erik Johnston
a955cbfa49
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/setup
2016-01-27 17:22:35 +00:00
Richard van der Hoff
8c97b49886
Merge pull request #533 from matrix-org/rav/hashtest_federation
...
Fix federation for #test:matrix.org
2016-01-27 17:19:36 +00:00
Erik Johnston
2152b320c5
PEP 8
2016-01-27 17:09:17 +00:00
Richard van der Hoff
d6d60b4d6c
Federation: drop events which cause SynapseErrors
...
... rather than rejecting any attempt to federate channels which contain such
events.
2016-01-27 17:02:10 +00:00
Mark Haines
d6c831bd3d
Merge pull request #531 from matrix-org/markjh/relative_push_rules
...
Fix adding push rules relative to other rules
2016-01-27 17:13:36 +01:00
Erik Johnston
03f4569dc3
Bump version and changelog
2016-01-27 10:35:30 +00:00
Mark Haines
8c94833b72
Fix adding push rules relative to other rules
2016-01-27 10:24:20 +00:00
Erik Johnston
9fda8b5193
Don't turn on profiling
2016-01-26 18:27:23 +00:00
Erik Johnston
e4e33c743e
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/server_refactor
2016-01-26 17:30:00 +00:00
Erik Johnston
87f9477b10
Add a Homeserver.setup method.
...
This is for setting up dependencies that require work on startup. This
is useful for the DataStore that wants to read a bunch from the database
before initiliazing.
2016-01-26 15:51:06 +00:00
Erik Johnston
9959d9ece8
Remove redundated BaseHomeServer
2016-01-26 13:52:29 +00:00
David Baker
766c24b2e6
Only notify for messages in one to one rooms, not every event
...
Fixes the fact that candidate events and hangups generated notifications.
2016-01-26 10:21:41 +00:00
Mark Haines
7179fdd550
Merge pull request #528 from matrix-org/markjh/missing_yield
...
Add missing yield in push_rules set enabled
2016-01-25 21:26:30 +01:00
Erik Johnston
c887c4cbd5
Merge pull request #524 from matrix-org/erikj/sync
...
Move some sync logic from rest to handlers pacakege
2016-01-25 16:58:39 +00:00
Mark Haines
e18257f0e5
Add missing yield in push_rules set enabled
2016-01-25 16:51:56 +00:00
Erik Johnston
8431f62ebb
Merge pull request #525 from matrix-org/erikj/select_many
...
Implement a `_simple_select_many_batch`
2016-01-25 16:30:36 +00:00
Erik Johnston
f091b73e69
Merge pull request #527 from matrix-org/erikj/push_cache
...
Push: Use storage apis that are cached
2016-01-25 16:16:34 +00:00
Erik Johnston
ce6fbbea94
Merge pull request #526 from matrix-org/erikj/push_index
...
Add index to event_push_actions
2016-01-25 16:06:07 +00:00
Erik Johnston
aea5da0ef6
Guard against empty iterables
2016-01-25 15:59:29 +00:00
Erik Johnston
3a75159832
Merge pull request #521 from matrix-org/erikj/underscores
...
Underscores are allowed in user ids
2016-01-25 15:56:31 +00:00
Erik Johnston
1ebf5e3d03
Correct docstring
2016-01-25 15:53:36 +00:00
Erik Johnston
dc2647cd3d
PEP8
2016-01-25 15:48:54 +00:00
Erik Johnston
86896408b0
Add index to event_push_actions
2016-01-25 15:30:32 +00:00
Erik Johnston
53cb173663
Push: Use storage apis that are cached
2016-01-25 13:55:18 +00:00
Erik Johnston
d59c58bc95
Remove weird stuff
2016-01-25 13:38:53 +00:00
Erik Johnston
ddd25def01
Implement a _simple_select_many_batch
2016-01-25 13:36:02 +00:00
Erik Johnston
8c6012a4af
Fix tests
2016-01-25 13:12:35 +00:00
Erik Johnston
42deca50c2
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/sync
2016-01-25 12:49:45 +00:00
Erik Johnston
d685ae73b4
Merge branch 'erikj/filters' of github.com:matrix-org/synapse into develop
2016-01-25 12:35:25 +00:00
Erik Johnston
4021f95261
Move logic from rest/ to handlers/
2016-01-25 10:10:44 +00:00
Matthew Hodgson
7dd0c1730a
initial WIP of a tentative preview_url endpoint - incomplete, untested, experimental, etc. just putting it here for safekeeping for now
2016-01-24 18:47:27 -05:00
David Baker
f92fe15897
Merge pull request #523 from matrix-org/dbkr/no_push_unless_notify
...
Better fix for actions with both dont_notify and tweaks
2016-01-22 17:27:25 +00:00
David Baker
3fe8c56736
Better fix for actions with both dont_notify and tweaks
2016-01-22 17:21:58 +00:00
David Baker
60965bd7e5
Revert b4a41aa542
as it's just broken.
2016-01-22 17:21:15 +00:00
David Baker
0e0e441b33
Merge pull request #522 from matrix-org/dbkr/no_push_unless_notify
...
Don't add notifications to the table unless there's actually a 'notify' action
2016-01-22 17:06:52 +00:00
David Baker
b4a41aa542
Don't add notifications to the table unless there's actually a 'notify' action
2016-01-22 16:56:48 +00:00
Erik Johnston
db6e26bb8c
Don't mutate cached values
2016-01-22 16:03:55 +00:00
Erik Johnston
88baa3865e
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/sync
2016-01-22 15:57:12 +00:00
David Baker
7065b75bfd
Don't crash if a user has no push rule enabled entries
2016-01-22 15:13:44 +00:00
Erik Johnston
7959e8b764
Underscores are allowed in user ids
2016-01-22 14:59:49 +00:00
David Baker
52bdd1b834
Overlay the push_rules_enabled map for users, otherwise they won't be able to disable server default rules.
2016-01-22 14:58:19 +00:00
David Baker
7cd418d38e
Don't add the member functiopn if we're not using treecache
2016-01-22 13:40:37 +00:00
David Baker
cd80019eec
docs
2016-01-22 12:21:13 +00:00
David Baker
d552861346
Revert all the bits changing keys of eeverything that used LRUCaches to tuples
2016-01-22 12:18:14 +00:00
David Baker
10f76dc5da
Make LRU cache not default to treecache & add options to use it
2016-01-22 12:10:33 +00:00
David Baker
5b142788d2
Add __contains__
2016-01-22 11:49:59 +00:00
David Baker
eaa836e8ca
Docs for treecache
2016-01-22 11:47:22 +00:00
David Baker
42eae4634f
Use new invalidate_many cache invalidation to invalidate the event_push_actions cache appropriately.
2016-01-22 11:22:48 +00:00
David Baker
8acc5cb60f
Add invalidate_many here too
2016-01-22 11:22:32 +00:00
Erik Johnston
975903ae17
Sanitize filters
2016-01-22 10:41:30 +00:00
David Baker
330be18ec5
peppate
2016-01-21 19:17:32 +00:00
David Baker
f1f8122120
Change LRUCache to be tree-based so we can delete subtrees.
2016-01-21 19:16:25 +00:00
Erik Johnston
0e07f2e15d
Only fetch events for rooms and receipts
2016-01-21 16:10:37 +00:00
Erik Johnston
8f66fe6392
Cache get_unread_event_push_actions_by_room_for_user
2016-01-21 15:02:07 +00:00
Erik Johnston
3a00f13436
Only compute badge count when necessary.
...
This reverts commit d726597737
.
2016-01-21 14:56:11 +00:00
Erik Johnston
c6549117a2
Fix AttributeError
2016-01-21 14:02:14 +00:00
Erik Johnston
ed1d189e10
Merge pull request #515 from matrix-org/erikj/syn-606
...
SYN-606: Peeking does not wake up /events
2016-01-21 13:40:20 +00:00
Erik Johnston
dfe1273d14
Merge pull request #509 from matrix-org/erikj/dns_cache
...
Cache dns lookups, and use the cache if we fail to lookup servers later
2016-01-21 13:37:23 +00:00
Erik Johnston
91a222c66d
SYN-606: Peeking does not wake up /events
...
If a real user attempted to first peek into one room, and then another,
their room event stream would not be woken up for events in the later
room.
2016-01-21 13:22:26 +00:00
David Baker
930ba003f8
Remove member event rule as per SYN-607
2016-01-21 11:50:27 +00:00
David Baker
c1a3021771
Merge pull request #507 from matrix-org/push_badge_counts
...
Push badge counts
2016-01-21 10:09:11 +00:00
Erik Johnston
d049e81b10
Merge pull request #513 from matrix-org/erikj/register_user_chars
...
Don't explode when given a unicode username in /register/
2016-01-21 09:53:35 +00:00
Erik Johnston
c43b6dcc75
Fix change_password
2016-01-20 16:14:48 +00:00
David Baker
367cfab4e6
peppate
2016-01-20 16:05:09 +00:00
Erik Johnston
73ca8e5834
Whine if we give a from param to /sync
2016-01-20 15:42:57 +00:00
Erik Johnston
b088291f14
Don't explode when given a unicode username in /register/
2016-01-20 15:40:25 +00:00
Daniel Wagner-Hall
da417aa56d
Allow non-guests to peek on rooms using /events
2016-01-20 15:34:07 +00:00
David Baker
d4315bbf6b
Add index by user id on receipts_linearized
2016-01-20 15:33:27 +00:00
David Baker
3fa344c037
Add storage function to get all receipts for a user. Also add some cache invalidation to the receipts storage because there wasn't any, and remove a method that was unused.
2016-01-20 15:30:31 +00:00
David Baker
7cc047455e
Inline membership specifier
2016-01-20 13:50:28 +00:00
David Baker
d726597737
Simplify badge updating code by just updating it every time we get woken up and it's not an event
2016-01-20 13:49:00 +00:00
David Baker
2309450a76
Merge branch 'develop' into push_badge_counts
2016-01-20 13:45:13 +00:00
David Baker
746f6e0eb3
'filtered' is a list of zero or 1
2016-01-20 13:44:04 +00:00
David Baker
7441d8cc0c
Merge remote-tracking branch 'origin/develop' into push_badge_counts
2016-01-20 13:40:22 +00:00
David Baker
ccf9387d57
Merge branch 'develop' into push_badge_counts
2016-01-20 13:33:45 +00:00
David Baker
259d1ecd1d
Don't generate push actions for our own events
2016-01-20 13:24:59 +00:00
Erik Johnston
191070123d
Cache dns lookups, and use the cache if we fail to lookup servers later
2016-01-20 11:34:09 +00:00
David Baker
afb7b377f2
Merge branch 'develop' into push_badge_counts
2016-01-19 18:17:23 +00:00
Erik Johnston
af30140621
Merge pull request #506 from matrix-org/erikj/push_fast
...
Only compute unread notifications for rooms we send down stream
2016-01-19 17:31:10 +00:00
Erik Johnston
ac2842ff1e
Only compute unread notifications for rooms we send down stream
2016-01-19 17:19:53 +00:00
Erik Johnston
892ee473d9
Don't use form of get_state_for_events with None state_key
2016-01-19 17:14:46 +00:00
Erik Johnston
2818a000aa
Use split rather than endswith
2016-01-19 16:11:39 +00:00
Erik Johnston
fb5d8e58ff
Change regex cache size to 5000
2016-01-19 16:07:07 +00:00
Erik Johnston
5a7d1ecffc
Add regex cache. Only caculate push actions for users that have sent read receipts, and are on that server
2016-01-19 16:01:05 +00:00
Erik Johnston
d056a0a3d8
Handle glob -> regex errors
2016-01-19 14:43:24 +00:00
Erik Johnston
7a079adc8f
Merge pull request #477 from matrix-org/erikj/access_token_log
...
Don't log urlencoded access_tokens
2016-01-19 14:28:29 +00:00
Erik Johnston
b8518ffe65
Use all_ephemeral_by_room in incremental_sync_with_gap_for_room
2016-01-19 14:26:58 +00:00
Erik Johnston
9654ee0848
Return don't break
2016-01-19 14:24:59 +00:00
Erik Johnston
7ecd211163
Except truthy values
2016-01-19 14:22:02 +00:00
Erik Johnston
05f78b3b52
Merge pull request #504 from matrix-org/erikj/highlight_count
...
Return highlight_count in /sync
2016-01-19 13:21:48 +00:00
Erik Johnston
9a8949f022
Merge branch 'develop' of github.com:matrix-org/synapse into default_notify
2016-01-19 11:37:05 +00:00
Erik Johnston
3adcc4c86a
Return highlight_count in /sync
2016-01-19 11:35:50 +00:00
Erik Johnston
47e7963e50
Merge pull request #502 from matrix-org/erikj/push_notif_perf
...
Unread notification performance.
2016-01-19 11:27:27 +00:00
Erik Johnston
0d241e1114
Take a deepcopy of push rules before mutating them
2016-01-19 10:15:12 +00:00
Erik Johnston
f750a442f7
Update _id
2016-01-19 10:14:53 +00:00
Erik Johnston
003853e702
Preserve truthiness
2016-01-18 17:34:02 +00:00
Erik Johnston
a284ad4092
You need to escape backslashes
2016-01-18 17:20:44 +00:00
Erik Johnston
47f82e4408
Fix branch didn't check word_boundary
2016-01-18 17:04:36 +00:00
Erik Johnston
5cd2126a6a
Remove dead code
2016-01-18 16:49:46 +00:00
Erik Johnston
29c353c553
Don't split at word boundaries, actually use regex
2016-01-18 16:48:17 +00:00
Daniel Wagner-Hall
808a8aedab
Don't error on AS non-ghost user use
...
This will probably go away either when we fix our existing ASes, or when
we kill the concept of non-ghost users.
2016-01-18 16:33:05 +00:00
Daniel Wagner-Hall
74474a6d63
Pull out app service user lookup
...
I find this a lot simpler than nested try-catches and stuff
2016-01-18 16:32:33 +00:00
Erik Johnston
d16dcf642e
Drop log levels
2016-01-18 15:44:04 +00:00
Erik Johnston
7dd14e5d1c
Add comments and remove dead code
2016-01-18 15:42:23 +00:00
Erik Johnston
866fe27e78
Do for loop once at start
2016-01-18 15:29:41 +00:00
Erik Johnston
d1f56f732e
Use static for const dicts
2016-01-18 15:17:56 +00:00
Erik Johnston
0e39dcd135
Remove internal ids
2016-01-18 14:50:17 +00:00
Erik Johnston
345ff2196a
Don't edit ruleset
2016-01-18 14:50:17 +00:00
Erik Johnston
2c176e02ae
Make unit tests work
2016-01-18 14:48:50 +00:00
Erik Johnston
63485b3029
Re-enable urnead notifications
2016-01-18 14:48:30 +00:00
Erik Johnston
f59b564507
Make notifications go quicker
2016-01-18 14:48:29 +00:00
Erik Johnston
2068678b8c
Make Event objects behave more like dicts
2016-01-18 14:43:50 +00:00
Erik Johnston
cc66a9a5e3
Allow filtering events for multiple users at once
2016-01-18 14:43:50 +00:00
Daniel Wagner-Hall
ac5a4477ad
Require unbanning before other membership changes
2016-01-15 16:27:26 +00:00
Daniel Wagner-Hall
b5ce4f0427
Remove unused parameters
2016-01-15 13:54:03 +00:00
David Baker
5819b7a78c
M_INVALID_USERNAME to be consistent with the parameter name
2016-01-15 10:06:34 +00:00
David Baker
3f8db3d597
Add specific error code for invalid user names.
2016-01-14 17:21:04 +00:00
Erik Johnston
a50013fd99
Merge pull request #497 from matrix-org/erikj/max_limit
...
Clamp pagination limits to at most 1000
2016-01-14 16:28:52 +00:00
Richard van der Hoff
2978053d16
Merge branch 'release-v0.12.1' into develop
2016-01-14 15:04:08 +00:00
Daniel Wagner-Hall
2680043bc6
Require ID and as_token be unique for ASs
...
Defaults ID to as_token if not specified. This will change
when IDs are fully supported.
2016-01-14 14:34:01 +00:00
David Baker
8db451f652
Merge pull request #498 from matrix-org/push_rule_enabled_fix
...
Fix enabling & disabling push rules
2016-01-14 13:34:05 +00:00
Daniel Wagner-Hall
d14fcfd24a
Merge pull request #487 from matrix-org/daniel/forceregistration
...
Require AS users to be registered before use
2016-01-14 11:06:43 +00:00
Daniel Wagner-Hall
27927463a1
Merge pull request #494 from matrix-org/daniel/2
...
Don't start server if ASes are invalidly configured
2016-01-14 11:06:19 +00:00
Daniel Wagner-Hall
fcb6df45e5
Merge pull request #493 from matrix-org/daniel/1
...
Delete unused code
2016-01-14 11:06:14 +00:00
David Baker
a7927c13fd
Fix enabling & disabling push rules
2016-01-14 10:53:44 +00:00
Erik Johnston
339c8f0133
Clamp pagination limits to at most 1000
2016-01-14 10:22:02 +00:00
Erik Johnston
bce602eb4e
Use logger not logging
2016-01-14 09:56:26 +00:00
David Baker
12623c99b6
Use the unread notification count to send accurate badge counts in push notifications.
2016-01-13 18:55:57 +00:00
Erik Johnston
2655d61d70
Don't change signature. Return empty list
2016-01-13 17:43:39 +00:00
Erik Johnston
fcb05b4c82
Temporarily disable notification branch
2016-01-13 17:39:58 +00:00
Daniel Wagner-Hall
f6fcff3602
Don't start server if ASes are invalidly configured
2016-01-13 17:09:24 +00:00
Daniel Wagner-Hall
244b356a37
Delete unused code
2016-01-13 17:03:58 +00:00
Richard van der Hoff
49f33f6438
Add 'event' result to 'context' endpoint
...
... because the context isn't much use without the event.
2016-01-13 16:42:14 +00:00
Daniel Wagner-Hall
93afb40cd4
Skip, rather than erroring, invalid guest requests
...
Erroring causes problems when people make illegal requests, because they
don't know what limit parameter they should pass.
This is definitely buggy. It leaks message counts for rooms people don't
have permission to see, via tokens. But apparently we already
consciously decided to allow that as a team, so this preserves that
behaviour.
2016-01-13 16:41:42 +00:00
Mark Haines
9c1f853d58
Rename 'user_name' to 'user_id' in push to make it consistent with the rest of the code
2016-01-13 13:32:59 +00:00
Daniel Wagner-Hall
7d09ab8915
Require AS users to be registered before use
2016-01-13 13:19:47 +00:00
David Baker
d9db819e23
Change default pushrules back to notifying for all messages.
2016-01-13 13:15:53 +00:00
Erik Johnston
44b4fc5f50
Use compiled regex
2016-01-13 11:47:32 +00:00
Mark Haines
f4dad9f639
Merge remote-tracking branch 'origin/erikj/bulk_get_push_rules' into markjh/table_name
...
Conflicts:
synapse/storage/push_rule.py
2016-01-13 11:46:07 +00:00
Erik Johnston
8740e4e94a
bulk_get_push_rules should handle empty lists
2016-01-13 11:37:17 +00:00
Mark Haines
c0a279e808
Delete the table objects from TransactionStore
2016-01-13 11:15:20 +00:00
Mark Haines
96e400fee5
Remove the RoomsTable object
2016-01-13 11:07:32 +00:00
Erik Johnston
72ba26679b
Merge pull request #480 from matrix-org/erikj/guest_event_tightloop
...
Dont fire user_joined_room when guest hits /events
2016-01-13 11:00:50 +00:00
Erik Johnston
70dfe4dc96
Don't include old left rooms
2016-01-12 15:01:56 +00:00
Mark Haines
a8e9e0b916
Remove the PushersTable and EventPushActionsTable objects
2016-01-12 14:41:26 +00:00
Mark Haines
31de2953a3
Remove the PushRuleTable and PushRuleEnableTable objects
2016-01-12 14:36:16 +00:00
Erik Johnston
fd5c28dc52
Dont fire user_joined_room when guest hits /events
...
Firing the 'user_joined_room' signal everytime a guest hits /events
causes all presence for that room to be returned in the stream. This may
sound helpful, but causes clients to tightloop calling /events.
In general, guest users should get the initial presence from (room)
intial sync and so we don't require presence to sbsequently come down
the event stream.
2016-01-12 11:04:06 +00:00
Daniel Wagner-Hall
42aa1f3f33
Merge pull request #478 from matrix-org/daniel/userobject
...
Introduce a User object
I'm sick of passing around more and more things as tuple items around
the whole world, and needing to edit every call site every time there is
more information about a user. So pass them around together as an
object.
This object has incredibly poorly named fields because we have a
convention that `user` indicates a UserID object, and `user_id`
indicates a string. I tried to clean up the whole repo to fix this, but
gave up. So instead, I introduce a second convention. A user_object is a
User, and a user_id_object is a UserId. I may have cried a little bit.
2016-01-11 17:50:22 +00:00
Daniel Wagner-Hall
2110e35fd6
Introduce a Requester object
...
This tracks data about the entity which made the request. This is
instead of passing around a tuple, which requires call-site
modifications every time a new piece of optional context is passed
around.
I tried to introduce a User object. I gave up.
2016-01-11 17:48:45 +00:00
David Baker
b5d33a656f
Postgres doesn't like booleans
2016-01-11 17:13:52 +00:00
David Baker
fe56138142
Remove rogue 'admin'
2016-01-11 17:09:03 +00:00
Erik Johnston
8f8b884430
Don't log urlencoded access_tokens
2016-01-08 17:48:08 +00:00
Erik Johnston
29e595e5d4
Merge pull request #474 from matrix-org/erikj/core_dump
...
Turn on core dumps
2016-01-08 16:52:15 +00:00
David Baker
c232780081
Merge pull request #456 from matrix-org/store_event_actions
...
Send unread notification counts
2016-01-08 14:47:15 +00:00
Mark Haines
8677b7d698
Only use cropped thumbnails when asked for a cropped thumbnail.
...
Even though ones cropped with scale might be technically valid.
2016-01-07 18:57:15 +00:00
Erik Johnston
33bef689c1
Turn on core dumps
2016-01-07 15:34:30 +00:00
Erik Johnston
fcbe63eaad
Use logger not logging
2016-01-07 15:28:17 +00:00
Erik Johnston
5727922106
Merge pull request #473 from matrix-org/erikj/ssh_manhole
...
Change manhole to use ssh
2016-01-07 14:36:16 +00:00
Erik Johnston
5dc5e29b9c
s/telnet/ssh/
2016-01-07 14:02:57 +00:00
Erik Johnston
c9ae1d1ee5
Change manhole to use ssh
2016-01-07 13:59:02 +00:00
David Baker
daadcf36c0
This comma is actually important
2016-01-07 10:15:35 +00:00
David Baker
823b679232
more commas
2016-01-07 10:02:47 +00:00
Matthew Hodgson
6c28ac260c
copyrights
2016-01-07 04:26:29 +00:00
Matthew Hodgson
49c34dfd36
Merge pull request #472 from roblabla/patch-1
...
Config Comment mixup in captcha public/private key
2016-01-06 22:24:28 +00:00
Robin Lambertz
4106477e7f
Config Comment mixup in captcha public/private key
2016-01-06 23:19:33 +01:00
Daniel Wagner-Hall
11a974da21
Add /_matrix/versions to report supported versions
2016-01-06 18:08:52 +00:00
David Baker
09dc9854cd
comma style
2016-01-06 17:44:10 +00:00
David Baker
442fcc02f7
Merge remote-tracking branch 'origin/develop' into store_event_actions
2016-01-06 17:28:55 +00:00
David Baker
b6a585348a
Adding is_guest here won't work because it just constructs a dict of uid -> password hash
2016-01-06 17:16:02 +00:00
Mark Haines
4cec90a260
Pass whether the user was a guest to some of the event streams
2016-01-06 16:54:57 +00:00
Mark Haines
392773ccb2
Guest users must be joined to a room to see it in /sync
2016-01-06 16:44:13 +00:00
Daniel Wagner-Hall
bf32922e5a
Log when starting stats reporting
2016-01-06 14:13:34 +00:00
Daniel Wagner-Hall
797691f908
Log on stats scheduling
2016-01-06 14:04:27 +00:00
Daniel Wagner-Hall
5880de186b
Log when we skip daily messages
2016-01-06 13:52:16 +00:00
David Baker
992928304f
Delete notifications for redacted events
2016-01-06 11:58:46 +00:00
David Baker
ae1262a241
Add schema change file for is_guest flag
2016-01-06 11:58:20 +00:00
David Baker
c79f221192
Add is_guest flag to users db to track whether a user is a guest user or not. Use this so we can run _filter_events_for_client when calculating event_push_actions.
2016-01-06 11:38:09 +00:00
David Baker
eb03625626
Merge remote-tracking branch 'origin/develop' into store_event_actions
2016-01-05 18:39:50 +00:00
Daniel Wagner-Hall
2ef6de928d
Skip, rather than erroring, invalid guest requests
...
Erroring causes problems when people make illegal requests, because they
don't know what limit parameter they should pass.
This is definitely buggy. It leaks message counts for rooms people don't
have permission to see, via tokens. But apparently we already
consciously decided to allow that as a team, so this preserves that
behaviour.
2016-01-05 18:12:37 +00:00
Daniel Wagner-Hall
cfd07aafff
Allow guests to upgrade their accounts
2016-01-05 18:01:18 +00:00
Erik Johnston
8737ead008
Use larger thumbnail rather than smaller.
2016-01-05 17:30:30 +00:00
Erik Johnston
acb19068d0
Return /sync when something under the 'leave' key has changed
2016-01-05 14:49:06 +00:00
David Baker
85ca8cb90c
comment typo
2016-01-05 13:32:39 +00:00
Erik Johnston
c3ea36304b
Use named args
2016-01-05 12:57:45 +00:00
Erik Johnston
1b5642604b
Support inviting 3pids in /createRoom
2016-01-05 11:56:21 +00:00
David Baker
4eb7b950c8
= not == in sql
2016-01-04 18:11:17 +00:00
David Baker
c77e7e60fc
Only joined rooms have unread_notif_count
2016-01-04 15:49:06 +00:00
David Baker
d74c6ace24
comma
2016-01-04 15:32:00 +00:00
David Baker
f1b67730fa
Add unread_notif_count in incremental_sync_with_gap
2016-01-04 14:50:36 +00:00
David Baker
c914d67cda
Rename event-actions to event_push_actions as per PR request
2016-01-04 14:05:37 +00:00
Mark Haines
d2709a5389
Bump changelog and version for v0.12.0
2016-01-04 13:57:39 +00:00
David Baker
928c575c6f
Merge remote-tracking branch 'origin/develop' into store_event_actions
2016-01-04 13:39:51 +00:00
David Baker
3051c9d002
Address minor PR issues
2016-01-04 13:39:29 +00:00
Richard van der Hoff
32d9fd0b26
Expose /login under r0
...
The spec says /login should be available at r0 and 'unstable', so make it so.
2016-01-02 17:24:28 +00:00
Mark Haines
c6e79c84de
Bump version and update changelog for v0.12.0-rc3
2015-12-23 16:15:54 +00:00
Mark Haines
8d6dde7825
Merge pull request #457 from matrix-org/markjh/cached_sync
...
Add a cache for initialSync responses that expires after 5 minutes
2015-12-23 16:04:52 +00:00
Mark Haines
d12c00bdc3
Add some docstring explaining the snapshot cache does
2015-12-23 15:18:11 +00:00
Mark Haines
f3948e001f
Missing yield on guest access auth check
...
Needs matrix-org/sytest#125 to land first
2015-12-23 14:10:06 +00:00
Mark Haines
7fa71e3267
Add a unit test for the snapshot cache
2015-12-23 11:48:03 +00:00
Mark Haines
517fb9a023
Move the doc string to the public facing method
2015-12-22 18:53:47 +00:00
Mark Haines
9ac417fa88
Add a cache for initialSync responses that expires after 5 minutes
2015-12-22 18:27:56 +00:00
David Baker
d2a92c6bde
Fix merge fail with anon access stuff
2015-12-22 18:25:04 +00:00
David Baker
9b4cd0cd0f
pep8 & unused variable
2015-12-22 17:25:09 +00:00
David Baker
140a50f641
Merge remote-tracking branch 'origin/develop' into store_event_actions
2015-12-22 17:23:35 +00:00
David Baker
5645d9747b
Add some comments to areas that could be optimised.
2015-12-22 17:19:22 +00:00
David Baker
4c8f6a7e42
Insert push actions in a single db query rather than one per user/profile_tag
2015-12-22 17:04:31 +00:00
Mark Haines
0ee0138325
Include the list of bad room ids in the error
2015-12-22 15:49:32 +00:00
David Baker
65c451cb38
Add bulk push rule evaluator which actually still evaluates rules one by one, but does far fewer db queries to fetch the rules
2015-12-22 15:19:34 +00:00
Mark Haines
251aafccca
Use a list comprehension
2015-12-22 14:03:24 +00:00
Mark Haines
c058625959
Merge remote-tracking branch 'origin/develop' into markjh/guest_access
...
Conflicts:
synapse/api/filtering.py
2015-12-22 13:58:18 +00:00
Mark Haines
cdd04f7055
Hook up read receipts and typing notifications for guest access
2015-12-22 11:59:55 +00:00
Mark Haines
542ab0f886
Merge branch 'develop' into markjh/guest_access
2015-12-22 11:49:12 +00:00
Mark Haines
b9b4466d0d
Add top level filters for filtering by room id
...
Documented by matrix-org/matrix-doc#246
2015-12-22 11:40:32 +00:00
Mark Haines
c3fff251a9
Allow guest access to /sync
2015-12-22 11:21:03 +00:00
Mark Haines
45a9e0ae0c
Allow guest access if the user provides a list of rooms in the filter
2015-12-22 10:25:46 +00:00
Mark Haines
489a4cd1cf
Add top level filtering by room id
2015-12-21 21:10:41 +00:00
Daniel Wagner-Hall
7f3148865c
Return room avatar URLs in /publicRooms
...
Spec: https://github.com/matrix-org/matrix-doc/pull/244
Tests: https://github.com/matrix-org/sytest/pull/121
2015-12-21 19:38:04 +00:00
David Baker
c061b47c57
Merge remote-tracking branch 'origin/develop' into store_event_actions
2015-12-21 15:30:26 +00:00
David Baker
f73f154ec2
Only run pushers for users on this hs!
2015-12-21 15:28:54 +00:00
Mark Haines
64b6606824
Remove accidentally committed debug logging
2015-12-21 15:22:03 +00:00
David Baker
091c545c4f
pep8
2015-12-21 10:14:57 +00:00
Paul "LeoNerd" Evans
a6ba41e078
Actually look up required remote server key IDs
...
set.union() is a side-effect-free function that returns the union of two
sets. This clearly wanted .update(), which is the side-effecting mutator
version.
2015-12-18 21:36:42 +00:00
Matthew Hodgson
c8ea2d5b1f
Merge pull request #450 from matrix-org/matthew/no-identicons
...
Matthew/no identicons
2015-12-18 18:14:06 +00:00
David Baker
413d0d6a24
Make unread notification count sending work: put the correct count in incremental syncs too, where necessary, and fix silly bugs like only select the event actions for that user...
2015-12-18 17:47:00 +00:00
David Baker
0a2d73fd60
Merge branch 'release-v0.12.0' into develop
2015-12-18 10:07:48 +00:00
David Baker
ce4999268a
Fix typo that broke registration on the mobile clients
2015-12-18 10:07:28 +00:00
Matthew Hodgson
64374bda5b
fix indentation level
2015-12-17 23:04:53 +00:00
Matthew Hodgson
772ad4f715
stop generating default identicons. reverts most of 582019f870
and solves vector-web/vector-im#346
2015-12-17 23:04:20 +00:00
Daniel Wagner-Hall
bdacee476d
Add display_name to 3pid invite in m.room.member invites
2015-12-17 18:55:08 +01:00
Daniel Wagner-Hall
8c5f252edb
Strip address and such out of 3pid invites
...
We're not meant to leak that into the graph
2015-12-17 18:09:51 +01:00
Richard van der Hoff
a64f9bbfe0
Fix 500 error when back-paginating search results
...
We were mistakenly adding pagination clauses to the count query, which then
failed because the count query doesn't join to the events table.
2015-12-17 12:50:46 +00:00
David Baker
42ad49f5b7
still very WIP, but now sends unread_notifications_count in the room object on sync (only actually corrrect in a full sync: hardcoded to 0 in incremental syncs).
2015-12-16 18:42:09 +00:00
Daniel Wagner-Hall
2b0f8a9482
Fix typo
2015-12-16 17:59:44 +01:00
Daniel Wagner-Hall
0311612ce9
Give the IS a bunch more 3pid invite context
...
This allows it to form richer emails
2015-12-16 13:05:32 +00:00
Mark Haines
5fc03449c8
Merge pull request #440 from matrix-org/daniel/ise
...
Include errcode on Internal Server Error
2015-12-16 11:26:55 +00:00
Mark Haines
4fab578b43
Merge branch 'release-v0.12.0' into develop
2015-12-16 11:18:45 +00:00
Mark Haines
dcfc70e8ed
Allow users to change which account a 3pid is bound to
2015-12-15 17:02:21 +00:00
Mark Haines
63fdd9fe0b
Changelog and version bump for v0.12.0-rc2
2015-12-14 16:26:59 +00:00
Mark Haines
3ddf0b9722
Fix spacing
2015-12-14 15:20:59 +00:00
Mark Haines
2acae8300f
Fix logging to lie less
2015-12-14 15:19:37 +00:00
Mark Haines
dbe7892e03
Fix a race between started/stopped stream
2015-12-14 15:09:41 +00:00
Mark Haines
28c5181dfe
Add commentary for fix in PR#442
2015-12-14 14:50:51 +00:00
Mark Haines
15e9885197
Merge branch 'release-v0.12.0' into develop
2015-12-14 14:46:55 +00:00
Mark Haines
8505a4ddc3
Merge pull request #441 from matrix-org/markjh/fts_skip_invalid
...
Skip events that where the body, name or topic isn't a string
2015-12-14 14:42:35 +00:00
Mark Haines
070e28e203
Combine the prev content tests
2015-12-14 14:34:04 +00:00
Mark Haines
834924248f
Check whether prev_content or prev_sender is set before trying to rollback state
2015-12-14 14:09:21 +00:00
Mark Haines
98dfa7d24f
Skip events that where the body, name or topic isn't a string when back populating the FTS index
2015-12-14 13:55:46 +00:00
Daniel Wagner-Hall
338c0a8a69
Include errcode on Internal Server Error
2015-12-14 13:50:50 +00:00
Daniel Wagner-Hall
76e69cc8de
Fix typo
2015-12-14 12:38:55 +00:00
Mark Haines
bfc52a2342
Fix typo in sql for full text search on sqlite3
2015-12-14 11:38:11 +00:00
Mark Haines
deeebbfcb7
Merge branch 'release-v0.12.0' into develop
2015-12-12 14:21:49 +00:00
Mark Haines
1ee7280c4c
Do the /sync in parallel accross the rooms like /initialSync does
2015-12-11 16:48:20 +00:00
Erik Johnston
cde49d3d2b
Merge pull request #435 from matrix-org/erikj/search
...
Include approximate count of search results
2015-12-11 16:27:38 +00:00
Erik Johnston
d9a5c56930
Include approximate count of search results
2015-12-11 11:40:23 +00:00
Erik Johnston
51fb590c0e
Use more efficient query form
2015-12-11 11:12:57 +00:00
David Baker
5e909c73d7
Store nothing instead of ['dont_notify'] for events with no notification required: much as it would be nice to be able to tell between the event not having been processed and there being no notification for it, this isn't worth filling up the table with ['dont_notify'] I think. Consequently treat the empty actions array as dont_notify and filter dont_notify out of the result.
2015-12-10 18:40:28 +00:00
Mark Haines
515548a47a
Missing yield
2015-12-10 17:54:23 +00:00
David Baker
aa667ee396
Save event actions to the db
2015-12-10 17:51:15 +00:00
Mark Haines
7d6b313312
Add caches for whether a room has been forgotten by a user
2015-12-10 17:49:34 +00:00
David Baker
a84a693327
Having consulted The Erikle, this should go at the end of on_receive_pdu, otherwise it will be triggered whenever we backfill too.
2015-12-10 17:18:46 +00:00
Paul "LeoNerd" Evans
99afb4b750
Ensure that the event that gets persisted is the one that was signed
2015-12-10 17:08:21 +00:00
David Baker
21f135ba76
Very first cut of calculating actions for events as they come in. Doesn't store them yet. Not very efficient.
2015-12-10 16:26:08 +00:00
Mark Haines
a8589d1ff3
Mark the version as a -rc1 release candidate
2015-12-10 11:39:00 +00:00
Mark Haines
05f6cb42db
Bump synapse version to v0.12.0
2015-12-09 17:48:02 +00:00
David Baker
a24eedada7
pep8
2015-12-09 15:57:42 +00:00
David Baker
4a728beba1
Split out the push rule evaluator into a separate file so it can be more readily reused. Should be functionally identical.
2015-12-09 15:51:34 +00:00
Mark Haines
e4bfe50e8f
Allow filter JSON object in the filter query parameter in /sync
...
Documented by matrix-org/matrix-doc#224
2015-12-09 12:56:50 +00:00
Daniel Wagner-Hall
0f826b0b0d
Merge pull request #430 from matrix-org/daniel/unstable
...
Merge pull request #430 from matrix-org/daniel/unstable
2015-12-09 11:34:22 +00:00
Erik Johnston
7c2ff8c889
Merge pull request #405 from matrix-org/erikj/search-ts
...
Change the result dict to be a list in /search response
2015-12-08 16:15:27 +00:00
Daniel Wagner-Hall
7a8ba4c9a0
Actually host r0 and unstable prefixes
2015-12-08 15:26:52 +00:00
Mark Haines
6a5ff5f223
Track the time spent in the database per request.
...
and track the number of transactions that request started.
2015-12-07 17:56:11 +00:00
Mark Haines
f7a1cdbbc6
Merge pull request #423 from matrix-org/markjh/archived_flag
...
Only include the archived rooms if a include_leave flag in set in the…
2015-12-07 13:16:03 +00:00
Mark Haines
d547afeae0
Merge remote-tracking branch 'origin/master' into develop
2015-12-07 13:13:43 +00:00
David Baker
9c9b2829ae
also do more structured logging
2015-12-07 12:01:00 +00:00
David Baker
50e5886de1
pep8
2015-12-07 11:57:48 +00:00
David Baker
ba1d740239
Add logging to pushers API to log the body of the request
2015-12-07 11:52:20 +00:00
Mark Haines
a190b2e85e
Merge pull request #427 from matrix-org/markjh/log_context
...
Add a setter for the current log context.
2015-12-07 11:00:12 +00:00
Mark Haines
3dd1630848
Add a setter for the current log context.
...
Move the resource tracking inside that setter so that it is easier
to make sure that the resource tracking isn't double counting the
resource usage.
2015-12-07 10:51:18 +00:00
Daniel Wagner-Hall
41905784f7
Take object not bool
...
Allows bool as legacy fallback
See https://github.com/matrix-org/matrix-doc/pull/212
2015-12-07 10:44:33 +00:00
Mark Haines
660dee94af
Only include the archived rooms if a include_leave flag in set in the filter
2015-12-04 17:32:09 +00:00
Mark Haines
262a97f02b
Merge pull request #422 from matrix-org/markjh/schema
...
Bump schema version.
2015-12-04 15:45:44 +00:00
Mark Haines
d57c5cda71
Bump schema version.
...
As we released version 26 in v0.11.1
2015-12-04 15:28:39 +00:00
Mark Haines
99e1d6777f
Add metrics to track the cpu on the main thread consumed by each type of request
2015-12-04 14:42:24 +00:00
Mark Haines
3c85a317d6
Merge pull request #420 from matrix-org/markjh/resource_usage
...
Track the cpu used in the main thread by each logging context
2015-12-04 14:15:41 +00:00
Mark Haines
5231737369
Add comments to explain why we are hardcoding RUSAGE_THREAD
2015-12-04 11:53:38 +00:00
Mark Haines
d6059bdd2a
Fix warnings
2015-12-04 11:34:23 +00:00
Mark Haines
48a2526d62
Track the cpu used in the main thread by each logging context
2015-12-03 21:03:01 +00:00
Mark Haines
b29d2fd7f8
Merge pull request #419 from matrix-org/markjh/reuse_captcha_client
...
Reuse the captcha client rather than creating a new one for each request
2015-12-03 17:00:59 +00:00
Daniel Wagner-Hall
edfcb83473
Flatten devices into a dict, not a list
2015-12-03 16:19:21 +00:00
Mark Haines
478b4e3ed4
Reuse the captcha client rather than creating a new one for each request
2015-12-03 13:48:55 +00:00
Erik Johnston
b8680b82c3
Merge pull request #414 from matrix-org/erikj/if_not_exists
...
Older versions of SQLite don't like IF NOT EXISTS in virtual tables
2015-12-03 13:21:09 +00:00
Daniel Wagner-Hall
ac213c2e08
Merge pull request #415 from matrix-org/daniel/endpoints
...
Merge pull request #415 from matrix-org/daniel/endpoints
2015-12-03 12:19:12 +00:00
Daniel Wagner-Hall
e880164c59
Merge pull request #418 from matrix-org/daniel/whois
...
Merge pull request #418 from matrix-org/daniel/whois
2015-12-03 12:18:01 +00:00
Daniel Wagner-Hall
526bc33e02
Fix implementation of /admin/whois
2015-12-02 17:29:47 +00:00
David Baker
e515b48929
Just replace the table definition with the one from full_schema 16
2015-12-02 17:23:52 +00:00
David Baker
8810eb8c39
Fix schema delta 15 on postgres in the very unlikley event that anyone upgrades to 15...
2015-12-02 17:19:11 +00:00
Mark Haines
491f3d16dc
Make state updates in the C+S API idempotent
2015-12-02 15:50:50 +00:00
Daniel Wagner-Hall
872c134807
Update endpoints to reflect current spec
2015-12-02 15:45:04 +00:00
Erik Johnston
f721fdbf87
Merge pull request #412 from matrix-org/erikj/search
...
Search: Add prefix matching support
2015-12-02 13:56:41 +00:00
Erik Johnston
976cb5aaa8
Throw if unrecognized DB type
2015-12-02 13:50:43 +00:00
Erik Johnston
b2def42bfd
Older versions of SQLite don't like IF NOT EXISTS in virtual tables
2015-12-02 13:29:14 +00:00
Erik Johnston
b9acef5301
Fix so highlight matching works again
2015-12-02 13:28:13 +00:00
Mark Haines
58d0927767
Merge pull request #410 from matrix-org/markjh/edu_frequency
...
Only fire user_joined_room if the user has actually joined.
2015-12-02 13:17:15 +00:00
Erik Johnston
7dd6e5efca
Remove deuplication. Add comment about regex.
2015-12-02 13:09:37 +00:00
Mark Haines
5dc09e82c4
Merge pull request #413 from matrix-org/markjh/reuse_http_client
...
Reuse a single http client, rather than creating new ones
2015-12-02 12:56:23 +00:00
Mark Haines
c2c70f7daf
Use the context returned by _handle_new_event
2015-12-02 12:01:24 +00:00
Erik Johnston
477da77b46
Search: Add prefix matching support
2015-12-02 11:40:52 +00:00
Mark Haines
37b2d69bbc
Reuse a single http client, rather than creating new ones
2015-12-02 11:36:02 +00:00
David Baker
addb248e0b
Merge pull request #411 from matrix-org/default_dont_notify
...
Change the m.room.message rule to be disabled by default
2015-12-02 11:32:56 +00:00
David Baker
4b1281f9b7
Change the m.room.message rule to be disabled by default so we only notify for 1:1 rooms / highlights out-of-the-box
2015-12-02 11:26:49 +00:00
Mark Haines
dede14f689
Merge branch 'develop' into markjh/edu_frequency
2015-12-02 10:57:51 +00:00
Mark Haines
5eb4d13aaa
Fix typo in collect_presencelike_data
2015-12-02 10:50:58 +00:00
Mark Haines
c30cdb0d68
Add comments
2015-12-02 10:49:35 +00:00
Mark Haines
2a0ec3b89d
Merge branch 'develop' into markjh/edu_frequency
...
Conflicts:
synapse/handlers/federation.py
synapse/handlers/room.py
2015-12-02 10:40:22 +00:00
Erik Johnston
03b2a6a8aa
Merge pull request #409 from MadsRC/develop
...
Develop
2015-12-02 10:08:18 +00:00
Mark Haines
9fbd504b4e
Merge pull request #408 from matrix-org/markjh/distributor_facade
...
Wrap calls to distributor.fire in appropriately named functions
2015-12-02 09:44:56 +00:00
Erik Johnston
9670f226e3
Merge pull request #406 from matrix-org/erikj/search
...
Search: Don't disregard grouping info in pagination tokens
2015-12-02 09:13:20 +00:00
Mads R. Christensen
6863466653
Added a single line to explain what the server_name is used for
2015-12-02 00:37:55 +01:00
Mark Haines
a9526831a4
Wrap calls to distributor.fire in appropriately named functions so that static analysis can work out want is calling what
2015-12-01 20:53:04 +00:00
Mark Haines
ed0f79bdc5
Only fire user_joined_room if the membership has changed
2015-12-01 19:46:15 +00:00
Mark Haines
f73ea0bda2
Merge branch 'develop' into markjh/edu_frequency
2015-12-01 19:15:27 +00:00
Mark Haines
95f30ecd1f
Add API for setting account_data globaly or on a per room basis
2015-12-01 18:41:32 +00:00
Daniel Wagner-Hall
14d7acfad4
Host /unstable and /r0 versions of r0 APIs
2015-12-01 17:34:32 +00:00
Erik Johnston
27c5e1b374
Search: Don't disregard grouping info in pagination tokens
2015-12-01 16:47:18 +00:00
Mark Haines
af96c6f4d3
Merge pull request #404 from matrix-org/markjh/trivial_rename
...
Rename presence_handler.send_invite
2015-12-01 16:11:03 +00:00
Mark Haines
d32db0bc45
Merge pull request #402 from matrix-org/markjh/event_formatting
...
Copy rather than move the fields to shuffle between a v1 and a v2 event.
2015-12-01 16:10:24 +00:00
Mark Haines
3d3da2b460
Only fire user_joined_room on the distributor if the user has actually joined the room
2015-12-01 16:03:08 +00:00
Mark Haines
31069ecf6a
Rename presence_handler.send_invite to presence_handler.send_presence_invite to distinguish it from normal invites
2015-12-01 15:59:45 +00:00
Erik Johnston
71578e2bf2
Change the result tict to be a list
2015-12-01 14:48:35 +00:00
Mark Haines
306415391d
Only add the user_id if the sender is present
2015-12-01 11:14:48 +00:00
Erik Johnston
da7dd58641
Tidy up a bit
2015-12-01 11:06:40 +00:00
Mark Haines
bde8d78b8a
Copy rather than move the fields to shuffle between a v1 and a v2 event.
...
This should make all v1 APIs compatible with v2 clients. While still
allowing v1 clients to access the fields.
This makes the documentation easier since we can just document the v2
format and explain that some of the fields, in some of the APIs are
duplicated for backwards compatibility, rather than having to document
two separate event formats.
2015-11-30 17:46:35 +00:00
Erik Johnston
4dcaa42b6d
Allow paginating search ordered by recents
2015-11-30 17:45:31 +00:00
Erik Johnston
76936f43ae
Return words to highlight in search results
2015-11-27 16:40:42 +00:00
Erik Johnston
17dd5071ef
Allow user to redact with an equal power
...
Users only need their power level to be equal to the redact level for
them to be allowed to redact events.
2015-11-26 11:17:57 +00:00
Daniel Wagner-Hall
df7cf6c0eb
Fix SQL for postgres again
2015-11-23 18:54:41 +00:00
Daniel Wagner-Hall
3e573a5c6b
Fix SQL for postgres
2015-11-23 18:48:53 +00:00
Daniel Wagner-Hall
7dfa455508
Remove size specifier for database column
...
Postgres doesn't support them like this.
We don't have a bool type in common between postgres and sqlite.
2015-11-23 18:35:25 +00:00
Daniel Wagner-Hall
924d85a75e
Merge pull request #375 from matrix-org/daniel/guestroominitialsync
...
Clean up room initialSync for guest users
2015-11-23 16:10:49 +00:00
Mark Haines
c6a15f5026
Merge pull request #385 from matrix-org/daniel/forgetrooms
...
Allow users to forget rooms
2015-11-20 18:07:26 +00:00
Erik Johnston
1b64cb019e
Merge branch 'erikj/perspective_limiter' into release-v0.11.1
2015-11-20 17:24:23 +00:00
Erik Johnston
0eabfa55f6
Fix typo
2015-11-20 17:17:58 +00:00
Erik Johnston
6408541075
Don't limit connections to perspective servers
2015-11-20 17:15:44 +00:00
Erik Johnston
2c1bc4392f
Bump changes and version
2015-11-20 16:35:01 +00:00
Erik Johnston
93f7bb8dd5
Merge pull request #394 from matrix-org/erikj/search
...
Add options for including state in search results
2015-11-20 16:31:24 +00:00
Richard van der Hoff
1d9c1d4166
Merge pull request #389 from matrix-org/rav/flatten_sync_response
...
v2 sync: Get rid of the event_map, and rename the keys of the rooms obj
2015-11-20 15:18:55 +00:00
Erik Johnston
3f151da314
Merge pull request #391 from matrix-org/erikj/remove_token_from_flow
...
Remove m.login.token from advertised flows.
2015-11-20 14:16:59 +00:00
Erik Johnston
6b95a79724
Add option to include the current room state
2015-11-20 14:16:42 +00:00
Erik Johnston
e3dae653e8
Comment
2015-11-20 14:05:22 +00:00
Erik Johnston
9de1f328ad
Merge pull request #393 from matrix-org/erikj/destination_retry_max
...
Use min and not max to set an upper bound on retry interval
2015-11-20 13:41:20 +00:00
Erik Johnston
506874cca9
Optionally include historic profile info
2015-11-20 11:39:44 +00:00
Erik Johnston
2f2bbb4d06
Use min and not max to set an upper bound on retry interval
2015-11-20 09:34:58 +00:00
Daniel Wagner-Hall
95c3306798
Merge branch 'daniel/forgetrooms' of github.com:matrix-org/synapse into daniel/forgetrooms
2015-11-19 15:00:14 -05:00
Daniel Wagner-Hall
df6824a008
Ignore forgotten rooms in v2 sync
2015-11-19 14:54:47 -05:00
Paul "LeoNerd" Evans
dd11bf8a79
Merge branch 'develop' into rav/flatten_sync_response
2015-11-19 17:21:03 +00:00
Paul "LeoNerd" Evans
1cfda3d2d8
Merge branch 'develop' into daniel/forgetrooms
2015-11-19 16:53:13 +00:00
Erik Johnston
8b5349c7bc
Merge branch 'master' of github.com:matrix-org/synapse into develop
2015-11-19 16:17:54 +00:00
Erik Johnston
37de8a7f4a
Remove m.login.token from advertised flows.
2015-11-19 16:16:49 +00:00
Mark Haines
7a802ec0ff
Merge pull request #386 from matrix-org/markjh/rename_pud_to_account_data
...
s/private_user_data/account_data/
2015-11-19 15:21:35 +00:00
Daniel Wagner-Hall
248cfd5eb3
Take a boolean not a list of lambdas
2015-11-19 15:16:25 +00:00
Daniel Wagner-Hall
9da4c5340d
Simplify code
2015-11-19 10:07:21 -05:00
Erik Johnston
5fcef78c6a
Bump changes and version
2015-11-19 13:09:48 +00:00
Erik Johnston
06f74068f4
Comment
2015-11-19 13:05:51 +00:00
Richard van der Hoff
f6e092f6cc
Put back the 'state.events' subobject
...
We're keeping 'events', in case we decide to add more keys later.
2015-11-19 12:23:42 +00:00
Richard van der Hoff
24ae0eee8e
v2 /sync: Rename the keys of the 'rooms' object to match member states
...
joined->join
invited->invite
archived->leave
2015-11-19 10:51:12 +00:00
Richard van der Hoff
3c3fc6b268
Flatten the /sync response to remove the event_map
2015-11-19 10:51:11 +00:00
Daniel Wagner-Hall
bed7889703
Apply forgetting properly to historical events
2015-11-18 18:11:12 -05:00
Erik Johnston
037ce4c68f
Split out text for missing config options.
...
This allows packages to more easily override the default messages to
include package specific options.
2015-11-18 18:37:05 +00:00
Mark Haines
d153f482dd
Rename the database table
2015-11-18 15:33:02 +00:00
Mark Haines
1c960fbb80
s/private_user_data/account_data/
2015-11-18 15:31:04 +00:00
Daniel Wagner-Hall
ba26eb3d5d
Allow users to forget rooms
2015-11-17 17:17:30 -05:00
Erik Johnston
cf844e2ad6
Bump changelog and version
2015-11-17 18:48:32 +00:00
Erik Johnston
cbf3cd6151
Add comment
2015-11-17 18:29:29 +00:00
Erik Johnston
cf4ef5f3c7
Only retry federation requests for a long time for background requests
2015-11-17 18:26:50 +00:00
Erik Johnston
afdfd12bdf
Implement required method 'resumeProducing'
2015-11-17 16:57:06 +00:00
Erik Johnston
bceec65913
Slightly more aggressive retry timers at HTTP level
2015-11-17 15:10:05 +00:00
Erik Johnston
9eff52d1a6
Bump changelog and version
2015-11-17 14:38:36 +00:00
Erik Johnston
0186aef814
Merge branch 'develop' of github.com:matrix-org/synapse into release-v0.11.0
2015-11-17 14:37:13 +00:00
Steven Hammerton
f20d064e05
Always check guest = true in macaroons
2015-11-17 10:58:05 +00:00
Steven Hammerton
f5e25c5f35
Merge branch 'develop' into sh-cas-auth-via-homeserver
2015-11-17 10:55:41 +00:00
Paul "LeoNerd" Evans
aca6e5bf46
Don't complain if /make_join response lacks 'prev_state' list (SYN-517)
2015-11-13 17:27:25 +00:00
Daniel Wagner-Hall
641420c5e0
Clean up room initialSync for guest users
2015-11-13 15:44:57 +00:00
Daniel Wagner-Hall
9c3f4f8dfd
Allow guests to /room/:room_id/{join,leave}
2015-11-13 11:56:58 +00:00
Erik Johnston
0644f0eb7d
Bump version and change log
2015-11-13 11:43:29 +00:00
Richard van der Hoff
e4d622aaaf
Implementation of state rollback in /sync
...
Implementation of SPEC-254: roll back the state dictionary to how it looked at
the start of the timeline.
Merged PR https://github.com/matrix-org/synapse/pull/373
2015-11-13 10:58:56 +00:00
Richard van der Hoff
fddedd51d9
Fix a few race conditions in the state calculation
...
Be a bit more careful about how we calculate the state to be returned by
/sync. In a few places, it was possible for /sync to return slightly later
state than that represented by the next_batch token and the timeline. In
particular, the following cases were susceptible:
* On a full state sync, for an active room
* During a per-room incremental sync with a timeline gap
* When the user has just joined a room. (Refactor check_joined_room to make it
less magical)
Also, use store.get_state_for_events() (and thus the existing stategroups) to
calculate the state corresponding to a particular sync position, rather than
state_handler.compute_event_context(), which recalculates from first principles
(and tends to miss some state).
Merged from PR https://github.com/matrix-org/synapse/pull/372
2015-11-13 10:39:09 +00:00
Richard van der Hoff
5ab4b0afe8
Make handlers.sync return a state dictionary, instead of an event list.
...
Basically this moves the process of flattening the existing dictionary into a
list up to rest.client.*, instead of doing it in handlers.sync. This simplifies
a bit of the code in handlers.sync, but it is also going to be somewhat
beneficial in the next stage of my hacking on SPEC-254.
Merged from PR #371
2015-11-13 10:35:01 +00:00
Richard van der Hoff
5dea4d37d1
Update some comments
...
Add a couple of type annotations, docstrings, and other comments, in the
interest of keeping track of what types I have.
Merged from pull request #370 .
2015-11-13 10:31:15 +00:00
Daniel Wagner-Hall
fc27ca9006
Merge pull request #369 from matrix-org/daniel/guestnonevents
...
Return non-room events from guest /events calls
2015-11-12 17:28:48 +00:00
Daniel Wagner-Hall
468a2ed4ec
Return non-room events from guest /events calls
2015-11-12 16:45:28 +00:00
Erik Johnston
018b504f5b
Merge pull request #368 from matrix-org/erikj/fix_federation_profile
...
Fix missing profile data in federation joins
2015-11-12 16:30:02 +00:00
Erik Johnston
49f1758d74
Merge pull request #366 from matrix-org/erikj/search_fix_sqlite_faster
...
Use a (hopefully) more efficient SQL query for doing recency based room search
2015-11-12 16:24:32 +00:00
Erik Johnston
c0b3554401
Fix missing profile data in federation joins
...
There was a regression where we stopped including profile data in
initial joins for rooms joined over federation.
2015-11-12 16:19:55 +00:00
Erik Johnston
3de46c7755
Trailing whitespace
2015-11-12 15:36:43 +00:00
Erik Johnston
8fd8e72cec
Expand comment
2015-11-12 15:33:47 +00:00
Richard van der Hoff
78f6010207
Fix an issue with ignoring power_level changes on divergent graphs
...
Changes to m.room.power_levels events are supposed to be handled at a high
priority; however a typo meant that the relevant bit of code was never
executed, so they were handled just like any other state change - which meant
that a bad person could cause room state changes by forking the graph from a
point in history when they were allowed to do so.
2015-11-12 15:24:59 +00:00
Daniel Wagner-Hall
06bfd0a3c0
Merge pull request #367 from matrix-org/daniel/readafterleave
...
Merge pull request #367 from matrix-org/daniel/readafterleave
Tweak guest access permissions
2015-11-12 15:22:02 +00:00
Erik Johnston
764e79d051
Comment
2015-11-12 15:19:56 +00:00
Daniel Wagner-Hall
0d08670f61
Merge pull request #360 from matrix-org/daniel/guestroominitialsync
...
Merge pull request #360 from matrix-org/daniel/guestroominitialsync
Allow guest access to room initialSync
2015-11-12 15:19:55 +00:00
Erik Johnston
320408ef47
Fix SQL syntax
2015-11-12 15:09:45 +00:00
Daniel Wagner-Hall
fb7e260a20
Tweak guest access permissions
...
* Allow world_readable rooms to be read by guests who have joined and
left
* Allow regular users to access world_readable rooms
2015-11-12 15:02:00 +00:00
Erik Johnston
14a9d805b9
Use a (hopefully) more efficient SQL query for doing recency based room search
2015-11-12 14:48:39 +00:00
Erik Johnston
39de87869c
Fix bug where assumed dict was namedtuple
2015-11-12 14:47:48 +00:00
Daniel Wagner-Hall
0a93df5f9c
Allow guests to set their display names
...
Depends: https://github.com/matrix-org/synapse/pull/363
Tests in https://github.com/matrix-org/sytest/pull/66
2015-11-12 13:44:39 +00:00
Daniel Wagner-Hall
50f1afbd5b
Consider joined guest users as joined users
...
Otherwise they're inconveniently allowed to write events to the room
but not to read them from the room.
2015-11-12 13:37:07 +00:00
Daniel Wagner-Hall
6a9c4cfd0b
Fix race creating directories
2015-11-12 11:58:48 +00:00
Erik Johnston
aa3ab6c6a0
Merge branch 'develop' of github.com:matrix-org/synapse into release-v0.11.0
2015-11-11 18:17:49 +00:00
Erik Johnston
04034d0b56
Merge pull request #361 from matrix-org/daniel/guestcontext
...
Allow guests to access room context API
2015-11-11 18:17:35 +00:00
Erik Johnston
6341be45c6
Merge branch 'develop' of github.com:matrix-org/synapse into release-v0.11.0
2015-11-11 17:51:14 +00:00
Daniel Wagner-Hall
e93d550b79
Allow guests to access room context API
2015-11-11 17:49:44 +00:00
Erik Johnston
e21cef9bb5
Merge pull request #359 from matrix-org/markjh/incremental_indexing
...
Incremental background updates for db indexes
2015-11-11 17:19:51 +00:00
Mark Haines
e1627388d1
Fix param style to work on both sqlite and postgres
2015-11-11 17:14:56 +00:00
Daniel Wagner-Hall
f15ba926cc
Allow guest access to room initialSync
2015-11-11 17:13:24 +00:00
Steven Hammerton
ffdc8e5e1c
Snakes not camels
2015-11-11 14:26:47 +00:00
Mark Haines
940a161192
Fix the background update
2015-11-11 13:59:40 +00:00
Steven Hammerton
2b779af10f
Minor review fixes
2015-11-11 11:21:43 +00:00
Steven Hammerton
dd2eb49385
Share more code between macaroon validation
2015-11-11 11:12:35 +00:00
Daniel Wagner-Hall
cf437900e0
Return world_readable and guest_can_join in /publicRooms
2015-11-10 17:10:27 +00:00
Daniel Wagner-Hall
38d82edf0e
Allow guest users to join and message rooms
2015-11-10 16:57:13 +00:00
Mark Haines
90b503216c
Use a background task to update databases to use the full text search
2015-11-10 16:20:13 +00:00
Mark Haines
a412b9a465
Run the background updates when starting synapse.
2015-11-10 15:50:58 +00:00
Daniel Wagner-Hall
82e8a2d763
Merge pull request #356 from matrix-org/daniel/3pidyetagain
...
Get display name from identity server, not client
2015-11-10 12:44:17 +00:00
Mark Haines
2ede7aa8a1
Add background update task for reindexing event search
2015-11-09 19:29:32 +00:00
Richard van der Hoff
c7db2068c8
Don't fiddle with results returned by event sources
...
Overwriting hashes returned by other methods is poor form.
Fixes: SYN-516
2015-11-09 18:09:46 +00:00
Daniel Wagner-Hall
0d63dc3ec9
Get display name from identity server, not client
2015-11-09 17:26:43 +00:00
Mark Haines
c6a01f2ed0
Add storage module for tracking background updates.
...
The progress for each background update is stored as a JSON blob in the
database. Each background update is broken up into separate batches.
The batch size is automatically tuned to try avoid blocking single
threaded databases for too long.
2015-11-09 17:26:27 +00:00
Richard van der Hoff
9107ed23b7
Add a couple of unit tests for room/<x>/messages
...
... merely because I was trying to figure out how it worked, and couldn't.
2015-11-09 16:16:43 +00:00
Mark Haines
bbe10e8be7
Merge branch 'develop' into markjh/SYN-513
...
Conflicts:
synapse/storage/tags.py
2015-11-09 15:01:59 +00:00
Mark Haines
c4135d85e1
SYN-513: Include updates for rooms that have had all their tags deleted
2015-11-09 14:53:08 +00:00
Matthew Hodgson
dd40fb68e4
fix comedy important missing comma breaking recent-ordered FTS on sqlite
2015-11-08 16:04:37 +00:00
Matthew Hodgson
767c20a869
add a key existence check to tags_by_room to avoid /events 500'ing when testing against vector
2015-11-06 20:49:57 +01:00
Daniel Wagner-Hall
f2c4ee41b9
Remove accidentally added ID column
2015-11-06 14:27:49 +00:00
Steven Hammerton
0b31223c7a
Updates to fallback CAS login to do new token login
2015-11-06 09:57:17 +00:00
Steven Hammerton
fece2f5c77
Merge branch 'develop' into sh-cas-auth-via-homeserver
2015-11-05 20:59:45 +00:00
Erik Johnston
f23af34729
Merge branch 'develop' of github.com:matrix-org/synapse into release-v0.11.0
2015-11-05 18:00:51 +00:00
Erik Johnston
6be1b4b113
Merge pull request #350 from matrix-org/erikj/search
...
Implement pagination, order by and groups in search
2015-11-05 17:52:32 +00:00
Erik Johnston
66d36b8e41
Be explicit about what we're doing
2015-11-05 17:26:19 +00:00
Erik Johnston
2aa98ff3bc
Remove redundant test
2015-11-05 17:25:50 +00:00
Erik Johnston
5ee070d21f
Increment by one, not five
2015-11-05 17:25:33 +00:00
Erik Johnston
f1dcaf3296
Bump changelog and version number
2015-11-05 17:20:28 +00:00
Daniel Wagner-Hall
2cebe53545
Exchange 3pid invites for m.room.member invites
2015-11-05 16:43:19 +00:00
Erik Johnston
1ad6222ebf
COMMENTS
2015-11-05 16:29:16 +00:00
Erik Johnston
5bc690408d
Merge pull request #340 from matrix-org/erikj/server_retries
...
Retry dead servers a lot less often
2015-11-05 16:15:50 +00:00
Erik Johnston
3640ddfbf6
Error handling
2015-11-05 16:10:54 +00:00
Erik Johnston
729ea933ea
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/search
2015-11-05 15:43:52 +00:00
Erik Johnston
347146be29
Merge branch 'develop' of github.com:matrix-org/synapse into develop
2015-11-05 15:35:17 +00:00
Erik Johnston
7a5ea067e2
Merge branch 'release-v0.10.1' of github.com:matrix-org/synapse into develop
2015-11-05 15:35:05 +00:00
Erik Johnston
7301e05122
Implement basic pagination for search results
2015-11-05 15:04:08 +00:00
Daniel Wagner-Hall
ca2f90742d
Open up /events to anonymous users for room events only
...
Squash-merge of PR #345 from daniel/anonymousevents
2015-11-05 14:32:26 +00:00
Steven Hammerton
414a4a71b4
Allow hs to do CAS login completely and issue the client with a login token that can be redeemed for the usual successful login response
2015-11-05 14:06:48 +00:00
Mark Haines
7a369e8a55
Merge pull request #347 from matrix-org/markjh/check_filter
...
Remove fields that are both unspecified and unused from the filter checks
2015-11-05 11:15:39 +00:00
Steven Hammerton
45f1827fb7
Add service URL to CAS config
2015-11-04 23:32:30 +00:00
Erik Johnston
05c326d445
Implement order and group by
2015-11-04 17:57:44 +00:00
Daniel Wagner-Hall
4e62ffdb21
Merge branch 'develop' of github.com:matrix-org/synapse into develop
2015-11-04 17:31:01 +00:00
Daniel Wagner-Hall
f522f50a08
Allow guests to register and call /events?room_id=
...
This follows the same flows-based flow as regular registration, but as
the only implemented flow has no requirements, it auto-succeeds. In the
future, other flows (e.g. captcha) may be required, so clients should
treat this like the regular registration flow choices.
2015-11-04 17:29:07 +00:00
Mark Haines
33b3e04049
Merge branch 'develop' into daniel/removesomelies
...
Conflicts:
synapse/notifier.py
2015-11-04 16:01:00 +00:00
Mark Haines
285d056629
Remove fields that are both unspecified and unused from the filter checks, check the right top level definitions in the filter
2015-11-04 15:47:19 +00:00
Mark Haines
c452dabc3d
Remove the LockManager class because it wasn't being used
2015-11-04 14:08:15 +00:00
Mark Haines
f74f48e9e6
Merge pull request #341 from matrix-org/markjh/v2_sync_receipts
...
Include read receipts in v2 sync
2015-11-03 18:45:13 +00:00
Erik Johnston
6a3a840b19
Merge pull request #343 from matrix-org/erikj/fix_retries
...
Fix broken cache for getting retry times.
2015-11-03 17:51:49 +00:00
Mark Haines
a3bfef35fd
Merge branch 'develop' into markjh/v2_sync_receipts
...
Conflicts:
synapse/handlers/sync.py
2015-11-03 17:31:17 +00:00
Mark Haines
6797fcd9ab
Merge pull request #335 from matrix-org/markjh/room_tags
...
Add APIs for adding and removing tags from rooms
2015-11-03 16:45:53 +00:00
Erik Johnston
97d792b28f
Don't rearrange transaction_queue
2015-11-03 16:31:08 +00:00
Erik Johnston
7ce264ce5f
Fix broken cache for getting retry times. This meant we retried remote destinations way more frequently than we should
2015-11-03 16:24:03 +00:00
Mark Haines
06986e46a3
That TODO was done
2015-11-03 14:28:51 +00:00
Mark Haines
5897e773fd
Spell "deferred" more correctly
2015-11-03 14:27:35 +00:00
Mark Haines
2657140c58
Include read receipts in v2 sync
2015-11-02 17:54:04 +00:00
Erik Johnston
eacb068ac2
Retry dead servers a lot less often
2015-11-02 16:56:30 +00:00
Mark Haines
57be722c46
Include room tags in v2 /sync
2015-11-02 16:23:15 +00:00
Daniel Wagner-Hall
771ca56c88
Remove more unused parameters
2015-11-02 15:31:57 +00:00
Mark Haines
ddd8566f41
Store room tag content and return the content in the m.tag event
2015-11-02 15:11:31 +00:00
Daniel Wagner-Hall
192241cf2a
Remove unused arguments and code
2015-11-02 15:10:59 +00:00
Mark Haines
0e36756383
Merge branch 'develop' into markjh/room_tags
2015-11-02 10:57:00 +00:00
Mark Haines
fb46937413
Support clients supplying older tokens, fix short poll test
2015-10-30 16:38:35 +00:00
Mark Haines
79b65f3875
Include tags in v1 room initial sync
2015-10-30 16:28:19 +00:00
Daniel Wagner-Hall
621e84d9a0
Add missing column
2015-10-30 16:25:53 +00:00
Mark Haines
fdf73c6855
Include room tags v1 /initialSync
2015-10-30 16:22:32 +00:00
Mark Haines
d58edd98e9
Update the other place check_joined_room is called
2015-10-30 11:15:37 +00:00
Mark Haines
5cf22f0596
Don't mark newly joined room timelines as limited in an incremental sync
2015-10-29 19:58:51 +00:00
Erik Johnston
f6e6f3d87a
Make search API honour limit set in filter
2015-10-29 16:17:47 +00:00
Mark Haines
f40b0ed5e1
Inform the client of new room tags using v1 /events
2015-10-29 15:21:09 +00:00
Erik Johnston
5d80dad99e
Merge pull request #336 from matrix-org/erikj/search
...
Optionally return event contexts with search results
2015-10-28 18:39:40 +00:00
Erik Johnston
e83c4b8e3e
Merge pull request #334 from matrix-org/erikj/context_api
...
Add room context api
2015-10-28 18:26:01 +00:00
Erik Johnston
a2e5f7f3d8
Optionally return event contexts with search results
2015-10-28 18:25:11 +00:00
Mark Haines
a89b86dc47
Fix pyflakes errors
2015-10-28 16:45:57 +00:00
Mark Haines
892e70ec84
Add APIs for adding and removing tags from rooms
2015-10-28 16:06:57 +00:00
Erik Johnston
56dbcd1524
Docs
2015-10-28 14:05:50 +00:00
Richard van der Hoff
234d6f9f3e
Merge pull request #332 from matrix-org/rav/full_state_sync
...
Implement full_state incremental sync
2015-10-28 14:04:39 +00:00
Erik Johnston
5cb298c934
Add room context api
2015-10-28 13:45:56 +00:00
Richard van der Hoff
c79c4f9b14
Implement full_state incremental sync
...
A hopefully-complete implementation of the full_state incremental sync, as
specced at https://github.com/matrix-org/matrix-doc/pull/133 .
This actually turns out to be a relatively simple modification to the initial
sync implementation.
2015-10-26 18:47:18 +00:00
Richard van der Hoff
f69a5c9134
Fix a 500 error resulting from empty room_ids
...
POST /_matrix/client/api/v1/rooms//send/a.b.c gave a 500 error, because we
assumed that rooms always had at least one character.
2015-10-26 18:44:03 +00:00
Erik Johnston
f73de2004e
Use correct service url
2015-10-26 18:12:09 +00:00
Erik Johnston
87961d8dcf
Add login fallback
2015-10-26 17:35:24 +00:00
Erik Johnston
fa1cf5ef34
Move static folder into synapse
...
This is because otherwise it won't get picked up by python packaging.
This also fixes the problem where the "static" folder was found if
synapse wasn't started from that directory.
2015-10-26 15:37:44 +00:00
Erik Johnston
3f0a57eb9b
Merge pull request #328 from matrix-org/erikj/search
...
Pull out sender when computing search results
2015-10-26 10:24:19 +00:00
Erik Johnston
4cf633d5e9
Pull out sender when computing search results
2015-10-23 15:41:36 +01:00
Erik Johnston
b8e37ed944
Merge pull request #327 from matrix-org/erikj/search
...
Implement rank function for SQLite FTS
2015-10-23 15:27:51 +01:00
Erik Johnston
0c36098c1f
Implement rank function for SQLite FTS
2015-10-23 13:23:48 +01:00
Daniel Wagner-Hall
216c976399
Merge pull request #323 from matrix-org/daniel/sizelimits
...
Reject events which are too large
2015-10-23 11:26:03 +01:00
Erik Johnston
259d10f0e4
Merge branch 'release-v0.10.1' of github.com:matrix-org/synapse into develop
2015-10-23 11:11:56 +01:00
Mark Haines
b051781ddb
Merge pull request #325 from matrix-org/markjh/filter_dicts
...
Support filtering events represented as dicts.
2015-10-22 17:14:52 +01:00
Mark Haines
4e05aab4f7
Don't assume that the event has a room_id or sender
2015-10-22 17:08:59 +01:00
Erik Johnston
671ac699f1
Actually filter results
2015-10-22 16:54:56 +01:00
Mark Haines
9b6f3bc742
Support filtering events represented as dicts.
...
This is useful because the emphemeral events such as presence and
typing are represented as dicts inside synapse.
2015-10-22 16:38:03 +01:00
Erik Johnston
2980136d75
Rename
2015-10-22 16:19:53 +01:00
Erik Johnston
fb0fecd0b9
LESS THAN
2015-10-22 16:18:35 +01:00
Erik Johnston
61547106f5
Fix receipts for room initial sync
2015-10-22 16:17:23 +01:00
Erik Johnston
232beb3a3c
Use namedtuple as return value
2015-10-22 15:02:35 +01:00
Erik Johnston
ba02bba88c
Limit max number of SQL vars
2015-10-22 13:25:27 +01:00
Erik Johnston
b0ac0a9438
Merge pull request #319 from matrix-org/erikj/filter_refactor
...
Refactor api.filtering to have a Filter API
2015-10-22 13:17:10 +01:00
Erik Johnston
8a98f0dc5b
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/search
2015-10-22 13:16:35 +01:00
Erik Johnston
c9c82e8f4d
Merge pull request #320 from matrix-org/appservice-retry-cap
...
Cap the time to retry txns to appservices to 8.5 minutes
2015-10-22 13:15:54 +01:00
Daniel Wagner-Hall
e60dad86ba
Reject events which are too large
...
SPEC-222
2015-10-22 11:44:31 +01:00
Erik Johnston
f142898f52
PEP8
2015-10-22 11:18:01 +01:00
Erik Johnston
4d25bc6c92
Move FTS to delta 25
2015-10-22 11:12:28 +01:00
Erik Johnston
5025ba959f
Add config option to disable password login
2015-10-22 10:37:04 +01:00
Mark Haines
5201c66108
Merge branch 'develop' into markjh/v2_sync_typing
...
Conflicts:
synapse/handlers/sync.py
2015-10-21 15:48:34 +01:00
Mark Haines
e94ffd89d6
Merge pull request #316 from matrix-org/markjh/v2_sync_archived
...
Add rooms that the user has left under archived in v2 sync.
2015-10-21 15:46:41 +01:00
Mark Haines
d63a0ca34b
Doc string for the SyncHandler.typing_by_room method
2015-10-21 15:45:37 +01:00
Mark Haines
e3d75f564a
Include banned rooms in the archived section of v2 sync
2015-10-21 11:15:48 +01:00
Kegsay
8627048787
Merge pull request #318 from matrix-org/syn-502-login-bad-emails
...
Don't 500 on /login when the email doesn't map to a valid user ID.
2015-10-21 10:16:33 +01:00
Kegan Dougal
4dec901c76
Cap the time to retry txns to appservices to 8.5 minutes
...
There's been numerous issues with people playing around with their
application service and then not receiving events from their HS for
ages due to backoff timers reaching crazy heights (albeit capped at
< 1 day).
Reduce the max time between pokes to be 8.5 minutes (2^9 secs) which
is quick enough for people to wait it out (avg wait time being 4.25 min)
but long enough to actually give the AS breathing room if it needs it.
2015-10-21 10:10:55 +01:00
Erik Johnston
5c41224a89
Filter room ids before hitting the database
2015-10-21 10:09:26 +01:00
Erik Johnston
c8baada94a
Filter search results
2015-10-21 10:08:53 +01:00
Kegan Dougal
ede07434e0
Use 403 and message to match handlers/auth
2015-10-21 09:42:07 +01:00
Mark Haines
7be06680ed
Include typing events in initial v2 sync
2015-10-20 16:36:20 +01:00
Erik Johnston
87deec824a
Docstring
2015-10-20 15:47:42 +01:00
Erik Johnston
45cd2b0233
Refactor api.filtering to have a Filter API
2015-10-20 15:33:25 +01:00
Daniel Wagner-Hall
137fafce4e
Allow rejecting invites
...
This is done by using the same /leave flow as you would use if you had
already accepted the invite and wanted to leave.
2015-10-20 11:58:58 +01:00
Kegan Dougal
b02a342750
Don't 500 when the email doesn't map to a valid user ID.
2015-10-20 11:07:50 +01:00
Mark Haines
51d03e65b2
Fix pep8
2015-10-19 17:48:58 +01:00
Mark Haines
68b7fc3e2b
Add rooms that the user has left under archived in v2 sync.
2015-10-19 17:26:18 +01:00
Daniel Wagner-Hall
9261ef3a15
Merge pull request #312 from matrix-org/daniel/3pidinvites
...
Stuff signed data in a standalone object
2015-10-19 15:52:34 +01:00
Erik Johnston
e0bf0258ee
Merge pull request #307 from matrix-org/erikj/search
...
Add basic search API
2015-10-19 13:37:15 +01:00
Paul "LeoNerd" Evans
243a79d291
Surely we don't need to preserve 'events_default' twice
2015-10-16 18:25:19 +01:00
Mark Haines
9371a35e89
Merge pull request #306 from matrix-org/markjh/unused_methods
...
Remove some login classes from synapse.
2015-10-16 18:18:41 +01:00
Daniel Wagner-Hall
0e5239ffc3
Stuff signed data in a standalone object
...
Makes both generating it in sydent, and verifying it here, simpler at
the cost of some repetition
2015-10-16 17:45:48 +01:00
Mark Haines
b19b9535f6
Merge pull request #310 from matrix-org/markjh/bcrypt_rounds
...
Add config for how many bcrypt rounds to use for password hashes
2015-10-16 17:05:21 +01:00
Erik Johnston
46d39343d9
Explicitly check for Sqlite3Engine
2015-10-16 16:58:00 +01:00
Erik Johnston
f2d698cb52
Typing
2015-10-16 16:46:48 +01:00
Erik Johnston
33646eb000
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/search
2015-10-16 15:35:35 +01:00
Erik Johnston
380f148db7
Remove unused import
2015-10-16 15:32:56 +01:00
Mark Haines
fc012aa8dc
Fix FilteringStore.get_user_filter to work with postgres
2015-10-16 15:28:43 +01:00
Daniel Wagner-Hall
e5acc8a47b
Merge pull request #302 from matrix-org/daniel/3pidinvites
...
Implement third party identifier invites
2015-10-16 15:23:30 +01:00
Erik Johnston
d4b5621e0a
Remove duplicate _filter_events_for_client
2015-10-16 15:19:52 +01:00
Erik Johnston
23ed7dc0e7
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/search
2015-10-16 15:18:42 +01:00
Daniel Wagner-Hall
c225d63e9e
Add signing host and keyname to signatures
2015-10-16 15:07:56 +01:00
Daniel Wagner-Hall
b8dd5b1a2d
Verify third party ID server certificates
2015-10-16 14:54:54 +01:00
Erik Johnston
366af6b73a
Amalgamate _filter_events_for_client
2015-10-16 14:52:48 +01:00
Mark Haines
f2f031fd57
Add config for how many bcrypt rounds to use for password hashes
...
By default we leave it at the default value of 12. But now we can reduce
it for preparing users for loadtests or running integration tests.
2015-10-16 14:52:08 +01:00
Erik Johnston
12122bfc36
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/search
2015-10-16 14:46:32 +01:00
Erik Johnston
edb998ba23
Explicitly check for Sqlite3Engine
2015-10-16 14:37:14 +01:00
Erik Johnston
b62da463e1
docstring
2015-10-16 11:52:16 +01:00
Erik Johnston
3cf9948b8d
Add docstring
2015-10-16 11:28:12 +01:00
Erik Johnston
73260ad01f
Comment on the LIMIT 500
2015-10-16 11:24:02 +01:00
Erik Johnston
22a8c91448
Split up run_upgrade
2015-10-16 11:19:44 +01:00
Mark Haines
6296590bf7
Encode the filter JSON as UTF-8 before storing in the database.
...
Because we are using a binary column type to store the filter JSON.
2015-10-16 10:50:32 +01:00
Erik Johnston
bcfb653816
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/search
2015-10-15 16:37:32 +01:00
Erik Johnston
8189c4e3fd
Bump version
2015-10-15 15:29:00 +01:00
Daniel Wagner-Hall
6ffbcf45c6
Use non-placeholder name for endpoint
2015-10-15 13:12:52 +01:00
Daniel Wagner-Hall
643b5fcdc8
Look for keys on the right objects
2015-10-15 13:10:30 +01:00
Daniel Wagner-Hall
f38df51e8d
Merge branch 'develop' into daniel/3pidinvites
2015-10-15 11:51:55 +01:00
Mark Haines
1a934e8bfd
synapse.client.v1.login.LoginFallbackRestServlet and synapse.client.v1.login.PasswordResetRestServlet are unused
2015-10-15 11:09:57 +01:00
Mark Haines
5338220d3a
synapse.util.emailutils was unused
2015-10-15 10:39:33 +01:00
Mark Haines
a059760954
Merge pull request #305 from matrix-org/markjh/v2_sync_api
...
Update the v2 sync API to work as specified in the current spec.
2015-10-14 13:56:23 +01:00
Mark Haines
c185c1c413
Fix v2 sync polling
2015-10-14 13:16:53 +01:00
Mark Haines
f50c43464c
Merge branch 'develop' into markjh/v2_sync_api
2015-10-14 11:40:45 +01:00
Erik Johnston
f45aaf0e35
Remove unused constatns
2015-10-14 10:36:55 +01:00
Erik Johnston
8c9df8774e
Make 'keys' optional
2015-10-14 10:35:50 +01:00
Erik Johnston
99c7fbfef7
Fix to work with SQLite
2015-10-14 09:52:40 +01:00
Erik Johnston
1d9e109820
More TODO markers
2015-10-14 09:49:00 +01:00
Erik Johnston
d25b0f65ea
Add TODO markers
2015-10-14 09:46:31 +01:00
Erik Johnston
858634e1d0
Remove unused room_id arg
2015-10-14 09:31:20 +01:00
Mark Haines
474274583f
Merge pull request #303 from matrix-org/markjh/twisted_debugging
...
Bounce all deferreds through the reactor to make debugging easier.
2015-10-13 18:40:57 +01:00
Daniel Wagner-Hall
d82c5f7b5c
Use more descriptive error code
2015-10-13 18:02:00 +01:00
Daniel Wagner-Hall
0c38e8637f
Remove unnecessary class-wrapping
2015-10-13 18:00:38 +01:00
Mark Haines
9020860479
Only turn on the twisted deferred debugging if full_twisted_stacktraces is set in the config
2015-10-13 17:50:44 +01:00
Daniel Wagner-Hall
14edea1aff
Move logic into handler
2015-10-13 17:47:58 +01:00
Daniel Wagner-Hall
b68db61222
Add logging
2015-10-13 17:22:50 +01:00
Daniel Wagner-Hall
bb407cd624
Re-add accidentally removed code
2015-10-13 17:19:26 +01:00
Mark Haines
32d66738b0
Fix pep8 warnings.
2015-10-13 17:18:29 +01:00
Daniel Wagner-Hall
95e53ac535
Add some docstring
2015-10-13 17:18:24 +01:00
Mark Haines
7639c3d9e5
Bounce all deferreds through the reactor to make debugging easier.
...
If all deferreds wait a reactor tick before resolving then there is
always a chance to add an errback to the deferred so that stacktraces
get reported, rather than being discarded.
2015-10-13 17:13:04 +01:00
Erik Johnston
7ecd11accb
Add paranoia limit
2015-10-13 15:50:56 +01:00
Daniel Wagner-Hall
17dffef5ec
Move event contents into third_party_layout field
2015-10-13 15:48:12 +01:00
Erik Johnston
3e2a1297b5
Remove constraints in preperation of using filters
2015-10-13 15:22:14 +01:00
Erik Johnston
323d3e506d
Merge branch 'develop' of github.com:matrix-org/synapse into erikj/search
2015-10-13 14:34:01 +01:00
Mark Haines
2fa9e23e04
Update the v2 filters to support filtering presence and remove support for public/private user data
2015-10-13 14:12:43 +01:00
Mark Haines
cacf0688c6
Add a get_invites_for_user method to the storage to find out the rooms a user is invited to
2015-10-13 14:08:38 +01:00
Erik Johnston
88971fd034
Merge branch 'erikj/store_engine' into erikj/search
2015-10-13 14:03:30 +01:00
Erik Johnston
17c80c8a3d
rename schema_prepare to prepare_database
2015-10-13 13:56:22 +01:00
Erik Johnston
cfd39d6b55
Add SQLite support
2015-10-13 13:47:50 +01:00
Daniel Wagner-Hall
32a453d7ba
Merge branch 'develop' into daniel/3pidinvites
2015-10-13 13:32:43 +01:00
Erik Johnston
f9340ea0d5
Merge branch 'erikj/store_engine' into erikj/search
2015-10-13 13:29:02 +01:00
Erik Johnston
ec398af41c
Expose error more nicely
2015-10-13 11:43:43 +01:00
Mark Haines
54414221e4
Include invites in incremental sync
2015-10-13 11:43:12 +01:00
Erik Johnston
40b6a5aad1
Split out the schema preparation and update logic into its own module
2015-10-13 11:38:48 +01:00
Mark Haines
ab9cf73258
Include invited rooms in the initial sync
2015-10-13 11:03:48 +01:00
Erik Johnston
30c2783d2f
Search left rooms too
2015-10-13 10:36:36 +01:00
Erik Johnston
1a40afa756
Add sqlite schema
2015-10-13 10:36:25 +01:00
Mark Haines
f96b480670
Merge branch 'develop' into markjh/v2_sync_api
2015-10-13 10:33:00 +01:00
Mark Haines
956509dfec
Start spliting out the rooms into joined and invited in v2 sync
2015-10-13 10:24:51 +01:00
Mark Haines
586beb8318
Update the filters to match the latest spec.
...
Apply the filter the 'timeline' and 'ephemeral' keys of rooms.
Apply the filter to the 'presence' key of a sync response.
2015-10-12 16:54:58 +01:00
Erik Johnston
427943907f
Merge pull request #299 from stevenhammerton/sh-cas-required-attribute
...
SH CAS Required Attribute
2015-10-12 16:08:34 +01:00
Steven Hammerton
739464fbc5
Add a comment to clarify why we split on closing curly brace when reading CAS attribute tags
2015-10-12 16:02:17 +01:00
Erik Johnston
ca53ad7425
Filter events to only thsoe that the user is allowed to see
2015-10-12 15:52:55 +01:00
Erik Johnston
f6fde343a1
Merge remote-tracking branch 'origin/develop' into erikj/search
2015-10-12 15:06:18 +01:00
Erik Johnston
927004e349
Remove unused room_id parameter
2015-10-12 15:06:14 +01:00
Steven Hammerton
83b464e4f7
Unpack dictionary in for loop for nicer syntax
2015-10-12 15:05:34 +01:00
Steven Hammerton
ab7f9bb861
Default cas_required_attributes to empty dictionary
2015-10-12 14:58:59 +01:00
Mark Haines
54cb509d64
Merge pull request #296 from matrix-org/markjh/eventstream_presence
...
Split the sections of EventStreamHandler.get_stream that handle presence
2015-10-12 14:48:09 +01:00
Mark Haines
885301486c
Merge pull request #297 from matrix-org/markjh/presence_races
...
Fix some races in the synapse presence handler caused by not yielding…
2015-10-12 14:47:53 +01:00
Steven Hammerton
7f8fdc9814
Remove not required parenthesis
2015-10-12 14:45:24 +01:00
Steven Hammerton
01a5f1991c
Support multiple required attributes in CAS response, and in a nicer config format too
2015-10-12 14:43:17 +01:00
Steven Hammerton
76421c496d
Allow optional config params for a required attribute and it's value, if specified any CAS user must have the given attribute and the value must equal
2015-10-12 11:11:49 +01:00
Steven Hammerton
7845f62c22
Parse both user and attributes from CAS response
2015-10-12 10:55:13 +01:00
Erik Johnston
ae72e247fa
PEP8
2015-10-12 10:50:46 +01:00
Erik Johnston
61561b9df7
Keep FTS indexes up to date. Only search through rooms currently joined
2015-10-12 10:49:53 +01:00
Erik Johnston
a80ef851f7
Fix previous merge to s/version_string/user_agent/
2015-10-10 12:35:39 +01:00
Steven Hammerton
95f7661170
Raise LoginError if CasResponse doensn't contain user
2015-10-10 10:54:19 +01:00
Steven Hammerton
a9c299c0be
Fix my broken line splitting
2015-10-10 10:54:19 +01:00
Steven Hammerton
e52f4dc599
Use UserId to create FQ user id
2015-10-10 10:54:19 +01:00