Commit message (Collapse) | Author | Files | Lines | ||
---|---|---|---|---|---|
2018-01-27 | Add tests for user directory search | Richard van der Hoff | 2 | -0/+89 | |
2018-01-27 | Fix SQL for user search | Richard van der Hoff | 1 | -7/+7 | |
fix some syntax errors for user search when search_all_users is enabled fixes #2801, hopefully | |||||
2018-01-27 | Make it possible to run tests against postgres | Richard van der Hoff | 1 | -9/+34 | |
2018-01-27 | Create dbpool as normal in tests | Richard van der Hoff | 2 | -45/+19 | |
... instead of creating our own special SQLiteMemoryDbPool, whose purpose was a bit of a mystery. For some reason this makes one of the tests run slightly slower, so bump the sleep(). Sorry. | |||||
2018-01-27 | Run on_new_connection for unit tests | Richard van der Hoff | 1 | -7/+17 | |
Configure the connectionpool used for unit tests to run the `on_new_connection` function. | |||||
2018-01-26 | Factor out get_db_conn to HomeServer base class | Richard van der Hoff | 11 | -130/+17 | |
This function is identical to all subclasses, so we may as well push it up to the base class to reduce duplication (and make use of it in the tests) | |||||
2018-01-26 | Remove unused/bitrotted MemoryDataStore | Richard van der Hoff | 1 | -151/+13 | |
This isn't used, and looks thoroughly bitrotted. | |||||
2018-01-26 | Remove spurious unittest.DEBUG | Richard van der Hoff | 1 | -1/+0 | |
2018-01-26 | add white space line | Neil Johnson | 1 | -0/+1 | |
2018-01-26 | rather than try reconstruct the results object, better to guard against the ↵ | Neil Johnson | 1 | -6/+2 | |
xrange step argument being 0 | |||||
2018-01-25 | fix return type, should be a dict | Neil Johnson | 1 | -1/+1 | |
2018-01-25 | fix PEP8 violation | Neil Johnson | 1 | -1/+1 | |
2018-01-25 | remove white space | Neil Johnson | 1 | -1/+0 | |
2018-01-25 | synapse 500s on a call to publicRooms in the case where the number of public ↵ | Neil Johnson | 1 | -0/+5 | |
rooms is zero, the specific cause is due to xrange trying to use a step value of zero, but if the total room number really is zero then it makes sense to just bail and save the extra processing | |||||
2018-01-24 | fix thinko on 3pid whitelisting | Matthew Hodgson | 1 | -2/+2 | |
2018-01-23 | add ?ts massaging for ASes (#2754) | Matthew Hodgson | 1 | -6/+11 | |
blindly implement ?ts for AS. untested | |||||
2018-01-22 | Add federation_domain_whitelist option (#2820) | Matthew Hodgson | 14 | -7/+146 | |
Add federation_domain_whitelist gives a way to restrict which domains your HS is allowed to federate with. useful mainly for gracefully preventing a private but internet-connected HS from trying to federate to the wider public Matrix network | |||||
2018-01-22 | Matthew's fixes to the unit tests | Richard van der Hoff | 1 | -2/+6 | |
Extracted from https://github.com/matrix-org/synapse/pull/2820 | |||||
2018-01-19 | Add some comments about the reactor tick time metric | Richard van der Hoff | 1 | -1/+6 | |
2018-01-19 | fix typo (thanks sytest) | Matthew Hodgson | 1 | -1/+1 | |
2018-01-19 | Use the right path for url_preview thumbnails | Richard van der Hoff | 1 | -0/+8 | |
This was introduced by #2627: we were overwriting the original media for url previews with the thumbnails :/ (fixes https://github.com/vector-im/riot-web/issues/6012, hopefully) | |||||
2018-01-19 | oops, check all login types | Matthew Hodgson | 1 | -14/+11 | |
2018-01-19 | fix PR nitpicking | Matthew Hodgson | 1 | -3/+6 | |
2018-01-19 | trailing commas | Matthew Hodgson | 2 | -7/+7 | |
2018-01-19 | rewrite based on PR feedback: | Matthew Hodgson | 7 | -89/+102 | |
* [ ] split config options into allowed_local_3pids and registrations_require_3pid * [ ] simplify and comment logic for picking registration flows * [ ] fix docstring and move check_3pid_allowed into a new util module * [ ] use check_3pid_allowed everywhere @erikjohnston PTAL | |||||
2018-01-19 | fix up v1, and improve errors | Matthew Hodgson | 4 | -20/+65 | |
2018-01-19 | fix pep8 | Matthew Hodgson | 1 | -2/+1 | |
2018-01-19 | mock registrations_require_3pid | Matthew Hodgson | 1 | -0/+1 | |
2018-01-19 | add registrations_require_3pid | Matthew Hodgson | 5 | -13/+110 | |
lets homeservers specify a whitelist for 3PIDs that users are allowed to associate with. Typically useful for stopping people from registering with non-work emails | |||||
2018-01-18 | Fix storage provider bug introduced when renamed to store_local | Erik Johnston | 1 | -1/+1 | |
2018-01-18 | Fix passing wrong config to provider constructor | Erik Johnston | 1 | -1/+1 | |
2018-01-18 | Remove duplicate directory test | Erik Johnston | 1 | -4/+0 | |
2018-01-18 | Missing staticmethod | Erik Johnston | 1 | -0/+1 | |
2018-01-18 | Fixup comments | Erik Johnston | 2 | -3/+7 | |
2018-01-18 | Fix typo in thumbnail resource causing access times to be incorrect | Erik Johnston | 1 | -2/+2 | |
2018-01-18 | Make storage providers more configurable | Erik Johnston | 3 | -31/+98 | |
2018-01-18 | Fix bugs in block metrics | Richard van der Hoff | 1 | -2/+4 | |
... which I introduced in #2785 | |||||
2018-01-18 | Do logcontexts correctly | Erik Johnston | 1 | -2/+2 | |
2018-01-18 | Move test stuff to tests | Erik Johnston | 2 | -33/+47 | |
2018-01-18 | Make all fields private | Erik Johnston | 1 | -31/+31 | |
2018-01-18 | better exception logging in callbackmetrics | Richard van der Hoff | 1 | -1/+8 | |
when we fail to render a metric, give a clue as to which metric it was | |||||
2018-01-18 | Ensure we registerProducer isn't called twice | Erik Johnston | 1 | -0/+3 | |
2018-01-18 | Fix _notify_empty typo | Erik Johnston | 1 | -1/+1 | |
2018-01-18 | Move definition of paused_producer to __init__ | Erik Johnston | 1 | -2/+4 | |
2018-01-18 | Fix comments | Erik Johnston | 1 | -3/+3 | |
2018-01-17 | Log room when doing state resolution | Richard van der Hoff | 1 | -0/+6 | |
Mostly because it helps figure out what is prompting the resolution | |||||
2018-01-17 | Add decent impl of a FileConsumer | Erik Johnston | 2 | -0/+296 | |
Twisted core doesn't have a general purpose one, so we need to write one ourselves. Features: - All writing happens in background thread - Supports both push and pull producers - Push producers get paused if the consumer falls behind | |||||
2018-01-17 | fix SQL when searching all users | Matthew Hodgson | 1 | -2/+7 | |
2018-01-17 | Split resolve_events into two functions | Richard van der Hoff | 2 | -20/+29 | |
... so that the return type doesn't depend on the arg types | |||||
2018-01-17 | Remove lost comment | Erik Johnston | 1 | -3/+0 | |
2018-01-17 | Sanity checking for user ids | Richard van der Hoff | 2 | -8/+19 | |
Check the user_id passed to a couple of APIs for validity, to avoid "IndexError: list index out of range" exception which looks scary and results in a 500 rather than a more useful error. Fixes #1432, among other things | |||||
2018-01-17 | Update last access time when thumbnails are viewed | Erik Johnston | 1 | -0/+2 | |
2018-01-17 | Keep track of last access time for local media | Erik Johnston | 4 | -11/+65 | |
2018-01-17 | Add docstring | Erik Johnston | 1 | -1/+1 | |
2018-01-16 | Fix 'NoneType' object has no attribute 'writeHeaders' | Richard van der Hoff | 1 | -9/+9 | |
Avoid throwing a (harmless) exception when we try to write an error response to an http request where the client has disconnected. This comes up as a CRITICAL error in the logs which tends to mislead people into thinking there's an actual problem | |||||
2018-01-16 | Track DB scheduling delay per-request | Richard van der Hoff | 5 | -4/+43 | |
For each request, track the amount of time spent waiting for a db connection. This entails adding it to the LoggingContext and we may as well add metrics for it while we are passing. | |||||
2018-01-16 | rework runInteraction in terms of runConnection | Richard van der Hoff | 1 | -20/+31 | |
... so that we can share the code | |||||
2018-01-16 | fix typo | Matthew Hodgson | 1 | -1/+1 | |
2018-01-16 | Use local vars | Erik Johnston | 1 | -6/+2 | |
2018-01-16 | Change _generate_thumbnails to take media_type | Erik Johnston | 2 | -7/+10 | |
2018-01-16 | Move setting of file_id up to caller | Erik Johnston | 2 | -13/+14 | |
2018-01-16 | Track db txn time in millisecs | Richard van der Hoff | 4 | -10/+17 | |
... to reduce the amount of floating-point foo we do. | |||||
2018-01-16 | Optimise LoggingContext creation and copying | Richard van der Hoff | 3 | -22/+33 | |
It turns out that the only thing we use the __dict__ of LoggingContext for is `request`, and given we create lots of LoggingContexts and then copy them every time we do a db transaction or log line, using the __dict__ seems a bit redundant. Let's try to optimise things by making the request attribute explicit. | |||||
2018-01-16 | Fix typo | Erik Johnston | 1 | -7/+10 | |
2018-01-16 | Fix up log lines | Erik Johnston | 2 | -7/+10 | |
2018-01-16 | document metrics changes | Richard van der Hoff | 2 | -8/+58 | |
2018-01-16 | Correctly use server_name/file_id when generating/fetching remote thumbnails | Erik Johnston | 2 | -5/+8 | |
2018-01-16 | Log when we respond with 404 | Erik Johnston | 2 | -1/+8 | |
2018-01-16 | Fix a logcontext leak in persist_events | Richard van der Hoff | 1 | -1/+8 | |
ObserveableDeferred expects its callbacks to be called without any logcontexts, whereas it turns out we were calling them with the logcontext of the request which initiated the persistence loop. It seems wrong that we are attributing work done in the persistence loop to the request that happened to initiate it, so let's solve this by dropping the logcontext for it. (I'm not sure this actually causes any real problems other than messages in the debug log, but let's clean it up anyway) | |||||
2018-01-16 | Fix thumbnailing remote files | Erik Johnston | 2 | -2/+30 | |
2018-01-15 | Metrics for events processed in appservice and fed sender | Richard van der Hoff | 2 | -0/+11 | |
More metrics I wished I'd had | |||||
2018-01-15 | Metrics for number of RDATA commands received | Richard van der Hoff | 1 | -5/+14 | |
I found myself wishing we had this. | |||||
2018-01-15 | Reorganise request and block metrics | Richard van der Hoff | 2 | -25/+84 | |
In order to circumvent the number of duplicate foo:count metrics increasing without bounds, it's time for a rearrangement. The following are all deprecated, and replaced with synapse_util_metrics_block_count: synapse_util_metrics_block_timer:count synapse_util_metrics_block_ru_utime:count synapse_util_metrics_block_ru_stime:count synapse_util_metrics_block_db_txn_count:count synapse_util_metrics_block_db_txn_duration:count The following are all deprecated, and replaced with synapse_http_server_response_count: synapse_http_server_requests synapse_http_server_response_time:count synapse_http_server_response_ru_utime:count synapse_http_server_response_ru_stime:count synapse_http_server_response_db_txn_count:count synapse_http_server_response_db_txn_duration:count The following are renamed (the old metrics are kept for now, but deprecated): synapse_util_metrics_block_timer:total -> synapse_util_metrics_block_time_seconds synapse_util_metrics_block_ru_utime:total -> synapse_util_metrics_block_ru_utime_seconds synapse_util_metrics_block_ru_stime:total -> synapse_util_metrics_block_ru_stime_seconds synapse_util_metrics_block_db_txn_count:total -> synapse_util_metrics_block_db_txn_count synapse_util_metrics_block_db_txn_duration:total -> synapse_util_metrics_block_db_txn_duration_seconds synapse_http_server_response_time:total -> synapse_http_server_response_time_seconds synapse_http_server_response_ru_utime:total -> synapse_http_server_response_ru_utime_seconds synapse_http_server_response_ru_stime:total -> synapse_http_server_response_ru_stime_seconds synapse_http_server_response_db_txn_count:total -> synapse_http_server_response_db_txn_count synapse_http_server_response_db_txn_duration:total synapse_http_server_response_db_txn_duration_seconds | |||||
2018-01-15 | mechanism to render metrics with alternative names | Richard van der Hoff | 1 | -13/+40 | |
2018-01-15 | Add some comments to metrics classes | Richard van der Hoff | 1 | -1/+27 | |
2018-01-12 | Make Counter render floats | Richard van der Hoff | 1 | -3/+10 | |
Prometheus handles all metrics as floats, and sometimes we store non-integer values in them (notably, durations in seconds), so let's render them as floats too. (Note that the standard client libraries also treat Counters as floats.) | |||||
2018-01-12 | Reinstate media download on thumbnail request | Richard van der Hoff | 1 | -0/+5 | |
We need to actually download the remote media when we get a request for a thumbnail. | |||||
2018-01-12 | Fix up comments | Erik Johnston | 2 | -7/+16 | |
2018-01-12 | Correctly reraise exception | Erik Johnston | 1 | -2/+4 | |
2018-01-12 | Make Responder a context manager | Erik Johnston | 2 | -9/+10 | |
2018-01-12 | Add missing class var | Erik Johnston | 1 | -0/+3 | |
2018-01-12 | Remove unnecessary condition | Erik Johnston | 1 | -4/+1 | |
2018-01-12 | Remove unused variables | Erik Johnston | 1 | -3/+0 | |
2018-01-12 | Make class var local | Erik Johnston | 1 | -3/+3 | |
2018-01-12 | Comments | Erik Johnston | 3 | -15/+65 | |
2018-01-12 | Actually make it work | Erik Johnston | 2 | -2/+15 | |
2018-01-12 | Refactor | Erik Johnston | 1 | -9/+4 | |
2018-01-11 | When using synctl with workers, don't start the main synapse automatically | Erik Johnston | 2 | -8/+33 | |
2018-01-10 | Do bcrypt hashing in a background thread | Erik Johnston | 3 | -10/+18 | |
2018-01-10 | fix order of operations derp and also use `.get` to default to {} | Michael Telatynski | 1 | -2/+3 | |
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com> | |||||
2018-01-10 | Fix publicised groups API |