Skip to content
Snippets Groups Projects
config_documentation.md 138 KiB
Newer Older
  • Learn to ignore specific revisions
  • otherwise. It has no default.
    
    See also the [`pid_file` option](#pid_file) option for the main Synapse process.
    
    Example configuration:
    ```yaml
    worker_pid_file: DATADIR/generic_worker1.pid
    ```
    ---
    ### `worker_log_config`
    
    This option specifies a yaml python logging config file as described
    [here](https://docs.python.org/3/library/logging.config.html#configuration-dictionary-schema).
    See also the [`log_config` option](#log_config) option for the main Synapse process.
    
    Example configuration:
    ```yaml
    worker_log_config: /etc/matrix-synapse/generic-worker-log.yaml
    ```
    ---
    ## Background Updates
    
    Configuration settings related to background updates.
    
    
    Background updates are database updates that are run in the background in batches.
    The duration, minimum batch size, default batch size, whether to sleep between batches and if so, how long to
    sleep can all be configured. This is helpful to speed up or slow down the updates.
    This setting has the following sub-options:
    
    * `background_update_duration_ms`: How long in milliseconds to run a batch of background updates for. Defaults to 100.
    
       Set a different time to change the default.
    * `sleep_enabled`: Whether to sleep between updates. Defaults to true. Set to false to change the default.
    * `sleep_duration_ms`: If sleeping between updates, how long in milliseconds to sleep for. Defaults to 1000.
       Set a duration to change the default.
    * `min_batch_size`: Minimum size a batch of background updates can be. Must be greater than 0. Defaults to 1.
       Set a size to change the default.
    * `default_batch_size`: The batch size to use for the first iteration of a new background update. The default is 100.
       Set a size to change the default.
    
    
    ```yaml
    background_updates:
        background_update_duration_ms: 500
        sleep_enabled: false
        sleep_duration_ms: 300
        min_batch_size: 10
        default_batch_size: 50