Setting Parameter Values
The parameters documented on this page apply to users of Spock extension version 4.0 and higher. You can use the pgEdge Platform UM module to upgrade your installed version of the Spock extension.
pgEdge Platform uses parameter settings in the postgresql.conf (opens in a new tab) file to manage the replication behavior of PostgreSQL and the extensions that provide advanced functionality for pgEdge.
Parameters are set to their default values when you install pgEdge. You can modify the parameter values later, but should consider the default values to be the minimum values required; we do not recommend lowering these values:
Parameter Name | Valid/Default Settings and Description |
---|---|
hot_standby_feedback (opens in a new tab) | on ; this setting is required. |
max_worker_processes (opens in a new tab) | 12 ; this is the minimum value required. |
max_replication_slots (opens in a new tab) | 16 ; this is the minimum value required. |
max_wal_senders (opens in a new tab) | 16 ; this is the minimum value required. |
shared_preload_libraries (opens in a new tab) | pg_stat_statements , snowflake , spock ; include these values to use pgEdge replication features. |
snowflake.node (opens in a new tab) | The snowflake node number; this value is unique to each node. |
spock.allow_ddl_from_functions (opens in a new tab) | off ; Use this GUC to specify automatic ddl replication behavior. |
spock.conflict_resolution (opens in a new tab) | last_update_wins ; spock.conflict_resolution sets the resolution method for any detected conflicts between local data and incoming changes. Possible values are: error (stop on error if a conflict is detected), apply_remote (always apply the change that's conflicting with local data), keep_local (keep the local version of the data and ignore the conflicting change), last_update_wins (the newest commit timestamp will be retained). To enable conflict resolution, enable track_commit_timestamp as well. |
spock.conflict_log_level (opens in a new tab) | The log level to use for logging conflicts; the default is: DEBUG . |
spock.enable_ddl_replication (opens in a new tab) | off ; Use this GUC to control automatic ddl replication behavior. |
spock.exception_behaviour (opens in a new tab) | discard , transdiscard , or sub-disable ; the default is transdiscard (if an error occurs, all operations are rolled back, regardless of succeeding or failing). Sub-disable disables the subscription for the node on which the exception was reported, and adds transactions for the disabled node to a queue that is written to the WAL log file; when the subscription is enabled, replication resumes with the transaction that caused the exception, followed by the other queued transactions. |
spock.exception_logging (opens in a new tab) | none ,discard , or all Use spock.exception_logging to specify a preference about logging exceptions when they occur. |
spock.include_ddl_repset (opens in a new tab) | off ; automatically add tables to replication sets at the time they are created on each node. |
spock.readonly (opens in a new tab) | all , user , or off . The default of off means that the database is fully read/write. user means database can be updated by replication, but not by a client application. all means database is 100% read only and not even spock can modify it. Read only workloads are always allowed. |
spock.save_resolutions (opens in a new tab) | off ; log all conflict resolutions to the spock.resolutions table. This option can only be set when the postmaster starts. |
track_commit_timestamp (opens in a new tab) | on ; this setting is required. |
wal_level (opens in a new tab) | logical ; this setting is required by pgEdge. |
wal_sender_timeout (opens in a new tab) | 5s ; this is the minimum value required. |
Note: On a Multi-master replication system, these parameter settings should be identical on each node. Additionally, the roles created on each node should be the same.