add-new-instance-volume-type

This commit is contained in:
huyujie 2019-02-12 14:18:00 +08:00
parent be6068c837
commit b22398f53c
2 changed files with 6 additions and 6 deletions

View File

@ -572,7 +572,7 @@ type RunInstancesInput struct {
Gpu *int `json:"gpu" name:"gpu" default:"0" location:"params"`
Hostname *string `json:"hostname" name:"hostname" location:"params"`
ImageID *string `json:"image_id" name:"image_id" location:"params"` // Required
// InstanceClass's available values: 0, 1
// InstanceClass's available values: 0, 1, 2, 3, 4, 5, 6, 100, 101, 200, 201, 300, 301
InstanceClass *int `json:"instance_class" name:"instance_class" location:"params"`
InstanceName *string `json:"instance_name" name:"instance_name" location:"params"`
InstanceType *string `json:"instance_type" name:"instance_type" location:"params"`
@ -670,7 +670,7 @@ func (v *RunInstancesInput) Validate() error {
}
if v.InstanceClass != nil {
instanceClassValidValues := []string{"0", "1"}
instanceClassValidValues := []string{"0", "1", "2", "3", "4", "5", "6", "100", "101", "200", "201", "300", "301"}
instanceClassParameterValue := fmt.Sprint(*v.InstanceClass)
instanceClassIsValid := false

View File

@ -134,7 +134,7 @@ type CreateVolumesInput struct {
Count *int `json:"count" name:"count" default:"1" location:"params"`
Size *int `json:"size" name:"size" location:"params"` // Required
VolumeName *string `json:"volume_name" name:"volume_name" location:"params"`
// VolumeType's available values: 0, 1, 2, 3
// VolumeType's available values: 0, 1, 2, 3, 4, 5, 10, 100, 200
VolumeType *int `json:"volume_type" name:"volume_type" default:"0" location:"params"`
}
@ -148,7 +148,7 @@ func (v *CreateVolumesInput) Validate() error {
}
if v.VolumeType != nil {
volumeTypeValidValues := []string{"0", "1", "2", "3"}
volumeTypeValidValues := []string{"0", "1", "2", "3", "4", "5", "10", "100", "200"}
volumeTypeParameterValue := fmt.Sprint(*v.VolumeType)
volumeTypeIsValid := false
@ -262,7 +262,7 @@ type DescribeVolumesInput struct {
Tags []*string `json:"tags" name:"tags" location:"params"`
// Verbose's available values: 0, 1
Verbose *int `json:"verbose" name:"verbose" default:"0" location:"params"`
// VolumeType's available values: 0, 1, 2, 3, 5
// VolumeType's available values: 0, 1, 2, 3, 4, 5, 10, 100, 200
VolumeType *int `json:"volume_type" name:"volume_type" location:"params"`
Volumes []*string `json:"volumes" name:"volumes" location:"params"`
}
@ -290,7 +290,7 @@ func (v *DescribeVolumesInput) Validate() error {
}
if v.VolumeType != nil {
volumeTypeValidValues := []string{"0", "1", "2", "3", "5"}
volumeTypeValidValues := []string{"0", "1", "2", "3", "4", "5", "10", "100", "200"}
volumeTypeParameterValue := fmt.Sprint(*v.VolumeType)
volumeTypeIsValid := false