Package com.xensource.xenapi
Class GPUGroup
java.lang.Object
com.xensource.xenapi.XenAPIObject
com.xensource.xenapi.GPUGroup
A group of compatible GPUs across the resource pool
First published in XenServer 6.0.
- Author:
- Cloud Software Group, Inc.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
Represents all the fields in a GPUGroup -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionvoid
addToOtherConfig
(Connection c, String key, String value) Add the given key-value pair to the other_config field of the given GPU_group.static GPUGroup
Minimum allowed role: pool-operator First published in XenServer 6.0.static Task
createAsync
(Connection c, String nameLabel, String nameDescription, Map<String, String> otherConfig) Minimum allowed role: pool-operator First published in XenServer 6.0.void
Minimum allowed role: pool-operator First published in XenServer 6.0.Minimum allowed role: pool-operator First published in XenServer 6.0.boolean
If obj is a GPUGroup, compares XenAPI references for equality.getAll
(Connection c) Return a list of all the GPU_groups known to the system.Get the allocation_algorithm field of the given GPU_group.static Map<GPUGroup,
GPUGroup.Record> Return a map of GPU_group references to GPU_group records for all GPU_groups known to the system.getByNameLabel
(Connection c, String label) Get all the GPU_group instances with the given label.static GPUGroup
getByUuid
(Connection c, String uuid) Get a reference to the GPU_group instance with the specified UUID.Get the enabled_VGPU_types field of the given GPU_group.Get the GPU_types field of the given GPU_group.Get the name/description field of the given GPU_group.Get the name/label field of the given GPU_group.Get the other_config field of the given GPU_group.Get the PGPUs field of the given GPU_group.Get a record containing the current state of the given GPU_group.getRemainingCapacity
(Connection c, VGPUType vgpuType) Minimum allowed role: read-only First published in XenServer 6.2 SP1 Tech-Preview.getRemainingCapacityAsync
(Connection c, VGPUType vgpuType) Minimum allowed role: read-only First published in XenServer 6.2 SP1 Tech-Preview.Get the supported_VGPU_types field of the given GPU_group.Get the uuid field of the given GPU_group.Get the VGPUs field of the given GPU_group.int
hashCode()
void
removeFromOtherConfig
(Connection c, String key) Remove the given key and its corresponding value from the other_config field of the given GPU_group.void
setAllocationAlgorithm
(Connection c, Types.AllocationAlgorithm allocationAlgorithm) Set the allocation_algorithm field of the given GPU_group.void
setNameDescription
(Connection c, String description) Set the name/description field of the given GPU_group.void
setNameLabel
(Connection c, String label) Set the name/label field of the given GPU_group.void
setOtherConfig
(Connection c, Map<String, String> otherConfig) Set the other_config field of the given GPU_group.Methods inherited from class com.xensource.xenapi.XenAPIObject
isNull
-
Field Details
-
ref
The XenAPI reference (OpaqueRef) to this object.
-
-
Method Details
-
toWireString
- Specified by:
toWireString
in classXenAPIObject
- Returns:
- The XenAPI reference (OpaqueRef) to this object.
-
equals
If obj is a GPUGroup, compares XenAPI references for equality. -
hashCode
public int hashCode() -
getRecord
public GPUGroup.Record getRecord(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get a record containing the current state of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- all fields from the object
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getByUuid
public static GPUGroup getByUuid(Connection c, String uuid) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get a reference to the GPU_group instance with the specified UUID. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made onuuid
- UUID of object to return- Returns:
- reference to the object
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getByNameLabel
public static Set<GPUGroup> getByNameLabel(Connection c, String label) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get all the GPU_group instances with the given label. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made onlabel
- label of object to return- Returns:
- references to objects with matching names
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getUuid
public String getUuid(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get the uuid field of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- value of the field
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getNameLabel
public String getNameLabel(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get the name/label field of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- value of the field
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getNameDescription
public String getNameDescription(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get the name/description field of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- value of the field
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getPGPUs
public Set<PGPU> getPGPUs(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get the PGPUs field of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- value of the field
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getVGPUs
public Set<VGPU> getVGPUs(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get the VGPUs field of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- value of the field
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getGPUTypes
public Set<String> getGPUTypes(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get the GPU_types field of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- value of the field
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getOtherConfig
public Map<String,String> getOtherConfig(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get the other_config field of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- value of the field
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getAllocationAlgorithm
public Types.AllocationAlgorithm getAllocationAlgorithm(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get the allocation_algorithm field of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.2 SP1 Tech-Preview.- Parameters:
c
- The connection the call is made on- Returns:
- value of the field
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getSupportedVGPUTypes
public Set<VGPUType> getSupportedVGPUTypes(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get the supported_VGPU_types field of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.2 SP1.- Parameters:
c
- The connection the call is made on- Returns:
- value of the field
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getEnabledVGPUTypes
public Set<VGPUType> getEnabledVGPUTypes(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Get the enabled_VGPU_types field of the given GPU_group. Minimum allowed role: read-only First published in XenServer 6.2 SP1.- Parameters:
c
- The connection the call is made on- Returns:
- value of the field
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
setNameLabel
public void setNameLabel(Connection c, String label) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Set the name/label field of the given GPU_group. Minimum allowed role: pool-operator First published in XenServer 6.0.- Parameters:
c
- The connection the call is made onlabel
- New value to set- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
setNameDescription
public void setNameDescription(Connection c, String description) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Set the name/description field of the given GPU_group. Minimum allowed role: pool-operator First published in XenServer 6.0.- Parameters:
c
- The connection the call is made ondescription
- New value to set- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
setOtherConfig
public void setOtherConfig(Connection c, Map<String, String> otherConfig) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcExceptionSet the other_config field of the given GPU_group. Minimum allowed role: pool-operator First published in XenServer 6.0.- Parameters:
c
- The connection the call is made onotherConfig
- New value to set- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
addToOtherConfig
public void addToOtherConfig(Connection c, String key, String value) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Add the given key-value pair to the other_config field of the given GPU_group. Minimum allowed role: pool-operator First published in XenServer 6.0.- Parameters:
c
- The connection the call is made onkey
- Key to addvalue
- Value to add- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
removeFromOtherConfig
public void removeFromOtherConfig(Connection c, String key) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Remove the given key and its corresponding value from the other_config field of the given GPU_group. If the key is not in that Map, then do nothing. Minimum allowed role: pool-operator First published in XenServer 6.0.- Parameters:
c
- The connection the call is made onkey
- Key to remove- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
setAllocationAlgorithm
public void setAllocationAlgorithm(Connection c, Types.AllocationAlgorithm allocationAlgorithm) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Set the allocation_algorithm field of the given GPU_group. Minimum allowed role: pool-operator First published in XenServer 6.2 SP1 Tech-Preview.- Parameters:
c
- The connection the call is made onallocationAlgorithm
- New value to set- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
createAsync
public static Task createAsync(Connection c, String nameLabel, String nameDescription, Map<String, String> otherConfig) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcExceptionMinimum allowed role: pool-operator First published in XenServer 6.0.- Parameters:
c
- The connection the call is made onnameLabel
- No descriptionnameDescription
- No descriptionotherConfig
- No description- Returns:
- Task
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
create
public static GPUGroup create(Connection c, String nameLabel, String nameDescription, Map<String, String> otherConfig) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcExceptionMinimum allowed role: pool-operator First published in XenServer 6.0.- Parameters:
c
- The connection the call is made onnameLabel
- No descriptionnameDescription
- No descriptionotherConfig
- No description- Returns:
- GPUGroup
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
destroyAsync
public Task destroyAsync(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Minimum allowed role: pool-operator First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- Task
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
destroy
public void destroy(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Minimum allowed role: pool-operator First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getRemainingCapacityAsync
public Task getRemainingCapacityAsync(Connection c, VGPUType vgpuType) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Minimum allowed role: read-only First published in XenServer 6.2 SP1 Tech-Preview.- Parameters:
c
- The connection the call is made onvgpuType
- The VGPU_type for which the remaining capacity will be calculated- Returns:
- Task
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getRemainingCapacity
public Long getRemainingCapacity(Connection c, VGPUType vgpuType) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Minimum allowed role: read-only First published in XenServer 6.2 SP1 Tech-Preview.- Parameters:
c
- The connection the call is made onvgpuType
- The VGPU_type for which the remaining capacity will be calculated- Returns:
- The number of VGPUs of the given type which can still be started on the PGPUs in the group
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getAll
public static Set<GPUGroup> getAll(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Return a list of all the GPU_groups known to the system. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- references to all objects
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-
getAllRecords
public static Map<GPUGroup,GPUGroup.Record> getAllRecords(Connection c) throws Types.BadServerResponse, Types.XenAPIException, org.apache.xmlrpc.XmlRpcException Return a map of GPU_group references to GPU_group records for all GPU_groups known to the system. Minimum allowed role: read-only First published in XenServer 6.0.- Parameters:
c
- The connection the call is made on- Returns:
- records of all objects
- Throws:
Types.BadServerResponse
- Thrown if the response from the server contains an invalid status.Types.XenAPIException
- Thrown if the call failed.org.apache.xmlrpc.XmlRpcException
- Thrown if the result of an asynchronous call could not be parsed.
-