public class AlterResourceGroupRequest extends Object implements org.apache.avro.generic.IndexedRecord
GPUdb.alterResourceGroup
.
Alters the properties of an exisiting resource group to facilitate resource management.
Modifier and Type | Class and Description |
---|---|
static class |
AlterResourceGroupRequest.Options
A set of string constants for the
AlterResourceGroupRequest
parameter options . |
static class |
AlterResourceGroupRequest.Ranking
A set of string constants for the
AlterResourceGroupRequest
parameter ranking . |
static class |
AlterResourceGroupRequest.TierAttributes
A set of string constants for the
AlterResourceGroupRequest
parameter tierAttributes . |
Constructor and Description |
---|
AlterResourceGroupRequest()
Constructs an AlterResourceGroupRequest object with default parameters.
|
AlterResourceGroupRequest(String name,
Map<String,Map<String,String>> tierAttributes,
String ranking,
String adjoiningResourceGroup,
Map<String,String> options)
Constructs an AlterResourceGroupRequest object with the specified
parameters.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
Object |
get(int index)
This method supports the Avro framework and is not intended to be called
directly by the user.
|
String |
getAdjoiningResourceGroup()
|
static org.apache.avro.Schema |
getClassSchema()
This method supports the Avro framework and is not intended to be called
directly by the user.
|
String |
getName()
Name of the group to be altered.
|
Map<String,String> |
getOptions()
Optional parameters.
|
String |
getRanking()
If the resource group ranking is to be updated, this indicates the
relative ranking among existing resource groups where this resource
group will be moved; leave blank if not changing the ranking.
|
org.apache.avro.Schema |
getSchema()
This method supports the Avro framework and is not intended to be called
directly by the user.
|
Map<String,Map<String,String>> |
getTierAttributes()
Optional map containing tier names and their respective attribute group
limits.
|
int |
hashCode() |
void |
put(int index,
Object value)
This method supports the Avro framework and is not intended to be called
directly by the user.
|
AlterResourceGroupRequest |
setAdjoiningResourceGroup(String adjoiningResourceGroup)
|
AlterResourceGroupRequest |
setName(String name)
Name of the group to be altered.
|
AlterResourceGroupRequest |
setOptions(Map<String,String> options)
Optional parameters.
|
AlterResourceGroupRequest |
setRanking(String ranking)
If the resource group ranking is to be updated, this indicates the
relative ranking among existing resource groups where this resource
group will be moved; leave blank if not changing the ranking.
|
AlterResourceGroupRequest |
setTierAttributes(Map<String,Map<String,String>> tierAttributes)
Optional map containing tier names and their respective attribute group
limits.
|
String |
toString() |
public AlterResourceGroupRequest()
public AlterResourceGroupRequest(String name, Map<String,Map<String,String>> tierAttributes, String ranking, String adjoiningResourceGroup, Map<String,String> options)
name
- Name of the group to be altered. Must be an existing
resource group name or an empty string when used
inconjunction with the is_default_group option.tierAttributes
- Optional map containing tier names and their
respective attribute group limits. The only
valid attribute limit that can be set is
max_memory (in bytes) for the VRAM & RAM tiers.
For instance, to set max VRAM capacity to 1GB and
max RAM capacity to 10GB, use:
{'VRAM':{'max_memory':'1000000000'},
'RAM':{'max_memory':'10000000000'}}.
MAX_MEMORY
: Maximum amount of memory
usable in the given tier at one time for
this group.
Map
.ranking
- If the resource group ranking is to be updated, this
indicates the relative ranking among existing resource
groups where this resource group will be moved; leave
blank if not changing the ranking. When using BEFORE
or AFTER
,
specify which resource group this one will be inserted
before or after in adjoiningResourceGroup
.
Supported values:
The default value is EMPTY_STRING
.adjoiningResourceGroup
- If ranking
is BEFORE
or AFTER
, this field
indicates the resource group before or
after which the current group will be
placed; otherwise, leave blank. The
default value is ''.options
- Optional parameters.
MAX_CPU_CONCURRENCY
: Maximum number of
simultaneous threads that will be used to
execute a request for this group. The minimum
allowed value is '4'.
MAX_DATA
: Maximum
amount of cumulative ram usage regardless of
tier status for this group. The minimum allowed
value is '-1'.
MAX_SCHEDULING_PRIORITY
: Maximum priority of a
scheduled task for this group. The minimum
allowed value is '1'. The maximum allowed value
is '100'.
MAX_TIER_PRIORITY
: Maximum priority of a tiered
object for this group. The minimum allowed value
is '1'. The maximum allowed value is '10'.
IS_DEFAULT_GROUP
: If TRUE
,
this request applies to the global default
resource group. It is an error for this field to
be TRUE
when the name
field is also populated.
Supported values:
The default value is FALSE
.
PERSIST
: If TRUE
and a system-level change was
requested, the system configuration will be
written to disk upon successful application of
this request. This will commit the changes from
this request and any additional in-memory
modifications.
Supported values:
The default value is TRUE
.
Map
.public static org.apache.avro.Schema getClassSchema()
public String getName()
name
.public AlterResourceGroupRequest setName(String name)
name
- The new value for name
.this
to mimic the builder pattern.public Map<String,Map<String,String>> getTierAttributes()
For instance, to set max VRAM capacity to 1GB and max RAM capacity to 10GB, use: {'VRAM':{'max_memory':'1000000000'}, 'RAM':{'max_memory':'10000000000'}}.
MAX_MEMORY
: Maximum amount of
memory usable in the given tier at one time for this group.
Map
.tierAttributes
.public AlterResourceGroupRequest setTierAttributes(Map<String,Map<String,String>> tierAttributes)
For instance, to set max VRAM capacity to 1GB and max RAM capacity to 10GB, use: {'VRAM':{'max_memory':'1000000000'}, 'RAM':{'max_memory':'10000000000'}}.
MAX_MEMORY
: Maximum amount of
memory usable in the given tier at one time for this group.
Map
.tierAttributes
- The new value for tierAttributes
.this
to mimic the builder pattern.public String getRanking()
BEFORE
or AFTER
,
specify which resource group this one will be inserted before or after
in adjoiningResourceGroup
.
Supported values:
The default value is EMPTY_STRING
.ranking
.public AlterResourceGroupRequest setRanking(String ranking)
BEFORE
or AFTER
,
specify which resource group this one will be inserted before or after
in adjoiningResourceGroup
.
Supported values:
The default value is EMPTY_STRING
.ranking
- The new value for ranking
.this
to mimic the builder pattern.public String getAdjoiningResourceGroup()
ranking
is BEFORE
or
AFTER
, this field indicates the resource group
before or after which the current group will be placed; otherwise, leave
blank. The default value is ''.adjoiningResourceGroup
.public AlterResourceGroupRequest setAdjoiningResourceGroup(String adjoiningResourceGroup)
ranking
is BEFORE
or
AFTER
, this field indicates the resource group
before or after which the current group will be placed; otherwise, leave
blank. The default value is ''.adjoiningResourceGroup
- The new value for adjoiningResourceGroup
.this
to mimic the builder pattern.public Map<String,String> getOptions()
MAX_CPU_CONCURRENCY
: Maximum
number of simultaneous threads that will be used to execute a
request for this group. The minimum allowed value is '4'.
MAX_DATA
: Maximum amount of cumulative
ram usage regardless of tier status for this group. The minimum
allowed value is '-1'.
MAX_SCHEDULING_PRIORITY
:
Maximum priority of a scheduled task for this group. The minimum
allowed value is '1'. The maximum allowed value is '100'.
MAX_TIER_PRIORITY
: Maximum
priority of a tiered object for this group. The minimum allowed
value is '1'. The maximum allowed value is '10'.
IS_DEFAULT_GROUP
: If TRUE
, this request applies to the global default
resource group. It is an error for this field to be TRUE
when the name
field is
also populated.
Supported values:
The default value is FALSE
.
PERSIST
: If TRUE
and a system-level change was requested, the system
configuration will be written to disk upon successful
application of this request. This will commit the changes from
this request and any additional in-memory modifications.
Supported values:
The default value is TRUE
.
Map
.options
.public AlterResourceGroupRequest setOptions(Map<String,String> options)
MAX_CPU_CONCURRENCY
: Maximum
number of simultaneous threads that will be used to execute a
request for this group. The minimum allowed value is '4'.
MAX_DATA
: Maximum amount of cumulative
ram usage regardless of tier status for this group. The minimum
allowed value is '-1'.
MAX_SCHEDULING_PRIORITY
:
Maximum priority of a scheduled task for this group. The minimum
allowed value is '1'. The maximum allowed value is '100'.
MAX_TIER_PRIORITY
: Maximum
priority of a tiered object for this group. The minimum allowed
value is '1'. The maximum allowed value is '10'.
IS_DEFAULT_GROUP
: If TRUE
, this request applies to the global default
resource group. It is an error for this field to be TRUE
when the name
field is
also populated.
Supported values:
The default value is FALSE
.
PERSIST
: If TRUE
and a system-level change was requested, the system
configuration will be written to disk upon successful
application of this request. This will commit the changes from
this request and any additional in-memory modifications.
Supported values:
The default value is TRUE
.
Map
.options
- The new value for options
.this
to mimic the builder pattern.public org.apache.avro.Schema getSchema()
getSchema
in interface org.apache.avro.generic.GenericContainer
public Object get(int index)
get
in interface org.apache.avro.generic.IndexedRecord
index
- the position of the field to getIndexOutOfBoundsException
public void put(int index, Object value)
put
in interface org.apache.avro.generic.IndexedRecord
index
- the position of the field to setvalue
- the value to setIndexOutOfBoundsException
Copyright © 2025. All rights reserved.