final class AlterResourceGroup
    implements Statement
    uses Snapshot
Public API: explicitly declared with @visibility public.

ALTER RESOURCE GROUP name [VCPU = …] [THREAD_PRIORITY = n] [ENABLE|DISABLE] [FORCE] (8.0+).

Mirrors PT_alter_resource_group. Rule: MYSQL-RESOURCE-GROUP-001. The type of the group is not written, and groups are not declared in a context, so the priority range cannot be checked. Source: https://dev.mysql.com/doc/refman/8.4/en/alter-resource-group.html. Status: Implemented.

Disabling a group by forcedoctest
(new \SqlSemantics\Platform\MySql\Semantics())->analyze('alter resource group batch disable force')->toString() // => 'ALTER RESOURCE GROUP batch DISABLE FORCE'

Properties§

public list<CpuRange> $cpus
public Name $name
public ThreadPriority|null $priority = null
public bool|null $enabled = null
public bool $force = false

Methods§

public function __construct(
    public Name $name,
    list<CpuRange> $cpus = [],
    public ThreadPriority|null $priority = null,
    public bool|null $enabled = null,
    public bool $force = false,
)

Parameters

$nameNameThe group name
$cpuslist<CpuRange>The CPUs of VCPU; none when the option is absent
$priorityThreadPriority|nullThe THREAD_PRIORITY, when written
$enabledbool|nullENABLE (true) or DISABLE (false), when written
$forceboolWhether FORCE is written
Calls 2
public function deriveStatement(Derivation $derivation): void

Derives nothing: the statement names no relation and no expression.

Parameters

$derivationDerivation
public function render(Output $out): void

Writes the request.

Parameters

$outOutput
Calls 2

Test cases 1§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 1

Relations§

Instantiated in 1