classAlterResourceGroup
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.
(new \SqlSemantics\Platform\MySql\Semantics())->analyze('alter resource group batch disable force')->toString() // => 'ALTER RESOURCE GROUP batch DISABLE FORCE'Properties§
public list<CpuRange> $cpuspublic Name $namepublic ThreadPriority|null $priority = nullpublic bool|null $enabled = nullpublic bool $force = falseMethods§
public function __construct(
public Name $name,
list<CpuRange> $cpus = [],
public ThreadPriority|null $priority = null,
public bool|null $enabled = null,
public bool $force = false,
)Parameters
$name | Name | The group name |
$cpus | list<CpuRange> | The CPUs of VCPU; none when the option is absent |
$priority | ThreadPriority|null | The THREAD_PRIORITY, when written |
$enabled | bool|null | ENABLE (true) or DISABLE (false), when written |
$force | bool | Whether FORCE is written |
Calls 2
- static-call Check::listOf() line 45
- class-const CpuRange::class() line 45
public function deriveStatement(Derivation $derivation): voidDerives nothing: the statement names no relation and no expression.
Parameters
$derivation | Derivation |
public function render(Output $out): voidWrites the request.
Parameters
$out | Output |
Calls 2
- method-call Output::keyword() line 60
- class-const NameUse::Label() line 60
Test cases 1§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 1
AlterResourceGroupTestcalls