Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Remove outdated comment in log config (#15648) | Andrew Morgan | 2023-05-22 | 1 | -3/+1 |
| | |||||
* | Reload the pyo3-log config when the Python logging config changes. (#14976) | Patrick Cloke | 2023-02-03 | 1 | -18/+24 |
| | | | | | | | | | | | Since pyo3-log is initialized very early in the Python start-up it caches the state of the loggers before they're fully initialized (and thus are essentially disabled). Whenever we reload the logging configuration we now also tell pyo3-log to discard any cached logging configuration it has; it will refetch the current logging configuration from Python at the next point it logs. This fixes Rust log lines not appearing in the homeserver logs. | ||||
* | Remove redundant types from comments. (#14412) | Patrick Cloke | 2022-11-16 | 1 | -3/+2 |
| | | | | | | | Remove type hints from comments which have been added as Python type hints. This helps avoid drift between comments and reality, as well as removing redundant information. Also adds some missing type hints which were simple to fill in. | ||||
* | Add workers settings to configuration manual (#14086) | Dirk Klimpel | 2022-10-27 | 1 | -1/+1 |
| | | | | | | | | | | | | | | | | | | | | * Add workers settings to configuration manual * Update `pusher_instances` * update url to python logger * update headlines * update links after headline change * remove link from `daemon process` There is no docs in Synapse for this * extend example for `federation_sender_instances` and `pusher_instances` * more infos about stream writers * add link to DAG * update `pusher_instances` * update `worker_listeners` * update `stream_writers` * Update `worker_name` Co-authored-by: David Robertson <davidr@element.io> | ||||
* | Parse SYNAPSE_ASYNC_IO_REACTOR env variable & log the reactor on startup ↵ | Quentin Gliech | 2022-10-07 | 1 | -0/+3 |
| | | | | (#14092) | ||||
* | Remove code generating comments in configuration file (#12941) | Shay | 2022-06-14 | 1 | -5/+0 |
| | |||||
* | Fix Synapse git info missing in version strings (#12973) | David Robertson | 2022-06-07 | 1 | -2/+2 |
| | |||||
* | Remove special-case for `twisted` logger (#12589) | Richard van der Hoff | 2022-04-29 | 1 | -7/+0 |
| | | | | | | | | | | | | | | | This was originally added when we first added a `MemoryHandler` to the default log config back in https://github.com/matrix-org/synapse/pull/8040, to ensure that we didn't explode with an infinite loop if there was an error formatting the logs. Since then, we made additional improvements to logging which make this workaround redundant. In particular: * we no longer attempt to log un-UTF8-decodable byte sequences, which were the most likely cause of an error in the first place. * https://github.com/matrix-org/synapse/pull/8268 ensures that in the unlikely case that there *is* an error, it won't cause an infinite loop. | ||||
* | Add missing type hints to config classes. (#12402) | Patrick Cloke | 2022-04-11 | 1 | -2/+5 |
| | |||||
* | Remove support for the legacy structured logging configuration. (#12008) | Patrick Cloke | 2022-02-17 | 1 | -4/+8 |
| | |||||
* | Use version string helper from matrix-common (#11979) | David Robertson | 2022-02-14 | 1 | -3/+6 |
| | | | | * Require latest matrix-common * Use the common function | ||||
* | Additional type hints for config module. (#11465) | Patrick Cloke | 2021-12-01 | 1 | -10/+14 |
| | | | | This adds some misc. type hints to helper methods used in the `synapse.config` module. | ||||
* | Add missing type hints to config base classes (#11377) | Patrick Cloke | 2021-11-23 | 1 | -2/+2 |
| | |||||
* | Add type hints for most `HomeServer` parameters (#11095) | Sean Quah | 2021-10-22 | 1 | -1/+8 |
| | |||||
* | Use direct references for configuration variables (part 5). (#10897) | Patrick Cloke | 2021-09-24 | 1 | -1/+3 |
| | |||||
* | Use direct references for configuration variables (part 4). (#10893) | Patrick Cloke | 2021-09-23 | 1 | -1/+1 |
| | |||||
* | Use direct references for some configuration variables (#10798) | Patrick Cloke | 2021-09-13 | 1 | -2/+2 |
| | | | | Instead of proxying through the magic getter of the RootConfig object. This should be more performant (and is more explicit). | ||||
* | Make `PeriodicallyFlushingMemoryHandler` the default logging handler. (#10518) | reivilibre | 2021-08-17 | 1 | -7/+20 |
| | |||||
* | Revert use of PeriodicallyFlushingMemoryHandler by default (#10515) | reivilibre | 2021-08-03 | 1 | -4/+1 |
| | |||||
* | Add a PeriodicallyFlushingMemoryHandler to prevent logging silence (#10407) | reivilibre | 2021-07-27 | 1 | -1/+4 |
| | | | Signed-off-by: Olivier Wilkinson (reivilibre) <olivier@librepush.net> | ||||
* | Update links to documentation in sample config (#10287) | Dirk Klimpel | 2021-07-07 | 1 | -1/+1 |
| | | | Signed-off-by: Dirk Klimpel dirk@klimpel.org | ||||
* | Ensure that errors during startup are written to the logs and the console. ↵ | Richard van der Hoff | 2021-06-21 | 1 | -3/+1 |
| | | | | | | | | (#10191) * Defer stdio redirection until we are about to start the reactor * Catch and handle exceptions during startup | ||||
* | Improved validation for received requests (#9817) | Richard van der Hoff | 2021-04-23 | 1 | -1/+2 |
| | | | | | | * Simplify `start_listening` callpath * Correctly check the size of uploaded files | ||||
* | Remove redundant "coding: utf-8" lines (#9786) | Jonathan de Jong | 2021-04-14 | 1 | -1/+0 |
| | | | | | | | Part of #9744 Removes all redundant `# -*- coding: utf-8 -*-` lines from files, as python 3 automatically reads source code as utf-8 now. `Signed-off-by: Jonathan de Jong <jonathan@automatia.nl>` | ||||
* | Fix additional type hints. (#9543) | Patrick Cloke | 2021-03-09 | 1 | -1/+4 |
| | | | Type hint fixes due to Twisted 21.2.0 adding type hints. | ||||
* | Update black, and run auto formatting over the codebase (#9381) | Eric Eastwood | 2021-02-16 | 1 | -1/+4 |
| | | | | | | | - Update black version to the latest - Run black auto formatting over the codebase - Run autoformatting according to [`docs/code_style.md `](https://github.com/matrix-org/synapse/blob/80d6dc9783aa80886a133756028984dbf8920168/docs/code_style.md) - Update `code_style.md` docs around installing black to use the correct version | ||||
* | Various clean-ups to the logging context code (#8935) | Patrick Cloke | 2020-12-14 | 1 | -1/+1 |
| | |||||
* | Support generating structured logs in addition to standard logs. (#8607) | Patrick Cloke | 2020-10-29 | 1 | -48/+48 |
| | | | | | | | This modifies the configuration of structured logging to be usable from the standard Python logging configuration. This also separates the formatting of logs from the transport allowing JSON logs to files or standard logs to sockets. | ||||
* | Fix typos and spelling errors. (#8639) | Patrick Cloke | 2020-10-23 | 1 | -1/+1 |
| | |||||
* | Fix stack overflow when logging system encounters an error (#8268) | Richard van der Hoff | 2020-09-07 | 1 | -2/+23 |
| | |||||
* | Move setting of Filter into code. | Erik Johnston | 2020-08-11 | 1 | -8/+16 |
| | | | | | | | | | | | | | | We do this to prevent foot guns. The default config uses a MemoryFilter, but users are free to change to logging to files directly. If they do then they have to ensure to set the `filters: [context]` on the right handler, otherwise records get written with the wrong context. Instead we move the logic to happen when we generate a record, which is when we *log* rather than *handle*. (It's possible to add filters to loggers in the config, however they don't apply to descendant loggers and so they have to be manually set on *every* logger used in the code base) | ||||
* | Change the default log config to reduce disk I/O and storage (#8040) | Erik Johnston | 2020-08-11 | 1 | -5/+36 |
| | | | | | | | | | | | | | | | | | | | | * Change default log config to buffer by default. This batches up writes to the filesystem, which is more efficient for disk I/O. This means that it can take some time for logs to get written to disk. Note that ERROR logs (and above) immediately flush the buffer. This only effects new installs, as we only write the log config if started with `--generate-config` (in the same way we do for generating signing keys). * Default to keeping last 4 days of logs. This hopefully reduces the amount of logs kept for new servers. Keeping the last 1GB of logs is likely overkill for new servers, but equally may not be enough for busy ones. Instead, we keep the last four days worth of logs, enough so that admins can investigate any problems that happened over e.g. a long weekend. | ||||
* | Update worker docs with recent enhancements (#7969) | Erik Johnston | 2020-07-29 | 1 | -1/+1 |
| | |||||
* | Add option to move event persistence off master (#7517) | Erik Johnston | 2020-05-22 | 1 | -0/+1 |
| | |||||
* | Automate generation of the sample and debian log configs (#6627) | Richard van der Hoff | 2020-01-03 | 1 | -1/+8 |
| | |||||
* | Raise an error if someone tries to use the log_file config option (#6626) | Richard van der Hoff | 2020-01-03 | 1 | -2/+15 |
| | | | | This has caused some confusion for people who didn't notice it going away. | ||||
* | Remove last usages of deprecated logging.warn method (#6314) | Andrew Morgan | 2019-11-01 | 1 | -2/+2 |
| | |||||
* | Remove usage of deprecated logger.warn method from codebase (#6271) | Andrew Morgan | 2019-10-31 | 1 | -1/+1 |
| | | | Replace every instance of `logger.warn` with `logger.warning` as the former is deprecated. | ||||
* | Fix logging config for the docker image (#6197) | Richard van der Hoff | 2019-10-18 | 1 | -3/+2 |
| | | | | | | | | Turns out that loggers that are instantiated before the config is loaded get turned off. Also bring the logging config that is generated by --generate-config into line. Fixes #6194. | ||||
* | Refactor HomeserverConfig so it can be typechecked (#6137) | Amber Brown | 2019-10-10 | 1 | -0/+2 |
| | |||||
* | Fix for structured logging tests stomping on logs (#6023) | Amber Brown | 2019-09-13 | 1 | -8/+25 |
| | |||||
* | Add a link to python's logging config schema (#5926) | Jorik Schellekens | 2019-08-28 | 1 | -1/+2 |
| | |||||
* | Implement a structured logging output system. (#5680) | Amber Brown | 2019-08-28 | 1 | -42/+61 |
| | |||||
* | Remove non-dedicated logging options and command line arguments (#5678) | Amber Brown | 2019-07-19 | 1 | -69/+12 |
| | |||||
* | Merge branch 'develop' of github.com:matrix-org/synapse into erikj/admin_api_cmd | Erik Johnston | 2019-07-15 | 1 | -2/+2 |
|\ | |||||
| * | Move logging utilities out of the side drawer of util/ and into logging/ (#5606) | Amber Brown | 2019-07-04 | 1 | -2/+2 |
| | | |||||
* | | Change add_arguments to be a static method | Erik Johnston | 2019-07-15 | 1 | -1/+2 |
|/ | |||||
* | Don't load the generated config as the default. | Richard van der Hoff | 2019-06-24 | 1 | -1/+1 |
| | | | | It's too confusing. | ||||
* | Ensure that all config options have sensible defaults | Richard van der Hoff | 2019-06-24 | 1 | -1/+1 |
| | | | | | This will enable us to skip the unintuitive behaviour where the generated config and default config are the same thing. | ||||
* | Pass config_dir_path and data_dir_path into Config.read_config. (#5522) | Richard van der Hoff | 2019-06-24 | 1 | -1/+1 |
| | | | | | | * Pull config_dir_path and data_dir_path calculation out of read_config_files * Pass config_dir_path and data_dir_path into read_config | ||||
* | Improve logging when generating config files (#5510) | Richard van der Hoff | 2019-06-21 | 1 | -0/+4 |
| | | | Make it a bit clearer what's going on. | ||||
* | Run Black. (#5482) | Amber Brown | 2019-06-20 | 1 | -32/+38 |
| | |||||
* | Use yaml safe_load | Erik Johnston | 2019-03-22 | 1 | -1/+1 |
| | |||||
* | Include a default configuration file in the 'docs' directory. (#4791) | Richard van der Hoff | 2019-03-04 | 1 | -1/+3 |
| | |||||
* | Attempt to make default config more consistent | Richard van der Hoff | 2019-02-19 | 1 | -0/+1 |
| | | | | | | The general idea here is that config examples should just have a hash and no extraneous whitespace, both to make it easier for people who don't understand yaml, and to make the examples stand out from the comments. | ||||
* | Fix errors in acme provisioning (#4648) | Richard van der Hoff | 2019-02-14 | 1 | -0/+2 |
| | | | | | | | | | * Better logging for errors on startup * Fix "TypeError: '>' not supported" when starting without an existing certificate * Fix a bug where an existing certificate would be reprovisoned every day | ||||
* | Deduplicate some code in synapse.app (#4567) | Amber Brown | 2019-02-08 | 1 | -11/+5 |
| | |||||
* | SIGHUP for TLS cert reloading (#4495) | Amber Brown | 2019-01-30 | 1 | -8/+11 |
| | |||||
* | Add a script to generate a clean config file (#4315) | Richard van der Hoff | 2018-12-22 | 1 | -3/+1 |
| | |||||
* | Set the encoding to UTF8 in the default logconfig (#4138) | Amber Brown | 2018-11-03 | 1 | -0/+1 |
| | |||||
* | Remove some superfluous logging (#3855) | Amber Brown | 2018-09-13 | 1 | -1/+16 |
| | |||||
* | Port over enough to get some sytests running on Python 3 (#3668) | Amber Brown | 2018-08-20 | 1 | -1/+2 |
| | |||||
* | log *after* reloading log config | Richard van der Hoff | 2018-08-10 | 1 | -2/+1 |
| | | | | ... because logging *before* reloading means the log message gets lost in the old MemoryLogger | ||||
* | run isort | Amber Brown | 2018-07-09 | 1 | -2/+4 |
| | |||||
* | Write a clear restart indicator in logs | Richard van der Hoff | 2018-06-20 | 1 | -6/+18 |
| | | | | | I'm fed up with never being able to find the point a server restarted in the logs. | ||||
* | open log_config in text mode too | Adrian Tschira | 2018-04-28 | 1 | -1/+1 |
| | | | | Signed-off-by: Adrian Tschira <nota@notafile.com> | ||||
* | Merge pull request #2763 from matrix-org/rav/fix_config_uts | Richard van der Hoff | 2018-01-09 | 1 | -2/+2 |
|\ | | | | | Fix broken config UTs | ||||
| * | Fix broken config UTs | Richard van der Hoff | 2018-01-09 | 1 | -2/+2 |
| | | | | | | | | | | https://github.com/matrix-org/synapse/pull/2755 broke log-config generation, which in turn broke the unit tests. | ||||
* | | Make indentation of generated log config consistent | Richard van der Hoff | 2018-01-09 | 1 | -17/+17 |
|/ | | | | (we had a mix of 2- and 4-space indents) | ||||
* | Remove 'verbosity'/'log_file' from generated cfg | Richard van der Hoff | 2018-01-05 | 1 | -8/+4 |
| | | | | | | ... because these only really exist to confuse people nowadays. Also bring log config more into line with the generated log config, by making `level_for_storage` apply to the `synapse.storage.SQL` logger rather than `synapse.storage`. | ||||
* | Fix error when running synapse with no logfile | Richard van der Hoff | 2017-10-26 | 1 | -1/+5 |
| | | | | Fixes 'UnboundLocalError: local variable 'sighup' referenced before assignment' | ||||
* | Add helpful texts to logger config options | Richard van der Hoff | 2017-03-13 | 1 | -5/+7 |
| | |||||
* | Merge pull request #1983 from matrix-org/rav/no_redirect_stdio | Richard van der Hoff | 2017-03-13 | 1 | -6/+28 |
|\ | | | | | Add an option to disable stdio redirect | ||||
| * | Add an option to disable stdio redirect | Richard van der Hoff | 2017-03-10 | 1 | -1/+12 |
| | | | | | | | | This makes it tractable to run synapse under pdb. | ||||
| * | Refactor logger config for workers | Richard van der Hoff | 2017-03-10 | 1 | -5/+16 |
| | | | | | | | | - to make it easier to add more config options. | ||||
* | | Reread log config on SIGHUP | Richard van der Hoff | 2017-03-10 | 1 | -10/+19 |
|/ | | | | When we are using a log_config file, reread it on SIGHUP. | ||||
* | Remove full_twisted_stacktraces option | Erik Johnston | 2017-01-12 | 1 | -8/+0 |
| | | | | | | | | | | | | | | | | | The debug 'full_twisted_stacktraces' flag caused synapse to rewrite twisted deferreds to always fire the callback on the next reactor tick. This was to force the deferred to always store the stacktraces on exceptions, and thus be more likely to have a full stacktrace when it reaches the final error handlers and gets printed to the logs. Dynamically rewriting things is generally bad, and in particular this change violates assumptions of various bits of Twisted. This wouldn't necessarily be so bad, but it turns out this option has been turned on on some production servers. Turning the option can cause e.g. #1778. For now, lets just entirely nuke this option. | ||||
* | Use the new twisted logging framework. | Mark Haines | 2016-12-30 | 1 | -3/+13 |
| | | | | | Hopefully adding an observer to the new framework will avoid a memory leak https://twistedmatrix.com/trac/ticket/8164 | ||||
* | Bugfix: Console logging handler missing default filter | pik | 2016-12-03 | 1 | -0/+1 |
| | |||||
* | Inline the synchrotron and pusher configs into the main config | Mark Haines | 2016-06-16 | 1 | -49/+53 |
| | |||||
* | copyrights | Matthew Hodgson | 2016-01-07 | 1 | -1/+1 |
| | |||||
* | Only turn on the twisted deferred debugging if full_twisted_stacktraces is ↵ | Mark Haines | 2015-10-13 | 1 | -0/+8 |
| | | | | set in the config | ||||
* | Implement configurable stats reporting | Daniel Wagner-Hall | 2015-09-22 | 1 | -1/+1 |
| | | | | | | | | | | SYN-287 This requires that HS owners either opt in or out of stats reporting. When --generate-config is passed, --report-stats must be specified If an already-generated config is used, and doesn't have the report_stats key, it is requested to be set. | ||||
* | Hacky attempt at catching SIGHUP and rotating the logfile around | Paul "LeoNerd" Evans | 2015-09-14 | 1 | -0/+14 |
| | |||||
* | Write a default log_config when generating config | Mark Haines | 2015-04-30 | 1 | -1/+53 |
| | |||||
* | Manually generate the default config yaml, remove most of the commandline ↵ | Mark Haines | 2015-04-30 | 1 | -8/+27 |
| | | | | arguments for synapse anticipating that people will use the yaml instead. Simpify implementing config options by not requiring the classes to hit the super class | ||||
* | Delete ugly commented out log line. | Mark Haines | 2015-04-29 | 1 | -1/+0 |
| | |||||
* | comment out ugly test logline | Matthew Hodgson | 2015-04-29 | 1 | -1/+1 |
| | |||||
* | yaml.load expects strings to be a yaml rather than file | Erik Johnston | 2015-02-10 | 1 | -1/+2 |
| | |||||
* | Use yaml logging config format because it is much nicer | Erik Johnston | 2015-02-10 | 1 | -1/+2 |
| | |||||
* | SYN-142: Rotate logs if logging to file. Fixed to a 4 file rotate with ↵ | Kegan Dougal | 2015-01-08 | 1 | -1/+4 |
| | | | | 100MB/file for now. | ||||
* | Update copyright notices | Mark Haines | 2015-01-06 | 1 | -1/+1 |
| | |||||
* | SYN-142: Use a default log file 'homeserver.log' so people get logging by ↵ | Kegan Dougal | 2014-12-16 | 1 | -1/+1 |
| | | | | default. | ||||
* | Don't log synapse.storage at DEBUG level when under -v; require -v -v for that | Paul "LeoNerd" Evans | 2014-12-02 | 1 | -0/+6 |
| | |||||
* | Pep8 and a few doc strings | Mark Haines | 2014-10-30 | 1 | -3/+3 |
| | |||||
* | Add a request-id to each log line | Mark Haines | 2014-10-30 | 1 | -7/+16 |
| | |||||
* | fix the copyright holder from matrix.org to OpenMarket Ltd, as matrix.org ↵ | Matthew Hodgson | 2014-09-03 | 1 | -1/+1 |
| | | | | hasn't been incorporated in time for launch. | ||||
* | Fix homeserver config parsing | Mark Haines | 2014-09-01 | 1 | -7/+7 |
| | |||||
* | Add config tree to synapse. Add support for reading config from a file | Mark Haines | 2014-08-31 | 1 | -0/+67 |