Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4.19 support changes #76

Merged
merged 1 commit into from
Feb 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 20 additions & 3 deletions cloudstack/AddressService.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ type AddressServiceIface interface {
AssociateIpAddress(p *AssociateIpAddressParams) (*AssociateIpAddressResponse, error)
NewAssociateIpAddressParams() *AssociateIpAddressParams
DisassociateIpAddress(p *DisassociateIpAddressParams) (*DisassociateIpAddressResponse, error)
NewDisassociateIpAddressParams(id string) *DisassociateIpAddressParams
NewDisassociateIpAddressParams() *DisassociateIpAddressParams
ListPublicIpAddresses(p *ListPublicIpAddressesParams) (*ListPublicIpAddressesResponse, error)
NewListPublicIpAddressesParams() *ListPublicIpAddressesParams
GetPublicIpAddressByID(id string, opts ...OptionFunc) (*PublicIpAddress, int, error)
Expand Down Expand Up @@ -331,6 +331,9 @@ func (p *DisassociateIpAddressParams) toURLValues() url.Values {
if v, found := p.p["id"]; found {
u.Set("id", v.(string))
}
if v, found := p.p["ipaddress"]; found {
u.Set("ipaddress", v.(string))
}
return u
}

Expand All @@ -349,12 +352,26 @@ func (p *DisassociateIpAddressParams) GetId() (string, bool) {
return value, ok
}

func (p *DisassociateIpAddressParams) SetIpaddress(v string) {
if p.p == nil {
p.p = make(map[string]interface{})
}
p.p["ipaddress"] = v
}

func (p *DisassociateIpAddressParams) GetIpaddress() (string, bool) {
if p.p == nil {
p.p = make(map[string]interface{})
}
value, ok := p.p["ipaddress"].(string)
return value, ok
}

// You should always use this function to get a new DisassociateIpAddressParams instance,
// as then you are sure you have configured all required params
func (s *AddressService) NewDisassociateIpAddressParams(id string) *DisassociateIpAddressParams {
func (s *AddressService) NewDisassociateIpAddressParams() *DisassociateIpAddressParams {
p := &DisassociateIpAddressParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}

Expand Down
8 changes: 4 additions & 4 deletions cloudstack/AddressService_mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions cloudstack/AffinityGroupService.go
Original file line number Diff line number Diff line change
Expand Up @@ -1026,6 +1026,7 @@ type UpdateVMAffinityGroupResponse struct {
Templatedisplaytext string `json:"templatedisplaytext"`
Templateid string `json:"templateid"`
Templatename string `json:"templatename"`
Templatetype string `json:"templatetype"`
Userdata string `json:"userdata"`
Userdatadetails string `json:"userdatadetails"`
Userdataid string `json:"userdataid"`
Expand All @@ -1034,6 +1035,8 @@ type UpdateVMAffinityGroupResponse struct {
Userid string `json:"userid"`
Username string `json:"username"`
Vgpu string `json:"vgpu"`
Vnfdetails map[string]string `json:"vnfdetails"`
Vnfnics []string `json:"vnfnics"`
Zoneid string `json:"zoneid"`
Zonename string `json:"zonename"`
}
Expand Down
92 changes: 92 additions & 0 deletions cloudstack/AutoScaleService.go
Original file line number Diff line number Diff line change
Expand Up @@ -560,6 +560,16 @@ func (p *CreateAutoScaleVmProfileParams) toURLValues() url.Values {
if v, found := p.p["userdata"]; found {
u.Set("userdata", v.(string))
}
if v, found := p.p["userdatadetails"]; found {
m := v.(map[string]string)
for i, k := range getSortedKeysFromMap(m) {
u.Set(fmt.Sprintf("userdatadetails[%d].key", i), k)
u.Set(fmt.Sprintf("userdatadetails[%d].value", i), m[k])
}
}
if v, found := p.p["userdataid"]; found {
u.Set("userdataid", v.(string))
}
if v, found := p.p["zoneid"]; found {
u.Set("zoneid", v.(string))
}
Expand Down Expand Up @@ -731,6 +741,36 @@ func (p *CreateAutoScaleVmProfileParams) GetUserdata() (string, bool) {
return value, ok
}

func (p *CreateAutoScaleVmProfileParams) SetUserdatadetails(v map[string]string) {
if p.p == nil {
p.p = make(map[string]interface{})
}
p.p["userdatadetails"] = v
}

func (p *CreateAutoScaleVmProfileParams) GetUserdatadetails() (map[string]string, bool) {
if p.p == nil {
p.p = make(map[string]interface{})
}
value, ok := p.p["userdatadetails"].(map[string]string)
return value, ok
}

func (p *CreateAutoScaleVmProfileParams) SetUserdataid(v string) {
if p.p == nil {
p.p = make(map[string]interface{})
}
p.p["userdataid"] = v
}

func (p *CreateAutoScaleVmProfileParams) GetUserdataid() (string, bool) {
if p.p == nil {
p.p = make(map[string]interface{})
}
value, ok := p.p["userdataid"].(string)
return value, ok
}

func (p *CreateAutoScaleVmProfileParams) SetZoneid(v string) {
if p.p == nil {
p.p = make(map[string]interface{})
Expand Down Expand Up @@ -808,6 +848,10 @@ type CreateAutoScaleVmProfileResponse struct {
Serviceofferingid string `json:"serviceofferingid"`
Templateid string `json:"templateid"`
Userdata string `json:"userdata"`
Userdatadetails string `json:"userdatadetails"`
Userdataid string `json:"userdataid"`
Userdataname string `json:"userdataname"`
Userdatapolicy string `json:"userdatapolicy"`
Zoneid string `json:"zoneid"`
}

Expand Down Expand Up @@ -2898,6 +2942,10 @@ type AutoScaleVmProfile struct {
Serviceofferingid string `json:"serviceofferingid"`
Templateid string `json:"templateid"`
Userdata string `json:"userdata"`
Userdatadetails string `json:"userdatadetails"`
Userdataid string `json:"userdataid"`
Userdataname string `json:"userdataname"`
Userdatapolicy string `json:"userdatapolicy"`
Zoneid string `json:"zoneid"`
}

Expand Down Expand Up @@ -3924,6 +3972,16 @@ func (p *UpdateAutoScaleVmProfileParams) toURLValues() url.Values {
if v, found := p.p["userdata"]; found {
u.Set("userdata", v.(string))
}
if v, found := p.p["userdatadetails"]; found {
m := v.(map[string]string)
for i, k := range getSortedKeysFromMap(m) {
u.Set(fmt.Sprintf("userdatadetails[%d].key", i), k)
u.Set(fmt.Sprintf("userdatadetails[%d].value", i), m[k])
}
}
if v, found := p.p["userdataid"]; found {
u.Set("userdataid", v.(string))
}
return u
}

Expand Down Expand Up @@ -4077,6 +4135,36 @@ func (p *UpdateAutoScaleVmProfileParams) GetUserdata() (string, bool) {
return value, ok
}

func (p *UpdateAutoScaleVmProfileParams) SetUserdatadetails(v map[string]string) {
if p.p == nil {
p.p = make(map[string]interface{})
}
p.p["userdatadetails"] = v
}

func (p *UpdateAutoScaleVmProfileParams) GetUserdatadetails() (map[string]string, bool) {
if p.p == nil {
p.p = make(map[string]interface{})
}
value, ok := p.p["userdatadetails"].(map[string]string)
return value, ok
}

func (p *UpdateAutoScaleVmProfileParams) SetUserdataid(v string) {
if p.p == nil {
p.p = make(map[string]interface{})
}
p.p["userdataid"] = v
}

func (p *UpdateAutoScaleVmProfileParams) GetUserdataid() (string, bool) {
if p.p == nil {
p.p = make(map[string]interface{})
}
value, ok := p.p["userdataid"].(string)
return value, ok
}

// You should always use this function to get a new UpdateAutoScaleVmProfileParams instance,
// as then you are sure you have configured all required params
func (s *AutoScaleService) NewUpdateAutoScaleVmProfileParams(id string) *UpdateAutoScaleVmProfileParams {
Expand Down Expand Up @@ -4137,5 +4225,9 @@ type UpdateAutoScaleVmProfileResponse struct {
Serviceofferingid string `json:"serviceofferingid"`
Templateid string `json:"templateid"`
Userdata string `json:"userdata"`
Userdatadetails string `json:"userdatadetails"`
Userdataid string `json:"userdataid"`
Userdataname string `json:"userdataname"`
Userdatapolicy string `json:"userdatapolicy"`
Zoneid string `json:"zoneid"`
}
1 change: 1 addition & 0 deletions cloudstack/BrocadeVCSService.go
Original file line number Diff line number Diff line change
Expand Up @@ -426,6 +426,7 @@ type BrocadeVcsDeviceNetwork struct {
Dns2 string `json:"dns2"`
Domain string `json:"domain"`
Domainid string `json:"domainid"`
Domainpath string `json:"domainpath"`
Egressdefaultpolicy bool `json:"egressdefaultpolicy"`
Externalid string `json:"externalid"`
Gateway string `json:"gateway"`
Expand Down
1 change: 1 addition & 0 deletions cloudstack/ConfigurationService.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ type Capability struct {
Cloudstackversion string `json:"cloudstackversion"`
Customdiskofferingmaxsize int64 `json:"customdiskofferingmaxsize"`
Customdiskofferingminsize int64 `json:"customdiskofferingminsize"`
Customhypervisordisplayname string `json:"customhypervisordisplayname"`
Defaultuipagesize int64 `json:"defaultuipagesize"`
Dynamicrolesenabled bool `json:"dynamicrolesenabled"`
Instancesdisksstatsretentionenabled bool `json:"instancesdisksstatsretentionenabled"`
Expand Down
54 changes: 54 additions & 0 deletions cloudstack/DiskOfferingService.go
Original file line number Diff line number Diff line change
Expand Up @@ -803,6 +803,9 @@ func (p *ListDiskOfferingsParams) toURLValues() url.Values {
if p.p == nil {
return u
}
if v, found := p.p["account"]; found {
u.Set("account", v.(string))
}
if v, found := p.p["domainid"]; found {
u.Set("domainid", v.(string))
}
Expand Down Expand Up @@ -835,9 +838,15 @@ func (p *ListDiskOfferingsParams) toURLValues() url.Values {
vv := strconv.Itoa(v.(int))
u.Set("pagesize", vv)
}
if v, found := p.p["projectid"]; found {
u.Set("projectid", v.(string))
}
if v, found := p.p["storageid"]; found {
u.Set("storageid", v.(string))
}
if v, found := p.p["storagetype"]; found {
u.Set("storagetype", v.(string))
}
if v, found := p.p["volumeid"]; found {
u.Set("volumeid", v.(string))
}
Expand All @@ -847,6 +856,21 @@ func (p *ListDiskOfferingsParams) toURLValues() url.Values {
return u
}

func (p *ListDiskOfferingsParams) SetAccount(v string) {
if p.p == nil {
p.p = make(map[string]interface{})
}
p.p["account"] = v
}

func (p *ListDiskOfferingsParams) GetAccount() (string, bool) {
if p.p == nil {
p.p = make(map[string]interface{})
}
value, ok := p.p["account"].(string)
return value, ok
}

func (p *ListDiskOfferingsParams) SetDomainid(v string) {
if p.p == nil {
p.p = make(map[string]interface{})
Expand Down Expand Up @@ -982,6 +1006,21 @@ func (p *ListDiskOfferingsParams) GetPagesize() (int, bool) {
return value, ok
}

func (p *ListDiskOfferingsParams) SetProjectid(v string) {
if p.p == nil {
p.p = make(map[string]interface{})
}
p.p["projectid"] = v
}

func (p *ListDiskOfferingsParams) GetProjectid() (string, bool) {
if p.p == nil {
p.p = make(map[string]interface{})
}
value, ok := p.p["projectid"].(string)
return value, ok
}

func (p *ListDiskOfferingsParams) SetStorageid(v string) {
if p.p == nil {
p.p = make(map[string]interface{})
Expand All @@ -997,6 +1036,21 @@ func (p *ListDiskOfferingsParams) GetStorageid() (string, bool) {
return value, ok
}

func (p *ListDiskOfferingsParams) SetStoragetype(v string) {
if p.p == nil {
p.p = make(map[string]interface{})
}
p.p["storagetype"] = v
}

func (p *ListDiskOfferingsParams) GetStoragetype() (string, bool) {
if p.p == nil {
p.p = make(map[string]interface{})
}
value, ok := p.p["storagetype"].(string)
return value, ok
}

func (p *ListDiskOfferingsParams) SetVolumeid(v string) {
if p.p == nil {
p.p = make(map[string]interface{})
Expand Down
Loading
Loading