Allow Synapse log levels to be configured (#23)

This commit is contained in:
Aaron Raimist 2018-11-14 13:39:52 -06:00
parent 691e52a45e
commit ddec99b899
No known key found for this signature in database
GPG Key ID: 37419210002890EF
3 changed files with 25 additions and 3 deletions

View File

@ -1,3 +1,17 @@
# 2018-11-14
## Ability to set Synapse log levels
The playbook now allows you to set the log levels used by Synapse. The default logging levels remain the same.
You can now override following variables with any of the supported log levels listed here: https://docs.python.org/3/library/logging.html#logging-levels
```
matrix_synapse_log_level: "INFO"
matrix_synapse_storage_sql_log_level: "INFO"
matrix_synapse_root_log_level: "INFO"
```
# 2018-11-03
## Customize parts of Riot's config

View File

@ -63,6 +63,14 @@ matrix_synapse_max_upload_size_mb: 10
matrix_synapse_max_log_file_size_mb: 100
matrix_synapse_max_log_files_count: 10
# Log levels
# Possible options are defined here https://docs.python.org/3/library/logging.html#logging-levels
# warning: setting log level to DEBUG will make synapse log sensitive information such
# as access tokens
matrix_synapse_log_level: "INFO"
matrix_synapse_storage_sql_log_level: "INFO"
matrix_synapse_root_log_level: "INFO"
# Rate limits
matrix_synapse_rc_messages_per_second: 0.2
matrix_synapse_rc_message_burst_count: 10.0

View File

@ -25,12 +25,12 @@ handlers:
loggers:
synapse:
level: INFO
level: {{ matrix_synapse_log_level }}
synapse.storage.SQL:
# beware: increasing this to DEBUG will make synapse log sensitive
# information such as access tokens.
level: INFO
level: {{ matrix_synapse_storage_sql_log_level }}
{% for logger in matrix_synapse_additional_loggers %}
{{ logger.name }}:
@ -38,5 +38,5 @@ loggers:
{% endfor %}
root:
level: INFO
level: {{ matrix_synapse_root_log_level }}
handlers: [file, console]