Distribute the Workload

In a multiplex environment, the query optimizer breaks complex queries into fragments and distributes the fragments to different nodes for processing.

Distributing a query involves a leader node and one or more worker nodes. A query originates on the leader node. A worker node can be any node in the multiplex that can accept some of the query processing work. Any multiplex node type (reader, writer, or coordinator) can be a leader or a worker node.

The query optimizer determines whether to distribute the query. To distribute the query, the leader node breaks the query into parallel fragments and assigns the fragments to the worker nodes. The workers process the fragments and return the intermediate results. Queries that are unlikely to scale appropriately or degrade performance are not distributed; they are executed on a single node in the multiplex.

This part of the Quick Start shows how to change the multiplex to accommodate a large volume of data and run a distributed query.