Documentation
¶
Overview ¶
API Actor for managing Compute Group. This actor is a final API for endusers to manage Compute Group
Index ¶
- type BService
- func (b BService) Create(ctx context.Context, req CreateRequest) (uint64, error)
- func (b BService) Delete(ctx context.Context, req DeleteRequest) (bool, error)
- func (b BService) Disable(ctx context.Context, req DisableRequest) (bool, error)
- func (b BService) Enable(ctx context.Context, req EnableRequest) (bool, error)
- func (b BService) Get(ctx context.Context, req GetRequest) (*RecordBasicService, error)
- func (b BService) GroupAdd(ctx context.Context, req GroupAddRequest) (uint64, error)
- func (b BService) GroupComputeRemove(ctx context.Context, req GroupComputeRemoveRequest) (bool, error)
- func (b BService) GroupGet(ctx context.Context, req GroupGetRequest) (*RecordGroup, error)
- func (b BService) GroupParentAdd(ctx context.Context, req GroupParentAddRequest) (bool, error)
- func (b BService) GroupParentRemove(ctx context.Context, req GroupParentRemoveRequest) (bool, error)
- func (b BService) GroupRemove(ctx context.Context, req GroupRemoveRequest) (bool, error)
- func (b BService) GroupResize(ctx context.Context, req GroupResizeRequest) (uint64, error)
- func (b BService) GroupStart(ctx context.Context, req GroupStartRequest) (bool, error)
- func (b BService) GroupStop(ctx context.Context, req GroupStopRequest) (bool, error)
- func (b BService) GroupUpdate(ctx context.Context, req GroupUpdateRequest) (bool, error)
- func (b BService) GroupUpdateExtNet(ctx context.Context, req GroupUpdateExtNetRequest) (bool, error)
- func (b BService) GroupUpdateVINS(ctx context.Context, req GroupUpdateVINSRequest) (bool, error)
- func (b BService) List(ctx context.Context, req ListRequest) (*ListBasicServices, error)
- func (b BService) ListDeleted(ctx context.Context, req ListDeletedRequest) (*ListBasicServices, error)
- func (b BService) Restore(ctx context.Context, req RestoreRequest) (bool, error)
- func (b BService) SnapshotCreate(ctx context.Context, req SnapshotCreateRequest) (bool, error)
- func (b BService) SnapshotDelete(ctx context.Context, req SnapshotDeleteRequest) (bool, error)
- func (b BService) SnapshotList(ctx context.Context, req SnapshotListRequest) (ListSnapshots, error)
- func (b BService) SnapshotRollback(ctx context.Context, req SnapshotRollbackRequest) (bool, error)
- func (b BService) Start(ctx context.Context, req StartRequest) (bool, error)
- func (b BService) Stop(ctx context.Context, req StopRequest) (bool, error)
- type CreateRequest
- type DeleteRequest
- type DisableRequest
- type EnableRequest
- type GetRequest
- type GroupAddRequest
- type GroupComputeRemoveRequest
- type GroupGetRequest
- type GroupParentAddRequest
- type GroupParentRemoveRequest
- type GroupRemoveRequest
- type GroupResizeRequest
- type GroupStartRequest
- type GroupStopRequest
- type GroupUpdateExtNetRequest
- type GroupUpdateRequest
- type GroupUpdateVINSRequest
- type ItemBasicService
- type ItemCompute
- type ItemGroup
- type ItemGroupCompute
- type ItemOSUser
- type ItemSnapshot
- type ListBasicServices
- func (lbs ListBasicServices) FilterByID(id uint64) ListBasicServices
- func (lbs ListBasicServices) FilterByName(name string) ListBasicServices
- func (lbs ListBasicServices) FilterByRGID(rgID uint64) ListBasicServices
- func (lbs ListBasicServices) FilterByStatus(status string) ListBasicServices
- func (lbs ListBasicServices) FilterByTechStatus(techStatus string) ListBasicServices
- func (lbs ListBasicServices) FilterFunc(predicate func(ItemBasicService) bool) ListBasicServices
- func (lbs ListBasicServices) FindOne() ItemBasicService
- func (lbs ListBasicServices) Serialize(params ...string) (serialization.Serialized, error)
- func (lbs ListBasicServices) SortByCreatedTime(inverse bool) ListBasicServices
- func (lbs ListBasicServices) SortByDeletedTime(inverse bool) ListBasicServices
- func (lbs ListBasicServices) SortByUpdatedTime(inverse bool) ListBasicServices
- type ListComputes
- type ListDeletedRequest
- type ListGroupComputes
- type ListGroups
- type ListOSUsers
- type ListRequest
- type ListSnapshots
- type RecordBasicService
- type RecordGroup
- type RestoreRequest
- type SnapshotCreateRequest
- type SnapshotDeleteRequest
- type SnapshotListRequest
- type SnapshotRollbackRequest
- type StartRequest
- type StopRequest
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BService ¶
type BService struct {
// contains filtered or unexported fields
}
Structure for creating request to bservice
func (BService) Disable ¶
Disable disables service. Disabling a service technically means setting model status of all computes and service itself to DISABLED and stopping all computes.
func (BService) Enable ¶
Enable enables service. Enabling a service technically means setting model status of all computes and service itself to ENABLED. It does not start computes.
func (BService) Get ¶
func (b BService) Get(ctx context.Context, req GetRequest) (*RecordBasicService, error)
Get gets detailed specifications for the BasicService.
func (BService) GroupAdd ¶
GroupAdd creates new Compute Group within BasicService. Compute Group is NOT started automatically, so you need to explicitly start it
func (BService) GroupComputeRemove ¶
func (b BService) GroupComputeRemove(ctx context.Context, req GroupComputeRemoveRequest) (bool, error)
GroupComputeRemove makes group compute remove of the Basic Service
func (BService) GroupGet ¶
func (b BService) GroupGet(ctx context.Context, req GroupGetRequest) (*RecordGroup, error)
GroupGet gets detailed specifications for the Compute Group
func (BService) GroupParentAdd ¶
GroupParentAdd add parent Compute Group relation to the specified Compute Group
func (BService) GroupParentRemove ¶
func (b BService) GroupParentRemove(ctx context.Context, req GroupParentRemoveRequest) (bool, error)
GroupParentRemove removes parent Compute Group relation to the specified Compute Group
func (BService) GroupRemove ¶
GroupRemove destroy the specified Compute Group
func (BService) GroupResize ¶
GroupResize resize the group by changing the number of computes
func (BService) GroupStart ¶
GroupStart starts the specified Compute Group within BasicService
func (BService) GroupUpdate ¶
GroupUpdate updates existing Compute group within Basic Service and apply new settings to its computes as necessary
func (BService) GroupUpdateExtNet ¶
func (b BService) GroupUpdateExtNet(ctx context.Context, req GroupUpdateExtNetRequest) (bool, error)
GroupUpdateExtNet updates External Network settings for the group according to the new list
func (BService) GroupUpdateVINS ¶
GroupUpdateVINS update ViNS settings for the group according to the new list
func (BService) List ¶
func (b BService) List(ctx context.Context, req ListRequest) (*ListBasicServices, error)
List gets list BasicService instances associated with the specified Resource Group
func (BService) ListDeleted ¶
func (b BService) ListDeleted(ctx context.Context, req ListDeletedRequest) (*ListBasicServices, error)
ListDeleted gets list deleted BasicService instances associated with the specified Resource Group
func (BService) SnapshotCreate ¶
SnapshotCreate create snapshot of the Basic Service
func (BService) SnapshotDelete ¶
SnapshotDelete delete snapshot of the Basic Service
func (BService) SnapshotList ¶
func (b BService) SnapshotList(ctx context.Context, req SnapshotListRequest) (ListSnapshots, error)
SnapshotList gets list existing snapshots of the Basic Service
func (BService) SnapshotRollback ¶
SnapshotRollback rollback snapshot of the Basic Service
type CreateRequest ¶
type CreateRequest struct { // Name of the service // Required: true Name string `url:"name" json:"name" validate:"required"` // ID of the Resource Group where this service will be placed // Required: true RGID uint64 `url:"rgId" json:"rgId" validate:"required"` // Name of the user to deploy SSH key for. Pass empty string if no SSH key deployment is required // Required: false SSHUser string `url:"sshUser,omitempty" json:"sshUser,omitempty"` // SSH key to deploy for the specified user. Same key will be deployed to all computes of the service // Required: false SSHKey string `url:"sshKey,omitempty" json:"sshKey,omitempty"` }
Request struct for BasicService
type DeleteRequest ¶
type DeleteRequest struct { // ID of the BasicService to be delete // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // If set to False, Basic service will be deleted to recycle bin. Otherwise destroyed immediately // Required: false Permanently bool `url:"permanently,omitempty" json:"permanently,omitempty"` }
Request struct for delete basic service
type DisableRequest ¶
type DisableRequest struct { // ID of the service to disable // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` }
Request struct for disable service
type EnableRequest ¶
type EnableRequest struct { // ID of the service to enable // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` }
Request struct for disable service
type GetRequest ¶
type GetRequest struct { // ID of the service to query information // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` }
Request struct for get detailed information about service
type GroupAddRequest ¶
type GroupAddRequest struct { // ID of the Basic Service to add a group to // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // Name of the Compute Group to add // Required: true Name string `url:"name" json:"name" validate:"required"` // Computes number. Defines how many computes must be there in the group // Required: true Count uint64 `url:"count" json:"count" validate:"required"` // Compute CPU number. All computes in the group have the same CPU count // Required: true CPU uint64 `url:"cpu" json:"cpu" validate:"required"` // Compute RAM volume in MB. All computes in the group have the same RAM volume // Required: true RAM uint64 `url:"ram" json:"ram" validate:"required"` // Compute boot disk size in GB // Required: true Disk uint64 `url:"disk" json:"disk" validate:"required"` // OS image ID to create computes from // Required: true ImageID uint64 `url:"imageId" json:"imageId" validate:"required"` // Compute driver // should be one of: // - KVM_X86 // - KVM_PPC // Required: true Driver string `url:"driver" json:"driver" validate:"driver"` // Storage endpoint provider ID // Required: false SEPID uint64 `url:"sepId,omitempty" json:"sepId,omitempty"` // Pool to use if sepId is set, can be also empty if needed to be chosen by system // Required: false SEPPool string `url:"sepPool,omitempty" json:"sepPool,omitempty"` // Group role tag. Can be empty string, does not have to be unique // Required: false Role string `url:"role,omitempty" json:"role,omitempty"` // List of ViNSes to connect computes to // Required: false VINSes []uint64 `url:"vinses,omitempty" json:"vinses,omitempty"` // List of external networks to connect computes to // Required: false ExtNets []uint64 `url:"extnets,omitempty" json:"extnets,omitempty"` // Time of Compute Group readiness // Required: false TimeoutStart uint64 `url:"timeoutStart,omitempty" json:"timeoutStart,omitempty"` // Meta data for working group computes, format YAML "user_data": 1111 // Required: false UserData string `url:"userData,omitempty" json:"userData,omitempty"` }
Request struct for create new compute group within BasicService
type GroupComputeRemoveRequest ¶
type GroupComputeRemoveRequest struct { // ID of the Basic Service // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute GROUP // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` // ID of the Compute // Required: true ComputeID uint64 `url:"computeId" json:"computeId" validate:"required"` }
Request struct for remove group compute
type GroupGetRequest ¶
type GroupGetRequest struct { // ID of the Basic Service of Compute Group // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute Group // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` }
Request struct for get detailed information about Compute Group
type GroupParentAddRequest ¶
type GroupParentAddRequest struct { // ID of the Basic Service of Compute Group // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute Group // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` // ID of the parent Compute Group to register with the current Compute Group // Required: true ParentID uint64 `url:"parentId" json:"parentId" validate:"required"` }
Request struct for add parent Compute Group relation emove parent Compute Group relation to the specified Compute Group
type GroupParentRemoveRequest ¶
type GroupParentRemoveRequest struct { // ID of the Basic Service of Compute Group // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute Group // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` // ID of the parent Compute Group // to remove from the current Compute Group // Required: true ParentID uint64 `url:"parentId" json:"parentId" validate:"required"` }
Request struct for remove parent Compute Group relation to the specified Compute Group
type GroupRemoveRequest ¶
type GroupRemoveRequest struct { // ID of the Basic Service of Compute Group // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute Group // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` }
Request struct for destroy the specified Compute Group
type GroupResizeRequest ¶
type GroupResizeRequest struct { // ID of the Basic Service of Compute Group // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute Group to resize // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` // Either delta or absolute value of computes // Required: true Count int64 `url:"count" json:"count" validate:"required"` // Either delta or absolute value of computes // Should be one of: // - ABSOLUTE // - RELATIVE // Required: true Mode string `url:"mode" json:"mode" validate:"bserviceMode"` }
Request struct for resize the group
type GroupStartRequest ¶
type GroupStartRequest struct { // ID of the Basic Service of Compute Group // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute Group to start // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` }
Request struct for start the specified Compute Group
type GroupStopRequest ¶
type GroupStopRequest struct { // ID of the Basic Service of Compute Group // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute Group to stop // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` // Force stop Compute Group // Required: false Force bool `url:"force,omitempty" json:"force,omitempty"` }
Request struct for stop the specified Compute Group
type GroupUpdateExtNetRequest ¶
type GroupUpdateExtNetRequest struct { // ID of the Basic Service of Compute Group // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute Group // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` // List of Extnets to connect computes // Required: false ExtNets []uint64 `url:"extnets,omitempty" json:"extnets,omitempty"` }
Request struct for update External Network settings
type GroupUpdateRequest ¶
type GroupUpdateRequest struct { // ID of the Basic Service of Compute Group // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute Group // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` // Specify non-empty string to update Compute Group name // Required: false Name string `url:"name,omitempty" json:"name,omitempty"` // Specify non-empty string to update group role // Required: false Role string `url:"role,omitempty" json:"role,omitempty"` // Specify positive value to set new compute CPU count // Required: false CPU uint64 `url:"cpu,omitempty" json:"cpu,omitempty"` // Specify positive value to set new compute RAM volume in MB // Required: false RAM uint64 `url:"ram,omitempty" json:"ram,omitempty"` // Specify new compute boot disk size in GB // Required: false Disk uint64 `url:"disk,omitempty" json:"disk,omitempty"` // Force resize Compute Group // Required: false Force bool `url:"force,omitempty" json:"force,omitempty"` }
Request struct for update existing Compute group
type GroupUpdateVINSRequest ¶
type GroupUpdateVINSRequest struct { // ID of the Basic Service of Compute Group // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // ID of the Compute Group // Required: true CompGroupID uint64 `url:"compgroupId" json:"compgroupId" validate:"required"` // List of ViNSes to connect computes // Required: false VINSes []uint64 `url:"vinses,omitempty" json:"vinses,omitempty"` }
Request struct for update VINS settings
type ItemBasicService ¶
type ItemBasicService struct { // Account ID AccountID uint64 `json:"accountId"` // Account name AccountName string `json:"accountName"` // Base domain BaseDomain string `json:"baseDomain"` // Created by CreatedBy string `json:"createdBy"` // Created time CreatedTime uint64 `json:"createdTime"` // Deleted by DeletedBy string `json:"deletedBy"` // Deleted time DeletedTime uint64 `json:"deletedTime"` // Grid ID GID uint64 `json:"gid"` // List of group IDs Groups []uint64 `json:"groups"` // GUID GUID uint64 `json:"guid"` // ID ID uint64 `json:"id"` // Name Name string `json:"name"` // Parent service ID ParentSrvID uint64 `json:"parentSrvId"` // Parent service type ParentSrvType string `json:"parentSrvType"` // Resource group ID RGID uint64 `json:"rgId"` // Resource group name RGName string `json:"rgName"` // SSH user SSHUser string `json:"sshUser"` // Status Status string `json:"status"` // TechStatus TechStatus string `json:"techStatus"` // Updated by UpdatedBy string `json:"updatedBy"` // Updated time UpdatedTime uint64 `json:"updatedTime"` // User Managed or not UserManaged bool `json:"userManaged"` }
Main information about BasicService
func (ItemBasicService) Serialize ¶
func (ibs ItemBasicService) Serialize(params ...string) (serialization.Serialized, error)
Serialize returns JSON-serialized []byte. Used as a wrapper over json.Marshal and json.MarshalIndent functions.
In order to serialize with indent make sure to follow these guidelines:
- First argument -> prefix
- Second argument -> indent
type ItemCompute ¶
type ItemCompute struct { // Account ID AccountID uint64 // Architecture Architecture string `json:"arch"` // Compute group ID CompGroupID uint64 `json:"compgroupId"` // Compute group name CompGroupName string `json:"compgroupName"` // compute group role CompGroupRole string `json:"compgroupRole"` // ID ID uint64 `json:"id"` // Name Name string `json:"name"` // Resource group ID RGID uint64 `json:"rgId"` // StackID StackID uint64 `json:"stackId"` // Status Status string `json:"status"` // Tech status TechStatus string `json:"techStatus"` }
Main information about Compute
type ItemGroup ¶ added in v1.4.0
type ItemGroup struct { // Amount of computes Computes uint64 `json:"computes"` // Consistency Consistency bool `json:"consistency"` // Group ID ID uint64 `json:"id"` // Group name Name string `json:"name"` // Status Status string `json:"status"` // TechStatus TechStatus string `json:"techStatus"` }
Main information about Group
type ItemGroupCompute ¶
type ItemGroupCompute struct { // ID ID uint64 `json:"id"` // IP Addresses IPAddresses []string `json:"ipAddresses"` // Name Name string `json:"name"` // List of information about OS Users OSUsers ListOSUsers `json:"osUsers"` }
Main information about Group Compute
type ItemOSUser ¶
type ItemOSUser struct { // Login Login string `json:"login"` // Password Password string `json:"password"` }
Main information about OS User
type ItemSnapshot ¶
type ItemSnapshot struct { // GUID GUID string `json:"guid"` // Label Label string `json:"label"` // Timestamp Timestamp uint64 `json:"timestamp"` // Valid or not Valid bool `json:"valid"` }
Main information about Snapshot
type ListBasicServices ¶
type ListBasicServices struct { Data []ItemBasicService `json:"data"` EntryCount uint64 `json:"entryCount"` }
List of BasicServices
func (ListBasicServices) FilterByID ¶
func (lbs ListBasicServices) FilterByID(id uint64) ListBasicServices
FilterByID returns ListBasicServices with specified ID.
func (ListBasicServices) FilterByName ¶
func (lbs ListBasicServices) FilterByName(name string) ListBasicServices
FilterByName returns ListBasicServices with specified Name.
func (ListBasicServices) FilterByRGID ¶
func (lbs ListBasicServices) FilterByRGID(rgID uint64) ListBasicServices
FilterByRGID returns ListBasicServices with specified RGID.
func (ListBasicServices) FilterByStatus ¶
func (lbs ListBasicServices) FilterByStatus(status string) ListBasicServices
FilterByStatus returns ListBasicServices with specified Status.
func (ListBasicServices) FilterByTechStatus ¶
func (lbs ListBasicServices) FilterByTechStatus(techStatus string) ListBasicServices
FilterByTechStatus returns ListBasicServices with specified TechStatus.
func (ListBasicServices) FilterFunc ¶
func (lbs ListBasicServices) FilterFunc(predicate func(ItemBasicService) bool) ListBasicServices
FilterFunc allows filtering ListResourceGroups based on a user-specified predicate.
func (ListBasicServices) FindOne ¶
func (lbs ListBasicServices) FindOne() ItemBasicService
FindOne returns first found ItemBasicService If none was found, returns an empty struct.
func (ListBasicServices) Serialize ¶
func (lbs ListBasicServices) Serialize(params ...string) (serialization.Serialized, error)
Serialize returns JSON-serialized []byte. Used as a wrapper over json.Marshal and json.MarshalIndent functions.
In order to serialize with indent make sure to follow these guidelines:
- First argument -> prefix
- Second argument -> indent
func (ListBasicServices) SortByCreatedTime ¶
func (lbs ListBasicServices) SortByCreatedTime(inverse bool) ListBasicServices
SortByCreatedTime sorts ListBasicServices by the CreatedTime field in ascending order.
If inverse param is set to true, the order is reversed.
func (ListBasicServices) SortByDeletedTime ¶
func (lbs ListBasicServices) SortByDeletedTime(inverse bool) ListBasicServices
SortByDeletedTime sorts ListBasicServices by the DeletedTime field in ascending order.
If inverse param is set to true, the order is reversed.
func (ListBasicServices) SortByUpdatedTime ¶
func (lbs ListBasicServices) SortByUpdatedTime(inverse bool) ListBasicServices
SortByUpdatedTime sorts ListBasicServices by the UpdatedTime field in ascending order.
If inverse param is set to true, the order is reversed.
type ListDeletedRequest ¶ added in v1.5.0
type ListDeletedRequest struct { // ID of the account to query for BasicService instances // Required: false AccountID uint64 `url:"accountId,omitempty" json:"accountId,omitempty"` // ID of the resource group to query for BasicService instances // Required: false RGID uint64 `url:"rgId,omitempty" json:"rgId,omitempty"` // Page number // Required: false Page uint64 `url:"page,omitempty" json:"page,omitempty"` // Page size // Required: false Size uint64 `url:"size,omitempty" json:"size,omitempty"` }
Request struct for get list of deleted BasicService instances
type ListRequest ¶
type ListRequest struct { // Find by ID // Required: false ByID uint64 `url:"by_id,omitempty" json:"by_id,omitempty"` // Find by name // Required: false Name string `url:"name,omitempty" json:"name,omitempty"` // ID of the account to query for BasicService instances // Required: false AccountID uint64 `url:"accountId,omitempty" json:"accountId,omitempty"` // Find by resource group name // Required: false RGName string `url:"rgName,omitempty" json:"rgName,omitempty"` // ID of the resource group to query for BasicService instances // Required: false RGID uint64 `url:"rgId,omitempty" json:"rgId,omitempty"` // Find by tech status // Required: false TechStatus string `url:"techStatus,omitempty" json:"techStatus,omitempty"` // Find by status // Required: false Status string `url:"status,omitempty" json:"status,omitempty"` // Find by account name // Required: false AccountName string `url:"accountName,omitempty" json:"accountName,omitempty"` // Page number // Required: false Page uint64 `url:"page,omitempty" json:"page,omitempty"` // Page size // Required: false Size uint64 `url:"size,omitempty" json:"size,omitempty"` }
Request struct for get list BasicService instances
type RecordBasicService ¶
type RecordBasicService struct { // Account ID AccountID uint64 `json:"accountId"` // Account name AccountName string `json:"accountName"` // Base domain BaseDomain string `json:"baseDomain"` // List Computes Computes ListComputes `json:"computes"` // Number of cores CPUTotal uint64 `json:"cpuTotal"` // Created by CreatedBy string `json:"createdBy"` // Created time CreatedTime uint64 `json:"createdTime"` // Deleted by DeletedBy string `json:"deletedBy"` // Deleted time DeletedTime uint64 `json:"deletedTime"` // Amount of disk space used, GB DiskTotal uint64 `json:"diskTotal"` // Grid ID GID uint64 `json:"gid"` // List of Service Compute Groups Groups ListGroups `json:"groups"` // GUID GUID uint64 `json:"guid"` // ID ID uint64 `json:"id"` // Milestones Milestones uint64 `json:"milestones"` // Name Name string `json:"name"` // Parent service ID ParentSrvID uint64 `json:"parentSrvId"` // Parent service type ParentSrvType string `json:"parentSrvType"` // Total amount of RAM, MB RAMTotal uint64 `json:"ramTotal"` // Resource group ID RGID uint64 `json:"rgId"` // Resource group name RGName string `json:"rgName"` // List of snapshots Snapshots ListSnapshots `json:"snapshots"` // SSH key for connection SSHKey string `json:"sshKey"` // Username for SSH connection SSHUser string `json:"sshUser"` // status Status string `json:"status"` // TechStatus TechStatus string `json:"techStatus"` // Updated by UpdatedBy string `json:"updatedBy"` // Updated time UpdatedTime uint64 `json:"updatedTime"` // Whether user controlled UserManaged bool `json:"userManaged"` }
Detailed info about BasicService
type RecordGroup ¶
type RecordGroup struct { // Account ID AccountID uint64 `json:"accountId"` // Account Name AccountName string `json:"accountName"` // List of Computes Computes ListGroupComputes `json:"computes"` // Consistency or not Consistency bool `json:"consistency"` // Number of CPU CPU uint64 `json:"cpu"` // Created by CreatedBy string `json:"createdBy"` // Created time CreatedTime uint64 `json:"createdTime"` // Deleted by DeletedBy string `json:"deletedBy"` // Deleted time DeletedTime uint64 `json:"deletedTime"` // Amount of disk Disk uint64 `json:"disk"` // Driver Driver string `json:"driver"` // list of External Network IDs ExtNets []uint64 `json:"extnets"` // Grid ID GID uint64 `json:"gid"` // GUID GUID uint64 `json:"guid"` // ID ID uint64 `json:"id"` // Image ID ImageID uint64 `json:"imageId"` // Milestones Milestones uint64 `json:"milestones"` // Name Name string `json:"name"` // List of Parent IDs Parents []uint64 `json:"parents"` // Pool name PoolName string `json:"poolName"` // Number of RAM, MB RAM uint64 `json:"ram"` // Resource group ID RGID uint64 `json:"rgId"` // Resource group name RGName string `json:"rgName"` // Role Role string `json:"role"` // SEPID SEPID uint64 `json:"sepId"` // Sequence number SeqNo uint64 `json:"seqNo"` // Service ID ServiceID uint64 `json:"serviceId"` // Status Status string `json:"status"` // TechStatus TechStatus string `json:"techStatus"` // Timeout Start TimeoutStart uint64 `json:"timeoutStart"` // Updated by UpdatedBy string `json:"updatedBy"` // Updated time UpdatedTime uint64 `json:"updatedTime"` // List of VINS IDs VINSes []uint64 `json:"vinses"` }
Main information about Group
type RestoreRequest ¶
type RestoreRequest struct { // ID of the BasicService to be restored // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` }
Request struct for restores BasicService instance
type SnapshotCreateRequest ¶
type SnapshotCreateRequest struct { // ID of the Basic Service // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // Label of the snapshot // Required: true Label string `url:"label" json:"label" validate:"required"` }
Request struct for create snapshot
type SnapshotDeleteRequest ¶
type SnapshotDeleteRequest struct { // ID of the Basic Service // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // Label of the snapshot // Required: true Label string `url:"label" json:"label" validate:"required"` }
Request struct for delete snapshot
type SnapshotListRequest ¶
type SnapshotListRequest struct { // ID of the Basic Service // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` }
Request struct for get list existing snapshots
type SnapshotRollbackRequest ¶
type SnapshotRollbackRequest struct { // ID of the Basic Service // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` // Label of the snapshot // Required: true Label string `url:"label" json:"label" validate:"required"` }
Request struct for rollback snapshot
type StartRequest ¶
type StartRequest struct { // ID of the service to start // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` }
Request struct for start service
type StopRequest ¶
type StopRequest struct { // ID of the service to stop // Required: true ServiceID uint64 `url:"serviceId" json:"serviceId" validate:"required"` }
Request struct for stop service
Source Files
¶
- bservice.go
- create.go
- delete.go
- disable.go
- enable.go
- filter.go
- get.go
- group_add.go
- group_compute_remove.go
- group_get.go
- group_parent_add.go
- group_parent_remove.go
- group_remove.go
- group_resize.go
- group_start.go
- group_stop.go
- group_update.go
- group_update_extnet.go
- group_update_vins.go
- list.go
- list_deleted.go
- models.go
- restore.go
- serialize.go
- snapshot_create.go
- snapshot_delete.go
- snapshot_list.go
- snapshot_rollback.go
- sorting.go
- start.go
- stop.go