Home Explore Blog CI



postgresql

81th chunk of `doc/src/sgml/config.sgml`
9f9722b97eb589c9eb1af3925698f4999778fbb35a8d54160000000100000fa0
 <term><varname>max_active_replication_origins</varname> (<type>integer</type>)
       <indexterm>
        <primary><varname>max_active_replication_origins</varname> configuration parameter</primary>
       </indexterm>
      </term>
      <listitem>
       <para>
        Specifies how many replication origins (see
        <xref linkend="replication-origins"/>) can be tracked simultaneously,
        effectively limiting how many logical replication subscriptions can
        be created on the server. Setting it to a lower value than the current
        number of tracked replication origins (reflected in
        <link linkend="view-pg-replication-origin-status">pg_replication_origin_status</link>)
        will prevent the server from starting. It defaults to 10. This parameter
        can only be set at server start.

        <literal>max_active_replication_origins</literal> must be set to at least the
        number of subscriptions that will be added to the subscriber, plus some
        reserve for table synchronization.
       </para>
      </listitem>
     </varlistentry>

     <varlistentry id="guc-max-logical-replication-workers" xreflabel="max_logical_replication_workers">
      <term><varname>max_logical_replication_workers</varname> (<type>integer</type>)
      <indexterm>
       <primary><varname>max_logical_replication_workers</varname> configuration parameter</primary>
      </indexterm>
      </term>
      <listitem>
       <para>
        Specifies maximum number of logical replication workers. This includes
        leader apply workers, parallel apply workers, and table synchronization
        workers.
       </para>
       <para>
        Logical replication workers are taken from the pool defined by
        <varname>max_worker_processes</varname>.
       </para>
       <para>
        The default value is 4. This parameter can only be set at server
        start.
       </para>
      </listitem>
     </varlistentry>

     <varlistentry id="guc-max-sync-workers-per-subscription" xreflabel="max_sync_workers_per_subscription">
      <term><varname>max_sync_workers_per_subscription</varname> (<type>integer</type>)
      <indexterm>
       <primary><varname>max_sync_workers_per_subscription</varname> configuration parameter</primary>
      </indexterm>
      </term>
      <listitem>
       <para>
        Maximum number of synchronization workers per subscription. This
        parameter controls the amount of parallelism of the initial data copy
        during the subscription initialization or when new tables are added.
       </para>
       <para>
        Currently, there can be only one synchronization worker per table.
       </para>
       <para>
        The synchronization workers are taken from the pool defined by
        <varname>max_logical_replication_workers</varname>.
       </para>
       <para>
        The default value is 2. This parameter can only be set in the
        <filename>postgresql.conf</filename> file or on the server command
        line.
       </para>
      </listitem>
     </varlistentry>

     <varlistentry id="guc-max-parallel-apply-workers-per-subscription" xreflabel="max_parallel_apply_workers_per_subscription">
      <term><varname>max_parallel_apply_workers_per_subscription</varname> (<type>integer</type>)
      <indexterm>
       <primary><varname>max_parallel_apply_workers_per_subscription</varname> configuration parameter</primary>
      </indexterm>
      </term>
      <listitem>
       <para>
        Maximum number of parallel apply workers per subscription. This
        parameter controls the amount of parallelism for streaming of
        in-progress transactions with subscription parameter
        <literal>streaming = parallel</literal>.
       </para>
       <para>
        The parallel apply workers are taken from the pool defined by
        <varname>max_logical_replication_workers</varname>.
       </para>
       <para>
        The default value is 2. This parameter can only be

Title: max_active_replication_origins, max_logical_replication_workers, max_sync_workers_per_subscription, and max_parallel_apply_workers_per_subscription
Summary
This section describes four configuration parameters related to logical replication subscribers. `max_active_replication_origins` limits the number of replication origins that can be tracked, thus limiting the number of logical replication subscriptions. `max_logical_replication_workers` specifies the maximum number of logical replication workers, including leader apply workers, parallel apply workers, and table synchronization workers. `max_sync_workers_per_subscription` controls the parallelism of the initial data copy during subscription initialization or when new tables are added. `max_parallel_apply_workers_per_subscription` controls the amount of parallelism for streaming of in-progress transactions with subscription parameter streaming = parallel.