SingleStore DB

Setting Resource Limits

Through its Resource Governor feature, SingleStore DB allows you to define resource pools, which can specify resource limits. As an example, you can use these resource limits to prevent one user’s query from making the system unusable for others connected to the database. This allows you to prevent non-critical workloads from overloading the system.

You can set the limits MEMORY_PERCENTAGE, SOFT_CPU_LIMIT_PERCENTAGE, HARD_CPU_LIMIT_PERCENTAGE, QUERY_TIMEOUT, MAX_CONCURRENCY, and MAX_QUEUE_DEPTH in resource pools. For information on these settings, see CREATE RESOURCE POOL.

Each client connection is assigned to a resource pool that specifies some (or all) of these limits.

Notice

Resource limits are for all databases in a cluster. It is not possible to set limits at the database level.

Resource limits also apply to any LOAD DATA queries, internal sampling queries, or stored procedures that are run by a user within a given resource pool.

Related to setting resource limits through governance is the concept of workload management. Workload management is a component of SingleStore DB that automatically manages cluster workloads by limiting execution of queries that require fully distributed execution, to ensure that they are matched with available system resources. For more information, see Workload Management.