Skip to main content

What are runtime parameters?

Runtime parameters are variables that can be set at runtime to configure the behavior of RisingWave. They are also known as session variables.

How to view runtime parameters?

You can use the SHOW ALL command to view the runtime parameters, their current settings, and some notes about these parameters.
For example, you may see a table similar to this:
Runtime Parameters
Below is the detailed information about the parameters you may see after using the SHOW ALL command: If you just want to view a specific parameter’s value, you can also use the SHOW command.

How to configure runtime parameters?

You can use SET command or the set_config() function to change the setting of a runtime parameter. The syntax of the SET command is:
Where parameter_name is the name of the parameter, and value or 'value' is the new value of the parameter. DEFAULT can be written to specify resetting the parameter to its default value. For details about the set_config() function, see System administration functions, and for details about the SET command, see SET.
SET applies only to the current session.
You can also use the ALTER SYSTEM SET command to set a system-wide default value for a runtime parameter. This configuration will then be applied to every new session.
ALTER SYSTEM SET takes effect in new sessions. The value of the runtime parameter remains unchanged in the current session.
Syntax

Usage examples

Configuring backfill parallelism

The streaming_parallelism_for_backfill parameter allows you to specify different parallelism for backfill operations versus normal streaming. This is useful for optimizing resource utilization during the initial data loading phase.
Example
The materialized view uses parallelism of 2 during the backfill phase, then automatically switches to parallelism of 3 after backfill completes.

Adaptive parallelism strategies

Streaming parallelism is configured through a single family of unified parameters:
  • streaming_parallelism — the global policy.
  • streaming_parallelism_for_<type> — per-job-type overrides, where <type> is one of table, materialized_view, index, source, or sink.
Each parameter accepts a value that either pins a fixed parallelism or selects an adaptive strategy, giving you fine-grained control over how streaming jobs utilize available worker parallelism in the resource group.

Accepted values

Each unified parameter accepts one of the following forms:
  • <n>: A positive integer, for example 4. Pins the job to a fixed parallelism. The effective parallelism is still capped by streaming_max_parallelism.
  • adaptive (or 0): Uses all available worker parallelism in the resource group. Maximizes resource utilization for high-throughput workloads.
  • bounded(<n>): Adaptive scheduling with an upper bound of <n>, for example bounded(4). The job scales with the resource group but never exceeds <n> parallel workers.
  • ratio(<r>): Adaptive scheduling using a fraction of the available worker parallelism, where 0 < r ≤ 1, for example ratio(0.5).
  • default: Falls back to the built-in default.
    • For streaming_parallelism, default resolves to bounded(64).
    • For streaming_parallelism_for_table and streaming_parallelism_for_source, default resolves to bounded(4) when streaming_parallelism is also default; otherwise it follows the resolved global value.
    • For the other streaming_parallelism_for_<type> parameters, default follows the resolved global value.

Examples

Set a session-level policy for all streaming jobs:
Pin a fixed parallelism:
Cap adaptive parallelism at an upper bound:
Override parallelism per job type within the same session:
Create a table with a specific policy:
Restore a parameter to its default:
Set a system-wide default that applies to new sessions:

Important notes

  • Per-job-type parameters (streaming_parallelism_for_<type>) take precedence over the global streaming_parallelism. When a per-type parameter is default, it inherits from the resolved global value, with the exceptions for table and source noted above.
  • The resolved policy is persisted with the streaming job at creation time and remains effective even if session or system-level settings change later.
  • The concrete policy for each job is visible in system catalogs and diagnostics. Fixed parallelism displays as an integer (for example, 4); adaptive policies display as adaptive, bounded(<n>), or ratio(<r>). This applies to pg_catalog.pg_settings, rw_streaming_parallelism, rw_streaming_jobs, rw_table_fragments, and diagnose-style output.
  • ALTER TABLE|SOURCE|SINK|INDEX|MATERIALIZED VIEW ... SET PARALLELISM accepts the same value forms (adaptive, 0, a fixed integer, bounded(<n>), ratio(<r>)). Fragment-level ALTER ... SET PARALLELISM remains limited to adaptive and fixed integers.
Older releases exposed the deprecated parameters adaptive_parallelism_strategy (system-level) and streaming_parallelism_strategy / streaming_parallelism_strategy_for_<type> (session-level). On upgrade, meta migrates their values into streaming_parallelism and streaming_parallelism_for_<type> once, then removes the deprecated entries. New clusters only expose the unified parameters, and pg_catalog.pg_settings no longer lists adaptive_parallelism_strategy.