This commit is contained in:
stSolo
2023-03-01 19:05:53 +03:00
parent de12bc2acc
commit 42800ac4fe
573 changed files with 2077 additions and 1844 deletions

View File

@@ -11,11 +11,11 @@ import (
type ComputeAddRequest struct {
// ID of the Floating IP group to add compute instance to
// Required: true
FLIPGroupID uint64 `url:"flipgroupId"`
FLIPGroupID uint64 `url:"flipgroupId" json:"flipgroupId"`
// ID of the compute instance to add to this group
// Required: true
ComputeID uint64 `url:"computeId"`
ComputeID uint64 `url:"computeId" json:"computeId"`
}
func (frq ComputeAddRequest) validate() error {

View File

@@ -11,11 +11,11 @@ import (
type ComputeRemoveRequest struct {
// ID of the Floating IP group to remove compute instance from
// Required: true
FLIPGroupID uint64 `url:"flipgroupId"`
FLIPGroupID uint64 `url:"flipgroupId" json:"flipgroupId"`
// ID of the compute instance to remove
// Required: true
ComputeID uint64 `url:"computeId"`
ComputeID uint64 `url:"computeId" json:"computeId"`
}
func (frq ComputeRemoveRequest) validate() error {

View File

@@ -13,36 +13,36 @@ import (
type CreateRequest struct {
// Account ID
// Required: true
AccountID uint64 `url:"accountId"`
AccountID uint64 `url:"accountId" json:"accountId"`
// FLIPGroup name
// Required: true
Name string `url:"name"`
Name string `url:"name" json:"name"`
// Network type
// Should be one of:
// - EXTNET
// - VINS
// Required: true
NetType string `url:"netType"`
NetType string `url:"netType" json:"netType"`
// ID of external network or VINS
// Required: true
NetID uint64 `url:"netId"`
NetID uint64 `url:"netId" json:"netId"`
// Type of client
// - 'compute'
// - 'vins' (will be later)
// Required: true
ClientType string `url:"clientType"`
ClientType string `url:"clientType" json:"clientType"`
// IP address to associate with this group. If empty, the platform will autoselect IP address
// Required: false
IP string `url:"ip,omitempty"`
IP string `url:"ip,omitempty" json:"ip,omitempty"`
// Text description of this FLIPGorup instance
// Required: false
Description string `url:"desc,omitempty"`
Description string `url:"desc,omitempty" json:"desc,omitempty"`
}
func (frq CreateRequest) validate() error {

View File

@@ -11,7 +11,7 @@ import (
type DeleteRequest struct {
// FLIPGroup ID
// Required: true
FLIPGroupID uint64 `url:"flipgroupId"`
FLIPGroupID uint64 `url:"flipgroupId" json:"flipgroupId"`
}
func (frq DeleteRequest) validate() error {

View File

@@ -11,15 +11,15 @@ import (
type EditRequest struct {
// FLIPGroup ID
// Required: true
FLIPGroupID uint64 `url:"flipgroupId"`
FLIPGroupID uint64 `url:"flipgroupId" json:"flipgroupId"`
// FLIPGroup name
// Required: true
Name string `url:"name,omitempty"`
Name string `url:"name,omitempty" json:"name,omitempty"`
// FLIPGroup description
// Required: true
Description string `url:"desc,omitempty"`
Description string `url:"desc,omitempty" json:"desc,omitempty"`
}
func (frq EditRequest) validate() error {

View File

@@ -11,7 +11,7 @@ import (
type GetRequest struct {
// FLIPGroup ID
// Required: true
FLIPGroupID uint64 `url:"flipgroupId"`
FLIPGroupID uint64 `url:"flipgroupId" json:"flipgroupId"`
}
func (frq GetRequest) validate() error {

View File

@@ -10,11 +10,11 @@ import (
type ListRequest struct {
// Page number
// Required: false
Page uint64 `url:"page,omitempty"`
Page uint64 `url:"page,omitempty" json:"page,omitempty"`
// Page size
// Required: false
Size uint64 `url:"size,omitempty"`
Size uint64 `url:"size,omitempty" json:"size,omitempty"`
}
// List gets list FLIPGroup managed cluster instances available to the current user