diff --git a/builder/cloudstack/artifact_test.go b/builder/cloudstack/artifact_test.go deleted file mode 100644 index 25d8863a2..000000000 --- a/builder/cloudstack/artifact_test.go +++ /dev/null @@ -1,73 +0,0 @@ -package cloudstack - -import ( - "testing" - - packersdk "github.com/hashicorp/packer-plugin-sdk/packer" - "github.com/xanzy/go-cloudstack/cloudstack" -) - -const templateID = "286dd44a-ec6b-4789-b192-804f08f04b4c" - -func TestArtifact_Impl(t *testing.T) { - var raw interface{} = &Artifact{} - - if _, ok := raw.(packersdk.Artifact); !ok { - t.Fatalf("Artifact does not implement packersdk.Artifact") - } -} - -func TestArtifactId(t *testing.T) { - a := &Artifact{ - client: nil, - config: nil, - template: &cloudstack.CreateTemplateResponse{ - Id: "286dd44a-ec6b-4789-b192-804f08f04b4c", - }, - } - - if a.Id() != templateID { - t.Fatalf("artifact ID should match: %s", templateID) - } -} - -func TestArtifactString(t *testing.T) { - a := &Artifact{ - client: nil, - config: nil, - template: &cloudstack.CreateTemplateResponse{ - Name: "packer-foobar", - }, - } - expected := "A template was created: packer-foobar" - - if a.String() != expected { - t.Fatalf("artifact string should match: %s", expected) - } -} - -func TestArtifactState_StateData(t *testing.T) { - expectedData := "this is the data" - artifact := &Artifact{ - StateData: map[string]interface{}{"state_data": expectedData}, - } - - // Valid state - result := artifact.State("state_data") - if result != expectedData { - t.Fatalf("Bad: State data was %s instead of %s", result, expectedData) - } - - // Invalid state - result = artifact.State("invalid_key") - if result != nil { - t.Fatalf("Bad: State should be nil for invalid state data name") - } - - // Nil StateData should not fail and should return nil - artifact = &Artifact{} - result = artifact.State("key") - if result != nil { - t.Fatalf("Bad: State should be nil for nil StateData") - } -} diff --git a/builder/cloudstack/builder_test.go b/builder/cloudstack/builder_test.go deleted file mode 100644 index b9729bc6e..000000000 --- a/builder/cloudstack/builder_test.go +++ /dev/null @@ -1,56 +0,0 @@ -package cloudstack - -import ( - "testing" - - packersdk "github.com/hashicorp/packer-plugin-sdk/packer" -) - -func TestBuilder_Impl(t *testing.T) { - var raw interface{} = &Builder{} - - if _, ok := raw.(packersdk.Builder); !ok { - t.Fatalf("Builder does not implement packersdk.Builder") - } -} - -func TestBuilder_Prepare(t *testing.T) { - cases := map[string]struct { - Config map[string]interface{} - Err bool - }{ - "good": { - Config: map[string]interface{}{ - "api_url": "https://cloudstack.com/client/api", - "api_key": "some-api-key", - "secret_key": "some-secret-key", - "cidr_list": []interface{}{"0.0.0.0/0"}, - "disk_size": "20", - "network": "c5ed8a14-3f21-4fa9-bd74-bb887fc0ed0d", - "service_offering": "a29c52b1-a83d-4123-a57d-4548befa47a0", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - "ssh_username": "ubuntu", - "template_os": "52d54d24-cef1-480b-b963-527703aa4ff9", - "zone": "a3b594d9-25e9-47c1-9c03-7a5fc61e3f43", - }, - Err: false, - }, - "bad": { - Err: true, - }, - } - - for desc, tc := range cases { - _, _, errs := (&Builder{}).Prepare(tc.Config) - - if tc.Err { - if errs == nil { - t.Fatalf("%s prepare should err", desc) - } - } else { - if errs != nil { - t.Fatalf("%s prepare should not fail: %s", desc, errs) - } - } - } -} diff --git a/builder/cloudstack/config_test.go b/builder/cloudstack/config_test.go deleted file mode 100644 index bff6c55e0..000000000 --- a/builder/cloudstack/config_test.go +++ /dev/null @@ -1,168 +0,0 @@ -package cloudstack - -import "testing" - -func TestNewConfig(t *testing.T) { - cases := map[string]struct { - Config map[string]interface{} - Nullify string - Err bool - }{ - "no_api_url": { - Config: map[string]interface{}{ - "disk_size": "20", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - }, - Nullify: "api_url", - Err: true, - }, - "no_api_key": { - Config: map[string]interface{}{ - "disk_size": "20", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - }, - Nullify: "api_key", - Err: true, - }, - "no_secret_key": { - Config: map[string]interface{}{ - "disk_size": "20", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - }, - Nullify: "secret_key", - Err: true, - }, - "no_cidr_list": { - Config: map[string]interface{}{ - "disk_size": "20", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - }, - Nullify: "cidr_list", - Err: false, - }, - "no_cidr_list_with_use_local_ip_address": { - Config: map[string]interface{}{ - "disk_size": "20", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - "use_local_ip_address": true, - }, - Nullify: "cidr_list", - Err: false, - }, - "no_network": { - Config: map[string]interface{}{ - "disk_size": "20", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - }, - Nullify: "network", - Err: true, - }, - "no_service_offering": { - Config: map[string]interface{}{ - "disk_size": "20", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - }, - Nullify: "service_offering", - Err: true, - }, - "no_template_os": { - Config: map[string]interface{}{ - "disk_size": "20", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - }, - Nullify: "template_os", - Err: true, - }, - "no_zone": { - Config: map[string]interface{}{ - "disk_size": "20", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - }, - Nullify: "zone", - Err: true, - }, - "no_source": { - Err: true, - }, - "both_sources": { - Config: map[string]interface{}{ - "disk_offering": "f043d193-242f-4941-a847-29408b998711", - "disk_size": "20", - "hypervisor": "KVM", - "source_iso": "fbd904dc-f46c-42e7-a467-f27480c667d5", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - }, - Err: true, - }, - "source_iso_good": { - Config: map[string]interface{}{ - "disk_offering": "f043d193-242f-4941-a847-29408b998711", - "hypervisor": "KVM", - "source_iso": "fbd904dc-f46c-42e7-a467-f27480c667d5", - }, - Err: false, - }, - "source_iso_without_disk_offering": { - Config: map[string]interface{}{ - "hypervisor": "KVM", - "source_iso": "fbd904dc-f46c-42e7-a467-f27480c667d5", - }, - Err: true, - }, - "source_iso_without_hypervisor": { - Config: map[string]interface{}{ - "disk_offering": "f043d193-242f-4941-a847-29408b998711", - "source_iso": "fbd904dc-f46c-42e7-a467-f27480c667d5", - }, - Err: true, - }, - "source_template_good": { - Config: map[string]interface{}{ - "disk_size": "20", - "source_template": "d31e6af5-94a8-4756-abf3-6493c38db7e5", - }, - Err: false, - }, - } - - for desc, tc := range cases { - raw := testConfig(tc.Config) - - if tc.Nullify != "" { - raw[tc.Nullify] = nil - } - - var c Config - errs := c.Prepare(raw) - - if tc.Err { - if errs == nil { - t.Fatalf("%q should error", desc) - } - } else { - if errs != nil { - t.Fatalf("%q should not error: %s", desc, errs) - } - } - } -} - -func testConfig(config map[string]interface{}) map[string]interface{} { - raw := map[string]interface{}{ - "api_url": "https://cloudstack.com/client/api", - "api_key": "some-api-key", - "secret_key": "some-secret-key", - "ssh_username": "root", - "cidr_list": []interface{}{"0.0.0.0/0"}, - "network": "c5ed8a14-3f21-4fa9-bd74-bb887fc0ed0d", - "service_offering": "a29c52b1-a83d-4123-a57d-4548befa47a0", - "template_os": "52d54d24-cef1-480b-b963-527703aa4ff9", - "zone": "a3b594d9-25e9-47c1-9c03-7a5fc61e3f43", - } - - for k, v := range config { - raw[k] = v - } - - return raw -} diff --git a/builder/cloudstack/version/version.go b/builder/cloudstack/version/version.go deleted file mode 100644 index 831976bc1..000000000 --- a/builder/cloudstack/version/version.go +++ /dev/null @@ -1,13 +0,0 @@ -package version - -import ( - "github.com/hashicorp/packer-plugin-sdk/version" - packerVersion "github.com/hashicorp/packer/version" -) - -var CloudstackPluginVersion *version.PluginVersion - -func init() { - CloudstackPluginVersion = version.InitializePluginVersion( - packerVersion.Version, packerVersion.VersionPrerelease) -} diff --git a/command/plugin.go b/command/plugin.go index e7725da0b..cec9bb873 100644 --- a/command/plugin.go +++ b/command/plugin.go @@ -16,7 +16,6 @@ import ( azurearmbuilder "github.com/hashicorp/packer/builder/azure/arm" azurechrootbuilder "github.com/hashicorp/packer/builder/azure/chroot" azuredtlbuilder "github.com/hashicorp/packer/builder/azure/dtl" - cloudstackbuilder "github.com/hashicorp/packer/builder/cloudstack" digitaloceanbuilder "github.com/hashicorp/packer/builder/digitalocean" filebuilder "github.com/hashicorp/packer/builder/file" hcloudbuilder "github.com/hashicorp/packer/builder/hcloud" @@ -70,7 +69,6 @@ var Builders = map[string]packersdk.Builder{ "azure-arm": new(azurearmbuilder.Builder), "azure-chroot": new(azurechrootbuilder.Builder), "azure-dtl": new(azuredtlbuilder.Builder), - "cloudstack": new(cloudstackbuilder.Builder), "digitalocean": new(digitaloceanbuilder.Builder), "file": new(filebuilder.Builder), "hcloud": new(hcloudbuilder.Builder), diff --git a/command/vendored_plugins.go b/command/vendored_plugins.go index 4201a1319..7cf2ad3b1 100644 --- a/command/vendored_plugins.go +++ b/command/vendored_plugins.go @@ -21,6 +21,7 @@ import ( ansiblelocalprovisioner "github.com/hashicorp/packer-plugin-ansible/provisioner/ansible-local" chefclientprovisioner "github.com/hashicorp/packer-plugin-chef/provisioner/chef-client" chefsoloprovisioner "github.com/hashicorp/packer-plugin-chef/provisioner/chef-solo" + cloudstackbuilder "github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack" dockerbuilder "github.com/hashicorp/packer-plugin-docker/builder/docker" dockerimportpostprocessor "github.com/hashicorp/packer-plugin-docker/post-processor/docker-import" dockerpushpostprocessor "github.com/hashicorp/packer-plugin-docker/post-processor/docker-push" @@ -70,6 +71,7 @@ var VendoredBuilders = map[string]packersdk.Builder{ "amazon-ebssurrogate": new(amazonebssurrogatebuilder.Builder), "amazon-ebsvolume": new(amazonebsvolumebuilder.Builder), "amazon-instance": new(amazoninstancebuilder.Builder), + "cloudstack": new(cloudstackbuilder.Builder), "docker": new(dockerbuilder.Builder), "googlecompute": new(googlecomputebuilder.Builder), "ncloud": new(ncloudbuilder.Builder), diff --git a/go.mod b/go.mod index b5059cd3c..9a83dd963 100644 --- a/go.mod +++ b/go.mod @@ -41,6 +41,7 @@ require ( github.com/hashicorp/packer-plugin-amazon v0.0.1 github.com/hashicorp/packer-plugin-ansible v0.0.2 github.com/hashicorp/packer-plugin-chef v0.0.1 + github.com/hashicorp/packer-plugin-cloudstack v0.0.1 github.com/hashicorp/packer-plugin-docker v0.0.7 github.com/hashicorp/packer-plugin-googlecompute v0.0.1 github.com/hashicorp/packer-plugin-ncloud v0.0.2 @@ -80,7 +81,6 @@ require ( github.com/ucloud/ucloud-sdk-go v0.16.3 github.com/ufilesdk-dev/ufile-gosdk v0.0.0-20190830075812-b4dbc4ef43a6 github.com/ulikunitz/xz v0.5.6 - github.com/xanzy/go-cloudstack v0.0.0-20190526095453-42f262b63ed0 github.com/yandex-cloud/go-genproto v0.0.0-20200915125933-33de72a328bd github.com/yandex-cloud/go-sdk v0.0.0-20200921111412-ef15ded2014c github.com/zclconf/go-cty v1.8.1 diff --git a/go.sum b/go.sum index eca69cfb7..e7aec69b6 100644 --- a/go.sum +++ b/go.sum @@ -470,6 +470,8 @@ github.com/hashicorp/packer-plugin-ansible v0.0.2 h1:nvBtCedXhUI5T6Up5+bmhlY7rmk github.com/hashicorp/packer-plugin-ansible v0.0.2/go.mod h1:ocXB4KTU+I+DBRGfMP4XE7dPlURaUnb7NJvyddZ6bh0= github.com/hashicorp/packer-plugin-chef v0.0.1 h1:1zQwnnvftwg9PJyWjMfHfDyzfWDdb0eo9IX8fX6kd+Y= github.com/hashicorp/packer-plugin-chef v0.0.1/go.mod h1:4iSyWfvrb4QwUDZqJ3iCb+kIsnDwOTL1yTEDXBtk3Ew= +github.com/hashicorp/packer-plugin-cloudstack v0.0.1 h1:BF9nXRlA0xQV5W/+CoLjWn0aLO60gTbsxnLi/o37ktc= +github.com/hashicorp/packer-plugin-cloudstack v0.0.1/go.mod h1:fx13TY2szz6cm2e99xzU3gQzKdGVwysxY2TyKr0r8MQ= github.com/hashicorp/packer-plugin-docker v0.0.7 h1:hMTrH7vrkFIjphtbbtpuzffTzSjMNgxayo2DPLz9y+c= github.com/hashicorp/packer-plugin-docker v0.0.7/go.mod h1:IpeKlwOSy2kdgQcysqd3gCsoqjME9jtmpFoKxn7RRNI= github.com/hashicorp/packer-plugin-googlecompute v0.0.1 h1:Shjio88MraB+ocj0VI5+M65r4UBKbYI4eCqLNyPXKEo= @@ -767,8 +769,9 @@ github.com/vmware/govmomi v0.23.1/go.mod h1:Y+Wq4lst78L85Ge/F8+ORXIWiKYqaro1vhAu github.com/vmware/govmomi v0.24.1 h1:ecVvrxF28/5g738gLTiYgc62fpGfIPRKheQ1Dj1p35w= github.com/vmware/govmomi v0.24.1/go.mod h1:Y+Wq4lst78L85Ge/F8+ORXIWiKYqaro1vhAulACy9Lc= github.com/vmware/vmw-guestinfo v0.0.0-20170707015358-25eff159a728/go.mod h1:x9oS4Wk2s2u4tS29nEaDLdzvuHdB19CvSGJjPgkZJNk= -github.com/xanzy/go-cloudstack v0.0.0-20190526095453-42f262b63ed0 h1:NJrcIkdzq0C3I8ypAZwFE9RHtGbfp+mJvqIcoFATZuk= github.com/xanzy/go-cloudstack v0.0.0-20190526095453-42f262b63ed0/go.mod h1:sBh287mCRwCz6zyXHMmw7sSZGPohVpnx+o+OY4M+i3A= +github.com/xanzy/go-cloudstack v2.4.1+incompatible h1:Oc4xa2+I94h1g/QJ+nHoq597nJz2KXzxuQx/weOx0AU= +github.com/xanzy/go-cloudstack v2.4.1+incompatible/go.mod h1:s3eL3z5pNXF5FVybcT+LIVdId8pYn709yv6v5mrkrQE= github.com/yandex-cloud/go-genproto v0.0.0-20200915125933-33de72a328bd h1:o4pvS7D4OErKOM6y+/q6IfOa65OaentKbEDh1ABirE8= github.com/yandex-cloud/go-genproto v0.0.0-20200915125933-33de72a328bd/go.mod h1:HEUYX/p8966tMUHHT+TsS0hF/Ca/NYwqprC5WXSDMfE= github.com/yandex-cloud/go-sdk v0.0.0-20200921111412-ef15ded2014c h1:LJrgyICodRAgtBvOO2eCbhDDIoaJgeLa1tGQecqW9ac= diff --git a/vendor/github.com/hashicorp/packer-plugin-cloudstack/LICENSE b/vendor/github.com/hashicorp/packer-plugin-cloudstack/LICENSE new file mode 100644 index 000000000..a612ad981 --- /dev/null +++ b/vendor/github.com/hashicorp/packer-plugin-cloudstack/LICENSE @@ -0,0 +1,373 @@ +Mozilla Public License Version 2.0 +================================== + +1. Definitions +-------------- + +1.1. "Contributor" + means each individual or legal entity that creates, contributes to + the creation of, or owns Covered Software. + +1.2. "Contributor Version" + means the combination of the Contributions of others (if any) used + by a Contributor and that particular Contributor's Contribution. + +1.3. "Contribution" + means Covered Software of a particular Contributor. + +1.4. "Covered Software" + means Source Code Form to which the initial Contributor has attached + the notice in Exhibit A, the Executable Form of such Source Code + Form, and Modifications of such Source Code Form, in each case + including portions thereof. + +1.5. "Incompatible With Secondary Licenses" + means + + (a) that the initial Contributor has attached the notice described + in Exhibit B to the Covered Software; or + + (b) that the Covered Software was made available under the terms of + version 1.1 or earlier of the License, but not also under the + terms of a Secondary License. + +1.6. "Executable Form" + means any form of the work other than Source Code Form. + +1.7. "Larger Work" + means a work that combines Covered Software with other material, in + a separate file or files, that is not Covered Software. + +1.8. "License" + means this document. + +1.9. "Licensable" + means having the right to grant, to the maximum extent possible, + whether at the time of the initial grant or subsequently, any and + all of the rights conveyed by this License. + +1.10. "Modifications" + means any of the following: + + (a) any file in Source Code Form that results from an addition to, + deletion from, or modification of the contents of Covered + Software; or + + (b) any new file in Source Code Form that contains any Covered + Software. + +1.11. "Patent Claims" of a Contributor + means any patent claim(s), including without limitation, method, + process, and apparatus claims, in any patent Licensable by such + Contributor that would be infringed, but for the grant of the + License, by the making, using, selling, offering for sale, having + made, import, or transfer of either its Contributions or its + Contributor Version. + +1.12. "Secondary License" + means either the GNU General Public License, Version 2.0, the GNU + Lesser General Public License, Version 2.1, the GNU Affero General + Public License, Version 3.0, or any later versions of those + licenses. + +1.13. "Source Code Form" + means the form of the work preferred for making modifications. + +1.14. "You" (or "Your") + means an individual or a legal entity exercising rights under this + License. For legal entities, "You" includes any entity that + controls, is controlled by, or is under common control with You. For + purposes of this definition, "control" means (a) the power, direct + or indirect, to cause the direction or management of such entity, + whether by contract or otherwise, or (b) ownership of more than + fifty percent (50%) of the outstanding shares or beneficial + ownership of such entity. + +2. License Grants and Conditions +-------------------------------- + +2.1. Grants + +Each Contributor hereby grants You a world-wide, royalty-free, +non-exclusive license: + +(a) under intellectual property rights (other than patent or trademark) + Licensable by such Contributor to use, reproduce, make available, + modify, display, perform, distribute, and otherwise exploit its + Contributions, either on an unmodified basis, with Modifications, or + as part of a Larger Work; and + +(b) under Patent Claims of such Contributor to make, use, sell, offer + for sale, have made, import, and otherwise transfer either its + Contributions or its Contributor Version. + +2.2. Effective Date + +The licenses granted in Section 2.1 with respect to any Contribution +become effective for each Contribution on the date the Contributor first +distributes such Contribution. + +2.3. Limitations on Grant Scope + +The licenses granted in this Section 2 are the only rights granted under +this License. No additional rights or licenses will be implied from the +distribution or licensing of Covered Software under this License. +Notwithstanding Section 2.1(b) above, no patent license is granted by a +Contributor: + +(a) for any code that a Contributor has removed from Covered Software; + or + +(b) for infringements caused by: (i) Your and any other third party's + modifications of Covered Software, or (ii) the combination of its + Contributions with other software (except as part of its Contributor + Version); or + +(c) under Patent Claims infringed by Covered Software in the absence of + its Contributions. + +This License does not grant any rights in the trademarks, service marks, +or logos of any Contributor (except as may be necessary to comply with +the notice requirements in Section 3.4). + +2.4. Subsequent Licenses + +No Contributor makes additional grants as a result of Your choice to +distribute the Covered Software under a subsequent version of this +License (see Section 10.2) or under the terms of a Secondary License (if +permitted under the terms of Section 3.3). + +2.5. Representation + +Each Contributor represents that the Contributor believes its +Contributions are its original creation(s) or it has sufficient rights +to grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use + +This License is not intended to limit any rights You have under +applicable copyright doctrines of fair use, fair dealing, or other +equivalents. + +2.7. Conditions + +Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted +in Section 2.1. + +3. Responsibilities +------------------- + +3.1. Distribution of Source Form + +All distribution of Covered Software in Source Code Form, including any +Modifications that You create or to which You contribute, must be under +the terms of this License. You must inform recipients that the Source +Code Form of the Covered Software is governed by the terms of this +License, and how they can obtain a copy of this License. You may not +attempt to alter or restrict the recipients' rights in the Source Code +Form. + +3.2. Distribution of Executable Form + +If You distribute Covered Software in Executable Form then: + +(a) such Covered Software must also be made available in Source Code + Form, as described in Section 3.1, and You must inform recipients of + the Executable Form how they can obtain a copy of such Source Code + Form by reasonable means in a timely manner, at a charge no more + than the cost of distribution to the recipient; and + +(b) You may distribute such Executable Form under the terms of this + License, or sublicense it under different terms, provided that the + license for the Executable Form does not attempt to limit or alter + the recipients' rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work + +You may create and distribute a Larger Work under terms of Your choice, +provided that You also comply with the requirements of this License for +the Covered Software. If the Larger Work is a combination of Covered +Software with a work governed by one or more Secondary Licenses, and the +Covered Software is not Incompatible With Secondary Licenses, this +License permits You to additionally distribute such Covered Software +under the terms of such Secondary License(s), so that the recipient of +the Larger Work may, at their option, further distribute the Covered +Software under the terms of either this License or such Secondary +License(s). + +3.4. Notices + +You may not remove or alter the substance of any license notices +(including copyright notices, patent notices, disclaimers of warranty, +or limitations of liability) contained within the Source Code Form of +the Covered Software, except that You may alter any license notices to +the extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms + +You may choose to offer, and to charge a fee for, warranty, support, +indemnity or liability obligations to one or more recipients of Covered +Software. However, You may do so only on Your own behalf, and not on +behalf of any Contributor. You must make it absolutely clear that any +such warranty, support, indemnity, or liability obligation is offered by +You alone, and You hereby agree to indemnify every Contributor for any +liability incurred by such Contributor as a result of warranty, support, +indemnity or liability terms You offer. You may include additional +disclaimers of warranty and limitations of liability specific to any +jurisdiction. + +4. Inability to Comply Due to Statute or Regulation +--------------------------------------------------- + +If it is impossible for You to comply with any of the terms of this +License with respect to some or all of the Covered Software due to +statute, judicial order, or regulation then You must: (a) comply with +the terms of this License to the maximum extent possible; and (b) +describe the limitations and the code they affect. Such description must +be placed in a text file included with all distributions of the Covered +Software under this License. Except to the extent prohibited by statute +or regulation, such description must be sufficiently detailed for a +recipient of ordinary skill to be able to understand it. + +5. Termination +-------------- + +5.1. The rights granted under this License will terminate automatically +if You fail to comply with any of its terms. However, if You become +compliant, then the rights granted under this License from a particular +Contributor are reinstated (a) provisionally, unless and until such +Contributor explicitly and finally terminates Your grants, and (b) on an +ongoing basis, if such Contributor fails to notify You of the +non-compliance by some reasonable means prior to 60 days after You have +come back into compliance. Moreover, Your grants from a particular +Contributor are reinstated on an ongoing basis if such Contributor +notifies You of the non-compliance by some reasonable means, this is the +first time You have received notice of non-compliance with this License +from such Contributor, and You become compliant prior to 30 days after +Your receipt of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent +infringement claim (excluding declaratory judgment actions, +counter-claims, and cross-claims) alleging that a Contributor Version +directly or indirectly infringes any patent, then the rights granted to +You by any and all Contributors for the Covered Software under Section +2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all +end user license agreements (excluding distributors and resellers) which +have been validly granted by You or Your distributors under this License +prior to termination shall survive termination. + +************************************************************************ +* * +* 6. Disclaimer of Warranty * +* ------------------------- * +* * +* Covered Software is provided under this License on an "as is" * +* basis, without warranty of any kind, either expressed, implied, or * +* statutory, including, without limitation, warranties that the * +* Covered Software is free of defects, merchantable, fit for a * +* particular purpose or non-infringing. The entire risk as to the * +* quality and performance of the Covered Software is with You. * +* Should any Covered Software prove defective in any respect, You * +* (not any Contributor) assume the cost of any necessary servicing, * +* repair, or correction. This disclaimer of warranty constitutes an * +* essential part of this License. No use of any Covered Software is * +* authorized under this License except under this disclaimer. * +* * +************************************************************************ + +************************************************************************ +* * +* 7. Limitation of Liability * +* -------------------------- * +* * +* Under no circumstances and under no legal theory, whether tort * +* (including negligence), contract, or otherwise, shall any * +* Contributor, or anyone who distributes Covered Software as * +* permitted above, be liable to You for any direct, indirect, * +* special, incidental, or consequential damages of any character * +* including, without limitation, damages for lost profits, loss of * +* goodwill, work stoppage, computer failure or malfunction, or any * +* and all other commercial damages or losses, even if such party * +* shall have been informed of the possibility of such damages. This * +* limitation of liability shall not apply to liability for death or * +* personal injury resulting from such party's negligence to the * +* extent applicable law prohibits such limitation. Some * +* jurisdictions do not allow the exclusion or limitation of * +* incidental or consequential damages, so this exclusion and * +* limitation may not apply to You. * +* * +************************************************************************ + +8. Litigation +------------- + +Any litigation relating to this License may be brought only in the +courts of a jurisdiction where the defendant maintains its principal +place of business and such litigation shall be governed by laws of that +jurisdiction, without reference to its conflict-of-law provisions. +Nothing in this Section shall prevent a party's ability to bring +cross-claims or counter-claims. + +9. Miscellaneous +---------------- + +This License represents the complete agreement concerning the subject +matter hereof. If any provision of this License is held to be +unenforceable, such provision shall be reformed only to the extent +necessary to make it enforceable. Any law or regulation which provides +that the language of a contract shall be construed against the drafter +shall not be used to construe this License against a Contributor. + +10. Versions of the License +--------------------------- + +10.1. New Versions + +Mozilla Foundation is the license steward. Except as provided in Section +10.3, no one other than the license steward has the right to modify or +publish new versions of this License. Each version will be given a +distinguishing version number. + +10.2. Effect of New Versions + +You may distribute the Covered Software under the terms of the version +of the License under which You originally received the Covered Software, +or under the terms of any subsequent version published by the license +steward. + +10.3. Modified Versions + +If you create software not governed by this License, and you want to +create a new license for such software, you may create and use a +modified version of this License if you rename the license and remove +any references to the name of the license steward (except to note that +such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary +Licenses + +If You choose to distribute Source Code Form that is Incompatible With +Secondary Licenses under the terms of this version of the License, the +notice described in Exhibit B of this License must be attached. + +Exhibit A - Source Code Form License Notice +------------------------------------------- + + This Source Code Form is subject to the terms of the Mozilla Public + License, v. 2.0. If a copy of the MPL was not distributed with this + file, You can obtain one at http://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular +file, then You may include the notice in a location (such as a LICENSE +file in a relevant directory) where a recipient would be likely to look +for such a notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - "Incompatible With Secondary Licenses" Notice +--------------------------------------------------------- + + This Source Code Form is "Incompatible With Secondary Licenses", as + defined by the Mozilla Public License, v. 2.0. diff --git a/builder/cloudstack/artifact.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/artifact.go similarity index 100% rename from builder/cloudstack/artifact.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/artifact.go diff --git a/builder/cloudstack/builder.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/builder.go similarity index 100% rename from builder/cloudstack/builder.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/builder.go diff --git a/builder/cloudstack/config.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/config.go similarity index 100% rename from builder/cloudstack/config.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/config.go diff --git a/builder/cloudstack/config.hcl2spec.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/config.hcl2spec.go similarity index 100% rename from builder/cloudstack/config.hcl2spec.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/config.hcl2spec.go diff --git a/builder/cloudstack/ssh.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/ssh.go similarity index 100% rename from builder/cloudstack/ssh.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/ssh.go diff --git a/builder/cloudstack/step_configure_networking.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_configure_networking.go similarity index 100% rename from builder/cloudstack/step_configure_networking.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_configure_networking.go diff --git a/builder/cloudstack/step_create_instance.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_create_instance.go similarity index 100% rename from builder/cloudstack/step_create_instance.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_create_instance.go diff --git a/builder/cloudstack/step_create_security_group.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_create_security_group.go similarity index 100% rename from builder/cloudstack/step_create_security_group.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_create_security_group.go diff --git a/builder/cloudstack/step_create_template.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_create_template.go similarity index 100% rename from builder/cloudstack/step_create_template.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_create_template.go diff --git a/builder/cloudstack/step_detach_iso.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_detach_iso.go similarity index 100% rename from builder/cloudstack/step_detach_iso.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_detach_iso.go diff --git a/builder/cloudstack/step_keypair.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_keypair.go similarity index 100% rename from builder/cloudstack/step_keypair.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_keypair.go diff --git a/builder/cloudstack/step_prepare_config.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_prepare_config.go similarity index 100% rename from builder/cloudstack/step_prepare_config.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_prepare_config.go diff --git a/builder/cloudstack/step_shutdown_instance.go b/vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_shutdown_instance.go similarity index 100% rename from builder/cloudstack/step_shutdown_instance.go rename to vendor/github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack/step_shutdown_instance.go diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/APIDiscoveryService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/APIDiscoveryService.go index e47653c45..030f034eb 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/APIDiscoveryService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/APIDiscoveryService.go @@ -75,8 +75,6 @@ type ListApisResponse struct { type Api struct { Description string `json:"description"` Isasync bool `json:"isasync"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Params []ApiParams `json:"params"` Related string `json:"related"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AccountService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AccountService.go index 2eb558594..ef82b7680 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AccountService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AccountService.go @@ -109,9 +109,8 @@ func (s *AccountService) AddAccountToProject(p *AddAccountToProjectParams) (*Add } type AddAccountToProjectResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -335,8 +334,6 @@ type CreateAccountResponse struct { Iptotal int64 `json:"iptotal"` Iscleanuprequired bool `json:"iscleanuprequired"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -467,9 +464,8 @@ func (s *AccountService) DeleteAccount(p *DeleteAccountParams) (*DeleteAccountRe } type DeleteAccountResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -548,9 +544,8 @@ func (s *AccountService) DeleteAccountFromProject(p *DeleteAccountFromProjectPar } type DeleteAccountFromProjectResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -656,6 +651,7 @@ func (s *AccountService) DisableAccount(p *DisableAccountParams) (*DisableAccoun } type DisableAccountResponse struct { + JobID string `json:"jobid"` Accountdetails map[string]string `json:"accountdetails"` Accounttype int `json:"accounttype"` Cpuavailable string `json:"cpuavailable"` @@ -671,8 +667,6 @@ type DisableAccountResponse struct { Iptotal int64 `json:"iptotal"` Iscleanuprequired bool `json:"iscleanuprequired"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -824,8 +818,6 @@ type EnableAccountResponse struct { Iptotal int64 `json:"iptotal"` Iscleanuprequired bool `json:"iscleanuprequired"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -953,9 +945,7 @@ func (s *AccountService) GetSolidFireAccountId(p *GetSolidFireAccountIdParams) ( } type GetSolidFireAccountIdResponse struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - SolidFireAccountId int64 `json:"solidFireAccountId"` + SolidFireAccountId int64 `json:"solidFireAccountId"` } type ListAccountsParams struct { @@ -1224,8 +1214,6 @@ type Account struct { Iptotal int64 `json:"iptotal"` Iscleanuprequired bool `json:"iscleanuprequired"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -1451,8 +1439,6 @@ type ProjectAccount struct { Ipavailable string `json:"ipavailable"` Iplimit string `json:"iplimit"` Iptotal int64 `json:"iptotal"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -1576,8 +1562,6 @@ type LockAccountResponse struct { Iptotal int64 `json:"iptotal"` Iscleanuprequired bool `json:"iscleanuprequired"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -1737,6 +1721,7 @@ func (s *AccountService) MarkDefaultZoneForAccount(p *MarkDefaultZoneForAccountP } type MarkDefaultZoneForAccountResponse struct { + JobID string `json:"jobid"` Accountdetails map[string]string `json:"accountdetails"` Accounttype int `json:"accounttype"` Cpuavailable string `json:"cpuavailable"` @@ -1752,8 +1737,6 @@ type MarkDefaultZoneForAccountResponse struct { Iptotal int64 `json:"iptotal"` Iscleanuprequired bool `json:"iscleanuprequired"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -1853,9 +1836,6 @@ func (p *UpdateAccountParams) toURLValues() url.Values { if v, found := p.p["newname"]; found { u.Set("newname", v.(string)) } - if v, found := p.p["roleid"]; found { - u.Set("roleid", v.(string)) - } return u } @@ -1907,19 +1887,12 @@ func (p *UpdateAccountParams) SetNewname(v string) { return } -func (p *UpdateAccountParams) SetRoleid(v string) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["roleid"] = v - return -} - // You should always use this function to get a new UpdateAccountParams instance, // as then you are sure you have configured all required params -func (s *AccountService) NewUpdateAccountParams() *UpdateAccountParams { +func (s *AccountService) NewUpdateAccountParams(newname string) *UpdateAccountParams { p := &UpdateAccountParams{} p.p = make(map[string]interface{}) + p.p["newname"] = newname return p } @@ -1954,8 +1927,6 @@ type UpdateAccountResponse struct { Iptotal int64 `json:"iptotal"` Iscleanuprequired bool `json:"iscleanuprequired"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AddressService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AddressService.go index ada47975e..d0a61fc8e 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AddressService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AddressService.go @@ -146,7 +146,7 @@ func (s *AddressService) NewAssociateIpAddressParams() *AssociateIpAddressParams return p } -// Acquires and associates a public IP to an account. Either of the parameters are required, i.e. either zoneId, or networkId, or vpcId +// Acquires and associates a public IP to an account. func (s *AddressService) AssociateIpAddress(p *AssociateIpAddressParams) (*AssociateIpAddressResponse, error) { resp, err := s.cs.newRequest("associateIpAddress", p.toURLValues()) if err != nil { @@ -182,6 +182,7 @@ func (s *AddressService) AssociateIpAddress(p *AssociateIpAddressParams) (*Assoc } type AssociateIpAddressResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Allocated string `json:"allocated"` Associatednetworkid string `json:"associatednetworkid"` @@ -196,8 +197,6 @@ type AssociateIpAddressResponse struct { Issourcenat bool `json:"issourcenat"` Isstaticnat bool `json:"isstaticnat"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Physicalnetworkid string `json:"physicalnetworkid"` Project string `json:"project"` @@ -279,9 +278,8 @@ func (s *AddressService) DisassociateIpAddress(p *DisassociateIpAddressParams) ( } type DisassociateIpAddressResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -641,8 +639,6 @@ type PublicIpAddress struct { Issourcenat bool `json:"issourcenat"` Isstaticnat bool `json:"isstaticnat"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Physicalnetworkid string `json:"physicalnetworkid"` Project string `json:"project"` @@ -752,6 +748,7 @@ func (s *AddressService) UpdateIpAddress(p *UpdateIpAddressParams) (*UpdateIpAdd } type UpdateIpAddressResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Allocated string `json:"allocated"` Associatednetworkid string `json:"associatednetworkid"` @@ -766,8 +763,6 @@ type UpdateIpAddressResponse struct { Issourcenat bool `json:"issourcenat"` Isstaticnat bool `json:"isstaticnat"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Physicalnetworkid string `json:"physicalnetworkid"` Project string `json:"project"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AffinityGroupService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AffinityGroupService.go index 87d28d85f..d81b54d05 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AffinityGroupService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AffinityGroupService.go @@ -148,13 +148,12 @@ func (s *AffinityGroupService) CreateAffinityGroup(p *CreateAffinityGroupParams) } type CreateAffinityGroupResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Description string `json:"description"` Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -268,9 +267,8 @@ func (s *AffinityGroupService) DeleteAffinityGroup(p *DeleteAffinityGroupParams) } type DeleteAffinityGroupResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -350,9 +348,7 @@ type ListAffinityGroupTypesResponse struct { } type AffinityGroupType struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Type string `json:"type"` + Type string `json:"type"` } type ListAffinityGroupsParams struct { @@ -628,8 +624,6 @@ type AffinityGroup struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -729,6 +723,7 @@ func (s *AffinityGroupService) UpdateVMAffinityGroup(p *UpdateVMAffinityGroupPar } type UpdateVMAffinityGroupResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []UpdateVMAffinityGroupResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -760,8 +755,6 @@ type UpdateVMAffinityGroupResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -771,7 +764,7 @@ type UpdateVMAffinityGroupResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -785,7 +778,6 @@ type UpdateVMAffinityGroupResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -837,30 +829,3 @@ type UpdateVMAffinityGroupResponseAffinitygroup struct { Type string `json:"type"` VirtualmachineIds []string `json:"virtualmachineIds"` } - -func (r *UpdateVMAffinityGroupResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias UpdateVMAffinityGroupResponse - return json.Unmarshal(b, (*alias)(r)) -} diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AlertService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AlertService.go index 8202e9631..e6fb54118 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AlertService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AlertService.go @@ -106,8 +106,6 @@ func (s *AlertService) ArchiveAlerts(p *ArchiveAlertsParams) (*ArchiveAlertsResp type ArchiveAlertsResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -126,14 +124,6 @@ func (r *ArchiveAlertsResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias ArchiveAlertsResponse return json.Unmarshal(b, (*alias)(r)) } @@ -220,8 +210,6 @@ func (s *AlertService) DeleteAlerts(p *DeleteAlertsParams) (*DeleteAlertsRespons type DeleteAlertsResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -240,14 +228,6 @@ func (r *DeleteAlertsResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteAlertsResponse return json.Unmarshal(b, (*alias)(r)) } @@ -362,9 +342,8 @@ func (s *AlertService) GenerateAlert(p *GenerateAlertParams) (*GenerateAlertResp } type GenerateAlertResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -562,8 +541,6 @@ type ListAlertsResponse struct { type Alert struct { Description string `json:"description"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Sent string `json:"sent"` Type int `json:"type"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AsyncjobService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AsyncjobService.go index 20ad3b0a9..93c1fa049 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AsyncjobService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AsyncjobService.go @@ -158,9 +158,7 @@ type ListAsyncJobsResponse struct { type AsyncJob struct { Accountid string `json:"accountid"` Cmd string `json:"cmd"` - Completed string `json:"completed"` Created string `json:"created"` - JobID string `json:"jobid"` Jobinstanceid string `json:"jobinstanceid"` Jobinstancetype string `json:"jobinstancetype"` Jobprocstatus int `json:"jobprocstatus"` @@ -231,9 +229,7 @@ func (s *AsyncjobService) QueryAsyncJobResult(p *QueryAsyncJobResultParams) (*Qu type QueryAsyncJobResultResponse struct { Accountid string `json:"accountid"` Cmd string `json:"cmd"` - Completed string `json:"completed"` Created string `json:"created"` - JobID string `json:"jobid"` Jobinstanceid string `json:"jobinstanceid"` Jobinstancetype string `json:"jobinstancetype"` Jobprocstatus int `json:"jobprocstatus"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AuthenticationService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AuthenticationService.go index aa886fed8..7842d049a 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AuthenticationService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AuthenticationService.go @@ -108,8 +108,6 @@ type LoginResponse struct { Account string `json:"account"` Domainid string `json:"domainid"` Firstname string `json:"firstname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Registered string `json:"registered"` Sessionkey string `json:"sessionkey"` @@ -158,6 +156,4 @@ func (s *AuthenticationService) Logout(p *LogoutParams) (*LogoutResponse, error) type LogoutResponse struct { Description string `json:"description"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AutoScaleService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AutoScaleService.go index ee6d8a0c6..fd18f87e7 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/AutoScaleService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/AutoScaleService.go @@ -130,6 +130,7 @@ func (s *AutoScaleService) CreateAutoScalePolicy(p *CreateAutoScalePolicyParams) } type CreateAutoScalePolicyResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Action string `json:"action"` Conditions []string `json:"conditions"` @@ -137,8 +138,6 @@ type CreateAutoScalePolicyResponse struct { Domainid string `json:"domainid"` Duration int `json:"duration"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` Quiettime int `json:"quiettime"` @@ -300,14 +299,13 @@ func (s *AutoScaleService) CreateAutoScaleVmGroup(p *CreateAutoScaleVmGroupParam } type CreateAutoScaleVmGroupResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Interval int `json:"interval"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Maxmembers int `json:"maxmembers"` Minmembers int `json:"minmembers"` @@ -473,6 +471,7 @@ func (s *AutoScaleService) CreateAutoScaleVmProfile(p *CreateAutoScaleVmProfileP } type CreateAutoScaleVmProfileResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Autoscaleuserid string `json:"autoscaleuserid"` Destroyvmgraceperiod int `json:"destroyvmgraceperiod"` @@ -480,8 +479,6 @@ type CreateAutoScaleVmProfileResponse struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Otherdeployparams string `json:"otherdeployparams"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -605,13 +602,12 @@ func (s *AutoScaleService) CreateCondition(p *CreateConditionParams) (*CreateCon } type CreateConditionResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Counter []string `json:"counter"` Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` Relationaloperator string `json:"relationaloperator"` @@ -711,13 +707,12 @@ func (s *AutoScaleService) CreateCounter(p *CreateCounterParams) (*CreateCounter } type CreateCounterResponse struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` - Source string `json:"source"` - Value string `json:"value"` - Zoneid string `json:"zoneid"` + JobID string `json:"jobid"` + Id string `json:"id"` + Name string `json:"name"` + Source string `json:"source"` + Value string `json:"value"` + Zoneid string `json:"zoneid"` } type DeleteAutoScalePolicyParams struct { @@ -783,9 +778,8 @@ func (s *AutoScaleService) DeleteAutoScalePolicy(p *DeleteAutoScalePolicyParams) } type DeleteAutoScalePolicyResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -852,9 +846,8 @@ func (s *AutoScaleService) DeleteAutoScaleVmGroup(p *DeleteAutoScaleVmGroupParam } type DeleteAutoScaleVmGroupResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -921,9 +914,8 @@ func (s *AutoScaleService) DeleteAutoScaleVmProfile(p *DeleteAutoScaleVmProfileP } type DeleteAutoScaleVmProfileResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -990,9 +982,8 @@ func (s *AutoScaleService) DeleteCondition(p *DeleteConditionParams) (*DeleteCon } type DeleteConditionResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1059,9 +1050,8 @@ func (s *AutoScaleService) DeleteCounter(p *DeleteCounterParams) (*DeleteCounter } type DeleteCounterResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1133,14 +1123,13 @@ func (s *AutoScaleService) DisableAutoScaleVmGroup(p *DisableAutoScaleVmGroupPar } type DisableAutoScaleVmGroupResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Interval int `json:"interval"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Maxmembers int `json:"maxmembers"` Minmembers int `json:"minmembers"` @@ -1220,14 +1209,13 @@ func (s *AutoScaleService) EnableAutoScaleVmGroup(p *EnableAutoScaleVmGroupParam } type EnableAutoScaleVmGroupResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Interval int `json:"interval"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Maxmembers int `json:"maxmembers"` Minmembers int `json:"minmembers"` @@ -1445,8 +1433,6 @@ type AutoScalePolicy struct { Domainid string `json:"domainid"` Duration int `json:"duration"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` Quiettime int `json:"quiettime"` @@ -1691,8 +1677,6 @@ type AutoScaleVmGroup struct { Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Interval int `json:"interval"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Maxmembers int `json:"maxmembers"` Minmembers int `json:"minmembers"` @@ -1944,8 +1928,6 @@ type AutoScaleVmProfile struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Otherdeployparams string `json:"otherdeployparams"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -2147,8 +2129,6 @@ type Condition struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` Relationaloperator string `json:"relationaloperator"` @@ -2348,13 +2328,11 @@ type ListCountersResponse struct { } type Counter struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` - Source string `json:"source"` - Value string `json:"value"` - Zoneid string `json:"zoneid"` + Id string `json:"id"` + Name string `json:"name"` + Source string `json:"source"` + Value string `json:"value"` + Zoneid string `json:"zoneid"` } type UpdateAutoScalePolicyParams struct { @@ -2461,6 +2439,7 @@ func (s *AutoScaleService) UpdateAutoScalePolicy(p *UpdateAutoScalePolicyParams) } type UpdateAutoScalePolicyResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Action string `json:"action"` Conditions []string `json:"conditions"` @@ -2468,8 +2447,6 @@ type UpdateAutoScalePolicyResponse struct { Domainid string `json:"domainid"` Duration int `json:"duration"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` Quiettime int `json:"quiettime"` @@ -2626,14 +2603,13 @@ func (s *AutoScaleService) UpdateAutoScaleVmGroup(p *UpdateAutoScaleVmGroupParam } type UpdateAutoScaleVmGroupResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Interval int `json:"interval"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Maxmembers int `json:"maxmembers"` Minmembers int `json:"minmembers"` @@ -2786,6 +2762,7 @@ func (s *AutoScaleService) UpdateAutoScaleVmProfile(p *UpdateAutoScaleVmProfileP } type UpdateAutoScaleVmProfileResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Autoscaleuserid string `json:"autoscaleuserid"` Destroyvmgraceperiod int `json:"destroyvmgraceperiod"` @@ -2793,8 +2770,6 @@ type UpdateAutoScaleVmProfileResponse struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Otherdeployparams string `json:"otherdeployparams"` Project string `json:"project"` Projectid string `json:"projectid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/BaremetalService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/BaremetalService.go index 41877f4e4..2b8b9f20d 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/BaremetalService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/BaremetalService.go @@ -138,10 +138,9 @@ func (s *BaremetalService) AddBaremetalDhcp(p *AddBaremetalDhcpParams) (*AddBare } type AddBaremetalDhcpResponse struct { + JobID string `json:"jobid"` Dhcpservertype string `json:"dhcpservertype"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Physicalnetworkid string `json:"physicalnetworkid"` Provider string `json:"provider"` Url string `json:"url"` @@ -286,13 +285,8 @@ func (s *BaremetalService) AddBaremetalPxeKickStartServer(p *AddBaremetalPxeKick } type AddBaremetalPxeKickStartServerResponse struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Physicalnetworkid string `json:"physicalnetworkid"` - Provider string `json:"provider"` - Tftpdir string `json:"tftpdir"` - Url string `json:"url"` + JobID string `json:"jobid"` + Tftpdir string `json:"tftpdir"` } type AddBaremetalPxePingServerParams struct { @@ -480,15 +474,10 @@ func (s *BaremetalService) AddBaremetalPxePingServer(p *AddBaremetalPxePingServe } type AddBaremetalPxePingServerResponse struct { - Id string `json:"id"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Physicalnetworkid string `json:"physicalnetworkid"` Pingdir string `json:"pingdir"` Pingstorageserverip string `json:"pingstorageserverip"` - Provider string `json:"provider"` Tftpdir string `json:"tftpdir"` - Url string `json:"url"` } type AddBaremetalRctParams struct { @@ -559,10 +548,9 @@ func (s *BaremetalService) AddBaremetalRct(p *AddBaremetalRctParams) (*AddBareme } type AddBaremetalRctResponse struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Url string `json:"url"` + JobID string `json:"jobid"` + Id string `json:"id"` + Url string `json:"url"` } type DeleteBaremetalRctParams struct { @@ -628,9 +616,8 @@ func (s *BaremetalService) DeleteBaremetalRct(p *DeleteBaremetalRctParams) (*Del } type DeleteBaremetalRctResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -747,8 +734,6 @@ type ListBaremetalDhcpResponse struct { type BaremetalDhcp struct { Dhcpservertype string `json:"dhcpservertype"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Physicalnetworkid string `json:"physicalnetworkid"` Provider string `json:"provider"` Url string `json:"url"` @@ -855,8 +840,6 @@ type ListBaremetalPxeServersResponse struct { type BaremetalPxeServer struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Physicalnetworkid string `json:"physicalnetworkid"` Provider string `json:"provider"` Url string `json:"url"` @@ -938,10 +921,8 @@ type ListBaremetalRctResponse struct { } type BaremetalRct struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Url string `json:"url"` + Id string `json:"id"` + Url string `json:"url"` } type NotifyBaremetalProvisionDoneParams struct { @@ -1007,8 +988,7 @@ func (s *BaremetalService) NotifyBaremetalProvisionDone(p *NotifyBaremetalProvis } type NotifyBaremetalProvisionDoneResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/BigSwitchBCFService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/BigSwitchBCFService.go index 3b88d5235..e85b20730 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/BigSwitchBCFService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/BigSwitchBCFService.go @@ -139,11 +139,10 @@ func (s *BigSwitchBCFService) AddBigSwitchBcfDevice(p *AddBigSwitchBcfDevicePara } type AddBigSwitchBcfDeviceResponse struct { + JobID string `json:"jobid"` Bcfdeviceid string `json:"bcfdeviceid"` Bigswitchdevicename string `json:"bigswitchdevicename"` Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Nat bool `json:"nat"` Password string `json:"password"` Physicalnetworkid string `json:"physicalnetworkid"` @@ -214,9 +213,8 @@ func (s *BigSwitchBCFService) DeleteBigSwitchBcfDevice(p *DeleteBigSwitchBcfDevi } type DeleteBigSwitchBcfDeviceResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -321,8 +319,6 @@ type BigSwitchBcfDevice struct { Bcfdeviceid string `json:"bcfdeviceid"` Bigswitchdevicename string `json:"bigswitchdevicename"` Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Nat bool `json:"nat"` Password string `json:"password"` Physicalnetworkid string `json:"physicalnetworkid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/BrocadeVCSService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/BrocadeVCSService.go index a89df33e8..297476709 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/BrocadeVCSService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/BrocadeVCSService.go @@ -127,10 +127,9 @@ func (s *BrocadeVCSService) AddBrocadeVcsDevice(p *AddBrocadeVcsDeviceParams) (* } type AddBrocadeVcsDeviceResponse struct { + JobID string `json:"jobid"` Brocadedevicename string `json:"brocadedevicename"` Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Physicalnetworkid string `json:"physicalnetworkid"` Provider string `json:"provider"` Vcsdeviceid string `json:"vcsdeviceid"` @@ -199,9 +198,8 @@ func (s *BrocadeVCSService) DeleteBrocadeVcsDevice(p *DeleteBrocadeVcsDevicePara } type DeleteBrocadeVcsDeviceResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -351,8 +349,6 @@ type BrocadeVcsDeviceNetwork struct { Isdefault bool `json:"isdefault"` Ispersistent bool `json:"ispersistent"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Netmask string `json:"netmask"` Networkcidr string `json:"networkcidr"` @@ -506,8 +502,6 @@ type ListBrocadeVcsDevicesResponse struct { type BrocadeVcsDevice struct { Brocadedevicename string `json:"brocadedevicename"` Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Physicalnetworkid string `json:"physicalnetworkid"` Provider string `json:"provider"` Vcsdeviceid string `json:"vcsdeviceid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/CertificateService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/CertificateService.go index 46ea6f1eb..196b961e4 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/CertificateService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/CertificateService.go @@ -136,7 +136,6 @@ func (s *CertificateService) UploadCustomCertificate(p *UploadCustomCertificateP } type UploadCustomCertificateResponse struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Message string `json:"message"` + JobID string `json:"jobid"` + Message string `json:"message"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/CloudIdentifierService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/CloudIdentifierService.go index 5da8af1fa..40d70aa92 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/CloudIdentifierService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/CloudIdentifierService.go @@ -70,8 +70,6 @@ func (s *CloudIdentifierService) GetCloudIdentifier(p *GetCloudIdentifierParams) type GetCloudIdentifierResponse struct { Cloudidentifier string `json:"cloudidentifier"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Signature string `json:"signature"` Userid string `json:"userid"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ClusterService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ClusterService.go index 9a3c15d2e..8ad5cfce3 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ClusterService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ClusterService.go @@ -280,8 +280,6 @@ type AddClusterResponse struct { Cpuovercommitratio string `json:"cpuovercommitratio"` Hypervisortype string `json:"hypervisortype"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Managedstate string `json:"managedstate"` Memoryovercommitratio string `json:"memoryovercommitratio"` Name string `json:"name"` @@ -399,14 +397,13 @@ func (s *ClusterService) DedicateCluster(p *DedicateClusterParams) (*DedicateClu } type DedicateClusterResponse struct { + JobID string `json:"jobid"` Accountid string `json:"accountid"` Affinitygroupid string `json:"affinitygroupid"` Clusterid string `json:"clusterid"` Clustername string `json:"clustername"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` } type DeleteClusterParams struct { @@ -458,8 +455,6 @@ func (s *ClusterService) DeleteCluster(p *DeleteClusterParams) (*DeleteClusterRe type DeleteClusterResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -478,14 +473,6 @@ func (r *DeleteClusterResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteClusterResponse return json.Unmarshal(b, (*alias)(r)) } @@ -558,14 +545,13 @@ func (s *ClusterService) DisableOutOfBandManagementForCluster(p *DisableOutOfBan } type DisableOutOfBandManagementForClusterResponse struct { + JobID string `json:"jobid"` Action string `json:"action"` Address string `json:"address"` Description string `json:"description"` Driver string `json:"driver"` Enabled bool `json:"enabled"` Hostid string `json:"hostid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Password string `json:"password"` Port string `json:"port"` Powerstate string `json:"powerstate"` @@ -641,14 +627,13 @@ func (s *ClusterService) EnableOutOfBandManagementForCluster(p *EnableOutOfBandM } type EnableOutOfBandManagementForClusterResponse struct { + JobID string `json:"jobid"` Action string `json:"action"` Address string `json:"address"` Description string `json:"description"` Driver string `json:"driver"` Enabled bool `json:"enabled"` Hostid string `json:"hostid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Password string `json:"password"` Port string `json:"port"` Powerstate string `json:"powerstate"` @@ -921,8 +906,6 @@ type Cluster struct { Cpuovercommitratio string `json:"cpuovercommitratio"` Hypervisortype string `json:"hypervisortype"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Managedstate string `json:"managedstate"` Memoryovercommitratio string `json:"memoryovercommitratio"` Name string `json:"name"` @@ -1075,8 +1058,6 @@ type DedicatedCluster struct { Clustername string `json:"clustername"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` } type ReleaseDedicatedClusterParams struct { @@ -1142,9 +1123,8 @@ func (s *ClusterService) ReleaseDedicatedCluster(p *ReleaseDedicatedClusterParam } type ReleaseDedicatedClusterResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1257,8 +1237,6 @@ type UpdateClusterResponse struct { Cpuovercommitratio string `json:"cpuovercommitratio"` Hypervisortype string `json:"hypervisortype"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Managedstate string `json:"managedstate"` Memoryovercommitratio string `json:"memoryovercommitratio"` Name string `json:"name"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ConfigurationService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ConfigurationService.go index 93f8d2f27..2f87a3cbe 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ConfigurationService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ConfigurationService.go @@ -72,8 +72,6 @@ type Capability struct { Customdiskofferingmaxsize int64 `json:"customdiskofferingmaxsize"` Customdiskofferingminsize int64 `json:"customdiskofferingminsize"` Dynamicrolesenabled bool `json:"dynamicrolesenabled"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Kvmsnapshotenabled bool `json:"kvmsnapshotenabled"` Projectinviterequired bool `json:"projectinviterequired"` Regionsecondaryenabled bool `json:"regionsecondaryenabled"` @@ -249,8 +247,6 @@ type Configuration struct { Category string `json:"category"` Description string `json:"description"` Id int64 `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Scope string `json:"scope"` Value string `json:"value"` @@ -332,9 +328,7 @@ type ListDeploymentPlannersResponse struct { } type DeploymentPlanner struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` + Name string `json:"name"` } type UpdateConfigurationParams struct { @@ -465,8 +459,6 @@ type UpdateConfigurationResponse struct { Category string `json:"category"` Description string `json:"description"` Id int64 `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Scope string `json:"scope"` Value string `json:"value"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/DiskOfferingService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/DiskOfferingService.go index f71d646f8..9e529ee16 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/DiskOfferingService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/DiskOfferingService.go @@ -37,26 +37,10 @@ func (p *CreateDiskOfferingParams) toURLValues() url.Values { vv := strconv.FormatInt(v.(int64), 10) u.Set("bytesreadrate", vv) } - if v, found := p.p["bytesreadratemax"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("bytesreadratemax", vv) - } - if v, found := p.p["bytesreadratemaxlength"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("bytesreadratemaxlength", vv) - } if v, found := p.p["byteswriterate"]; found { vv := strconv.FormatInt(v.(int64), 10) u.Set("byteswriterate", vv) } - if v, found := p.p["byteswriteratemax"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("byteswriteratemax", vv) - } - if v, found := p.p["byteswriteratemaxlength"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("byteswriteratemaxlength", vv) - } if v, found := p.p["customized"]; found { vv := strconv.FormatBool(v.(bool)) u.Set("customized", vv) @@ -87,26 +71,10 @@ func (p *CreateDiskOfferingParams) toURLValues() url.Values { vv := strconv.FormatInt(v.(int64), 10) u.Set("iopsreadrate", vv) } - if v, found := p.p["iopsreadratemax"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("iopsreadratemax", vv) - } - if v, found := p.p["iopsreadratemaxlength"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("iopsreadratemaxlength", vv) - } if v, found := p.p["iopswriterate"]; found { vv := strconv.FormatInt(v.(int64), 10) u.Set("iopswriterate", vv) } - if v, found := p.p["iopswriteratemax"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("iopswriteratemax", vv) - } - if v, found := p.p["iopswriteratemaxlength"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("iopswriteratemaxlength", vv) - } if v, found := p.p["maxiops"]; found { vv := strconv.FormatInt(v.(int64), 10) u.Set("maxiops", vv) @@ -138,22 +106,6 @@ func (p *CreateDiskOfferingParams) SetBytesreadrate(v int64) { return } -func (p *CreateDiskOfferingParams) SetBytesreadratemax(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["bytesreadratemax"] = v - return -} - -func (p *CreateDiskOfferingParams) SetBytesreadratemaxlength(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["bytesreadratemaxlength"] = v - return -} - func (p *CreateDiskOfferingParams) SetByteswriterate(v int64) { if p.p == nil { p.p = make(map[string]interface{}) @@ -162,22 +114,6 @@ func (p *CreateDiskOfferingParams) SetByteswriterate(v int64) { return } -func (p *CreateDiskOfferingParams) SetByteswriteratemax(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["byteswriteratemax"] = v - return -} - -func (p *CreateDiskOfferingParams) SetByteswriteratemaxlength(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["byteswriteratemaxlength"] = v - return -} - func (p *CreateDiskOfferingParams) SetCustomized(v bool) { if p.p == nil { p.p = make(map[string]interface{}) @@ -242,22 +178,6 @@ func (p *CreateDiskOfferingParams) SetIopsreadrate(v int64) { return } -func (p *CreateDiskOfferingParams) SetIopsreadratemax(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["iopsreadratemax"] = v - return -} - -func (p *CreateDiskOfferingParams) SetIopsreadratemaxlength(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["iopsreadratemaxlength"] = v - return -} - func (p *CreateDiskOfferingParams) SetIopswriterate(v int64) { if p.p == nil { p.p = make(map[string]interface{}) @@ -266,22 +186,6 @@ func (p *CreateDiskOfferingParams) SetIopswriterate(v int64) { return } -func (p *CreateDiskOfferingParams) SetIopswriteratemax(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["iopswriteratemax"] = v - return -} - -func (p *CreateDiskOfferingParams) SetIopswriteratemaxlength(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["iopswriteratemaxlength"] = v - return -} - func (p *CreateDiskOfferingParams) SetMaxiops(v int64) { if p.p == nil { p.p = make(map[string]interface{}) @@ -356,37 +260,27 @@ func (s *DiskOfferingService) CreateDiskOffering(p *CreateDiskOfferingParams) (* } type CreateDiskOfferingResponse struct { - CacheMode string `json:"cacheMode"` - Created string `json:"created"` - DiskBytesReadRate int64 `json:"diskBytesReadRate"` - DiskBytesReadRateMax int64 `json:"diskBytesReadRateMax"` - DiskBytesReadRateMaxLength int64 `json:"diskBytesReadRateMaxLength"` - DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` - DiskBytesWriteRateMax int64 `json:"diskBytesWriteRateMax"` - DiskBytesWriteRateMaxLength int64 `json:"diskBytesWriteRateMaxLength"` - DiskIopsReadRate int64 `json:"diskIopsReadRate"` - DiskIopsReadRateMax int64 `json:"diskIopsReadRateMax"` - DiskIopsReadRateMaxLength int64 `json:"diskIopsReadRateMaxLength"` - DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` - DiskIopsWriteRateMax int64 `json:"diskIopsWriteRateMax"` - DiskIopsWriteRateMaxLength int64 `json:"diskIopsWriteRateMaxLength"` - Disksize int64 `json:"disksize"` - Displayoffering bool `json:"displayoffering"` - Displaytext string `json:"displaytext"` - Domain string `json:"domain"` - Domainid string `json:"domainid"` - Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` - Id string `json:"id"` - Iscustomized bool `json:"iscustomized"` - Iscustomizediops bool `json:"iscustomizediops"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Maxiops int64 `json:"maxiops"` - Miniops int64 `json:"miniops"` - Name string `json:"name"` - Provisioningtype string `json:"provisioningtype"` - Storagetype string `json:"storagetype"` - Tags string `json:"tags"` + CacheMode string `json:"cacheMode"` + Created string `json:"created"` + DiskBytesReadRate int64 `json:"diskBytesReadRate"` + DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` + DiskIopsReadRate int64 `json:"diskIopsReadRate"` + DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` + Disksize int64 `json:"disksize"` + Displayoffering bool `json:"displayoffering"` + Displaytext string `json:"displaytext"` + Domain string `json:"domain"` + Domainid string `json:"domainid"` + Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` + Id string `json:"id"` + Iscustomized bool `json:"iscustomized"` + Iscustomizediops bool `json:"iscustomizediops"` + Maxiops int64 `json:"maxiops"` + Miniops int64 `json:"miniops"` + Name string `json:"name"` + Provisioningtype string `json:"provisioningtype"` + Storagetype string `json:"storagetype"` + Tags string `json:"tags"` } type DeleteDiskOfferingParams struct { @@ -438,8 +332,6 @@ func (s *DiskOfferingService) DeleteDiskOffering(p *DeleteDiskOfferingParams) (* type DeleteDiskOfferingResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -458,14 +350,6 @@ func (r *DeleteDiskOfferingResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteDiskOfferingResponse return json.Unmarshal(b, (*alias)(r)) } @@ -686,37 +570,27 @@ type ListDiskOfferingsResponse struct { } type DiskOffering struct { - CacheMode string `json:"cacheMode"` - Created string `json:"created"` - DiskBytesReadRate int64 `json:"diskBytesReadRate"` - DiskBytesReadRateMax int64 `json:"diskBytesReadRateMax"` - DiskBytesReadRateMaxLength int64 `json:"diskBytesReadRateMaxLength"` - DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` - DiskBytesWriteRateMax int64 `json:"diskBytesWriteRateMax"` - DiskBytesWriteRateMaxLength int64 `json:"diskBytesWriteRateMaxLength"` - DiskIopsReadRate int64 `json:"diskIopsReadRate"` - DiskIopsReadRateMax int64 `json:"diskIopsReadRateMax"` - DiskIopsReadRateMaxLength int64 `json:"diskIopsReadRateMaxLength"` - DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` - DiskIopsWriteRateMax int64 `json:"diskIopsWriteRateMax"` - DiskIopsWriteRateMaxLength int64 `json:"diskIopsWriteRateMaxLength"` - Disksize int64 `json:"disksize"` - Displayoffering bool `json:"displayoffering"` - Displaytext string `json:"displaytext"` - Domain string `json:"domain"` - Domainid string `json:"domainid"` - Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` - Id string `json:"id"` - Iscustomized bool `json:"iscustomized"` - Iscustomizediops bool `json:"iscustomizediops"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Maxiops int64 `json:"maxiops"` - Miniops int64 `json:"miniops"` - Name string `json:"name"` - Provisioningtype string `json:"provisioningtype"` - Storagetype string `json:"storagetype"` - Tags string `json:"tags"` + CacheMode string `json:"cacheMode"` + Created string `json:"created"` + DiskBytesReadRate int64 `json:"diskBytesReadRate"` + DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` + DiskIopsReadRate int64 `json:"diskIopsReadRate"` + DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` + Disksize int64 `json:"disksize"` + Displayoffering bool `json:"displayoffering"` + Displaytext string `json:"displaytext"` + Domain string `json:"domain"` + Domainid string `json:"domainid"` + Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` + Id string `json:"id"` + Iscustomized bool `json:"iscustomized"` + Iscustomizediops bool `json:"iscustomizediops"` + Maxiops int64 `json:"maxiops"` + Miniops int64 `json:"miniops"` + Name string `json:"name"` + Provisioningtype string `json:"provisioningtype"` + Storagetype string `json:"storagetype"` + Tags string `json:"tags"` } type UpdateDiskOfferingParams struct { @@ -813,35 +687,25 @@ func (s *DiskOfferingService) UpdateDiskOffering(p *UpdateDiskOfferingParams) (* } type UpdateDiskOfferingResponse struct { - CacheMode string `json:"cacheMode"` - Created string `json:"created"` - DiskBytesReadRate int64 `json:"diskBytesReadRate"` - DiskBytesReadRateMax int64 `json:"diskBytesReadRateMax"` - DiskBytesReadRateMaxLength int64 `json:"diskBytesReadRateMaxLength"` - DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` - DiskBytesWriteRateMax int64 `json:"diskBytesWriteRateMax"` - DiskBytesWriteRateMaxLength int64 `json:"diskBytesWriteRateMaxLength"` - DiskIopsReadRate int64 `json:"diskIopsReadRate"` - DiskIopsReadRateMax int64 `json:"diskIopsReadRateMax"` - DiskIopsReadRateMaxLength int64 `json:"diskIopsReadRateMaxLength"` - DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` - DiskIopsWriteRateMax int64 `json:"diskIopsWriteRateMax"` - DiskIopsWriteRateMaxLength int64 `json:"diskIopsWriteRateMaxLength"` - Disksize int64 `json:"disksize"` - Displayoffering bool `json:"displayoffering"` - Displaytext string `json:"displaytext"` - Domain string `json:"domain"` - Domainid string `json:"domainid"` - Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` - Id string `json:"id"` - Iscustomized bool `json:"iscustomized"` - Iscustomizediops bool `json:"iscustomizediops"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Maxiops int64 `json:"maxiops"` - Miniops int64 `json:"miniops"` - Name string `json:"name"` - Provisioningtype string `json:"provisioningtype"` - Storagetype string `json:"storagetype"` - Tags string `json:"tags"` + CacheMode string `json:"cacheMode"` + Created string `json:"created"` + DiskBytesReadRate int64 `json:"diskBytesReadRate"` + DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` + DiskIopsReadRate int64 `json:"diskIopsReadRate"` + DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` + Disksize int64 `json:"disksize"` + Displayoffering bool `json:"displayoffering"` + Displaytext string `json:"displaytext"` + Domain string `json:"domain"` + Domainid string `json:"domainid"` + Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` + Id string `json:"id"` + Iscustomized bool `json:"iscustomized"` + Iscustomizediops bool `json:"iscustomizediops"` + Maxiops int64 `json:"maxiops"` + Miniops int64 `json:"miniops"` + Name string `json:"name"` + Provisioningtype string `json:"provisioningtype"` + Storagetype string `json:"storagetype"` + Tags string `json:"tags"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/DomainService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/DomainService.go index fdf26044f..5aff9933e 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/DomainService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/DomainService.go @@ -113,8 +113,6 @@ type CreateDomainResponse struct { Ipavailable string `json:"ipavailable"` Iplimit string `json:"iplimit"` Iptotal int64 `json:"iptotal"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Level int `json:"level"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` @@ -229,9 +227,8 @@ func (s *DomainService) DeleteDomain(p *DeleteDomainParams) (*DeleteDomainRespon } type DeleteDomainResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -448,8 +445,6 @@ type DomainChildren struct { Ipavailable string `json:"ipavailable"` Iplimit string `json:"iplimit"` Iptotal int64 `json:"iptotal"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Level int `json:"level"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` @@ -714,8 +709,6 @@ type Domain struct { Ipavailable string `json:"ipavailable"` Iplimit string `json:"iplimit"` Iptotal int64 `json:"iptotal"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Level int `json:"level"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` @@ -833,8 +826,6 @@ type UpdateDomainResponse struct { Ipavailable string `json:"ipavailable"` Iplimit string `json:"iplimit"` Iptotal int64 `json:"iptotal"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Level int `json:"level"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/EventService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/EventService.go index 243ada4fa..f1cd41c2a 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/EventService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/EventService.go @@ -106,8 +106,6 @@ func (s *EventService) ArchiveEvents(p *ArchiveEventsParams) (*ArchiveEventsResp type ArchiveEventsResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -126,14 +124,6 @@ func (r *ArchiveEventsResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias ArchiveEventsResponse return json.Unmarshal(b, (*alias)(r)) } @@ -220,8 +210,6 @@ func (s *EventService) DeleteEvents(p *DeleteEventsParams) (*DeleteEventsRespons type DeleteEventsResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -240,14 +228,6 @@ func (r *DeleteEventsResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteEventsResponse return json.Unmarshal(b, (*alias)(r)) } @@ -293,9 +273,7 @@ type ListEventTypesResponse struct { } type EventType struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` + Name string `json:"name"` } type ListEventsParams struct { @@ -560,8 +538,6 @@ type Event struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Level string `json:"level"` Parentid string `json:"parentid"` Project string `json:"project"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/FirewallService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/FirewallService.go index 766b7748c..4c4f85b6b 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/FirewallService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/FirewallService.go @@ -195,13 +195,12 @@ func (s *FirewallService) AddPaloAltoFirewall(p *AddPaloAltoFirewallParams) (*Ad } type AddPaloAltoFirewallResponse struct { + JobID string `json:"jobid"` Fwdevicecapacity int64 `json:"fwdevicecapacity"` Fwdeviceid string `json:"fwdeviceid"` Fwdevicename string `json:"fwdevicename"` Fwdevicestate string `json:"fwdevicestate"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Numretries string `json:"numretries"` Physicalnetworkid string `json:"physicalnetworkid"` Privateinterface string `json:"privateinterface"` @@ -300,13 +299,12 @@ func (s *FirewallService) ConfigurePaloAltoFirewall(p *ConfigurePaloAltoFirewall } type PaloAltoFirewallResponse struct { + JobID string `json:"jobid"` Fwdevicecapacity int64 `json:"fwdevicecapacity"` Fwdeviceid string `json:"fwdeviceid"` Fwdevicename string `json:"fwdevicename"` Fwdevicestate string `json:"fwdevicestate"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Numretries string `json:"numretries"` Physicalnetworkid string `json:"physicalnetworkid"` Privateinterface string `json:"privateinterface"` @@ -500,6 +498,7 @@ func (s *FirewallService) CreateEgressFirewallRule(p *CreateEgressFirewallRulePa } type CreateEgressFirewallRuleResponse struct { + JobID string `json:"jobid"` Cidrlist string `json:"cidrlist"` Destcidrlist string `json:"destcidrlist"` Endport int `json:"endport"` @@ -509,8 +508,6 @@ type CreateEgressFirewallRuleResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Protocol string `json:"protocol"` Startport int `json:"startport"` @@ -686,6 +683,7 @@ func (s *FirewallService) CreateFirewallRule(p *CreateFirewallRuleParams) (*Crea } type CreateFirewallRuleResponse struct { + JobID string `json:"jobid"` Cidrlist string `json:"cidrlist"` Destcidrlist string `json:"destcidrlist"` Endport int `json:"endport"` @@ -695,8 +693,6 @@ type CreateFirewallRuleResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Protocol string `json:"protocol"` Startport int `json:"startport"` @@ -909,13 +905,12 @@ func (s *FirewallService) CreatePortForwardingRule(p *CreatePortForwardingRulePa } type CreatePortForwardingRuleResponse struct { + JobID string `json:"jobid"` Cidrlist string `json:"cidrlist"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Privateendport string `json:"privateendport"` Privateport string `json:"privateport"` @@ -998,9 +993,8 @@ func (s *FirewallService) DeleteEgressFirewallRule(p *DeleteEgressFirewallRulePa } type DeleteEgressFirewallRuleResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1072,9 +1066,8 @@ func (s *FirewallService) DeleteFirewallRule(p *DeleteFirewallRuleParams) (*Dele } type DeleteFirewallRuleResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1146,9 +1139,8 @@ func (s *FirewallService) DeletePaloAltoFirewall(p *DeletePaloAltoFirewallParams } type DeletePaloAltoFirewallResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1220,9 +1212,8 @@ func (s *FirewallService) DeletePortForwardingRule(p *DeletePortForwardingRulePa } type DeletePortForwardingRuleResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1467,8 +1458,6 @@ type EgressFirewallRule struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Protocol string `json:"protocol"` Startport int `json:"startport"` @@ -1717,8 +1706,6 @@ type FirewallRule struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Protocol string `json:"protocol"` Startport int `json:"startport"` @@ -1834,8 +1821,6 @@ type PaloAltoFirewall struct { Fwdevicename string `json:"fwdevicename"` Fwdevicestate string `json:"fwdevicestate"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Numretries string `json:"numretries"` Physicalnetworkid string `json:"physicalnetworkid"` Privateinterface string `json:"privateinterface"` @@ -2086,8 +2071,6 @@ type PortForwardingRule struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Privateendport string `json:"privateendport"` Privateport string `json:"privateport"` @@ -2198,6 +2181,7 @@ func (s *FirewallService) UpdateEgressFirewallRule(p *UpdateEgressFirewallRulePa } type UpdateEgressFirewallRuleResponse struct { + JobID string `json:"jobid"` Cidrlist string `json:"cidrlist"` Destcidrlist string `json:"destcidrlist"` Endport int `json:"endport"` @@ -2207,8 +2191,6 @@ type UpdateEgressFirewallRuleResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Protocol string `json:"protocol"` Startport int `json:"startport"` @@ -2312,6 +2294,7 @@ func (s *FirewallService) UpdateFirewallRule(p *UpdateFirewallRuleParams) (*Upda } type UpdateFirewallRuleResponse struct { + JobID string `json:"jobid"` Cidrlist string `json:"cidrlist"` Destcidrlist string `json:"destcidrlist"` Endport int `json:"endport"` @@ -2321,8 +2304,6 @@ type UpdateFirewallRuleResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Protocol string `json:"protocol"` Startport int `json:"startport"` @@ -2472,13 +2453,12 @@ func (s *FirewallService) UpdatePortForwardingRule(p *UpdatePortForwardingRulePa } type UpdatePortForwardingRuleResponse struct { + JobID string `json:"jobid"` Cidrlist string `json:"cidrlist"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Privateendport string `json:"privateendport"` Privateport string `json:"privateport"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/GuestOSService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/GuestOSService.go index b2cacbc9b..9e6a67236 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/GuestOSService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/GuestOSService.go @@ -131,11 +131,10 @@ func (s *GuestOSService) AddGuestOs(p *AddGuestOsParams) (*AddGuestOsResponse, e } type AddGuestOsResponse struct { + JobID string `json:"jobid"` Description string `json:"description"` Id string `json:"id"` Isuserdefined bool `json:"isuserdefined"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Oscategoryid string `json:"oscategoryid"` } @@ -253,44 +252,16 @@ func (s *GuestOSService) AddGuestOsMapping(p *AddGuestOsMappingParams) (*AddGues } type AddGuestOsMappingResponse struct { + JobID string `json:"jobid"` Hypervisor string `json:"hypervisor"` Hypervisorversion string `json:"hypervisorversion"` Id string `json:"id"` Isuserdefined string `json:"isuserdefined"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Osdisplayname string `json:"osdisplayname"` Osnameforhypervisor string `json:"osnameforhypervisor"` Ostypeid string `json:"ostypeid"` } -func (r *AddGuestOsMappingResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias AddGuestOsMappingResponse - return json.Unmarshal(b, (*alias)(r)) -} - type ListGuestOsMappingParams struct { p map[string]interface{} } @@ -448,40 +419,11 @@ type GuestOsMapping struct { Hypervisorversion string `json:"hypervisorversion"` Id string `json:"id"` Isuserdefined string `json:"isuserdefined"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Osdisplayname string `json:"osdisplayname"` Osnameforhypervisor string `json:"osnameforhypervisor"` Ostypeid string `json:"ostypeid"` } -func (r *GuestOsMapping) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias GuestOsMapping - return json.Unmarshal(b, (*alias)(r)) -} - type ListOsCategoriesParams struct { p map[string]interface{} } @@ -663,10 +605,8 @@ type ListOsCategoriesResponse struct { } type OsCategory struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` + Id string `json:"id"` + Name string `json:"name"` } type ListOsTypesParams struct { @@ -814,8 +754,6 @@ type OsType struct { Description string `json:"description"` Id string `json:"id"` Isuserdefined bool `json:"isuserdefined"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Oscategoryid string `json:"oscategoryid"` } @@ -882,9 +820,8 @@ func (s *GuestOSService) RemoveGuestOs(p *RemoveGuestOsParams) (*RemoveGuestOsRe } type RemoveGuestOsResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -951,9 +888,8 @@ func (s *GuestOSService) RemoveGuestOsMapping(p *RemoveGuestOsMappingParams) (*R } type RemoveGuestOsMappingResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1053,11 +989,10 @@ func (s *GuestOSService) UpdateGuestOs(p *UpdateGuestOsParams) (*UpdateGuestOsRe } type UpdateGuestOsResponse struct { + JobID string `json:"jobid"` Description string `json:"description"` Id string `json:"id"` Isuserdefined bool `json:"isuserdefined"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Oscategoryid string `json:"oscategoryid"` } @@ -1141,40 +1076,12 @@ func (s *GuestOSService) UpdateGuestOsMapping(p *UpdateGuestOsMappingParams) (*U } type UpdateGuestOsMappingResponse struct { + JobID string `json:"jobid"` Hypervisor string `json:"hypervisor"` Hypervisorversion string `json:"hypervisorversion"` Id string `json:"id"` Isuserdefined string `json:"isuserdefined"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Osdisplayname string `json:"osdisplayname"` Osnameforhypervisor string `json:"osnameforhypervisor"` Ostypeid string `json:"ostypeid"` } - -func (r *UpdateGuestOsMappingResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias UpdateGuestOsMappingResponse - return json.Unmarshal(b, (*alias)(r)) -} diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/HostService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/HostService.go index 7ce06f547..a5e6f3590 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/HostService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/HostService.go @@ -216,8 +216,6 @@ type AddBaremetalHostResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Islocalstorageactive bool `json:"islocalstorageactive"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastannotated string `json:"lastannotated"` Lastpinged string `json:"lastpinged"` Managementserverid int64 `json:"managementserverid"` @@ -359,9 +357,8 @@ func (s *HostService) AddGloboDnsHost(p *AddGloboDnsHostParams) (*AddGloboDnsHos } type AddGloboDnsHostResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -546,8 +543,6 @@ type AddHostResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Islocalstorageactive bool `json:"islocalstorageactive"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastannotated string `json:"lastannotated"` Lastpinged string `json:"lastpinged"` Managementserverid int64 `json:"managementserverid"` @@ -650,8 +645,6 @@ func (s *HostService) AddSecondaryStorage(p *AddSecondaryStorageParams) (*AddSec type AddSecondaryStorageResponse struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Protocol string `json:"protocol"` Providername string `json:"providername"` @@ -729,6 +722,7 @@ func (s *HostService) CancelHostMaintenance(p *CancelHostMaintenanceParams) (*Ca } type CancelHostMaintenanceResponse struct { + JobID string `json:"jobid"` Annotation string `json:"annotation"` Averageload int64 `json:"averageload"` Capabilities string `json:"capabilities"` @@ -757,8 +751,6 @@ type CancelHostMaintenanceResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Islocalstorageactive bool `json:"islocalstorageactive"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastannotated string `json:"lastannotated"` Lastpinged string `json:"lastpinged"` Managementserverid int64 `json:"managementserverid"` @@ -892,14 +884,13 @@ func (s *HostService) DedicateHost(p *DedicateHostParams) (*DedicateHostResponse } type DedicateHostResponse struct { + JobID string `json:"jobid"` Accountid string `json:"accountid"` Affinitygroupid string `json:"affinitygroupid"` Domainid string `json:"domainid"` Hostid string `json:"hostid"` Hostname string `json:"hostname"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` } type DeleteHostParams struct { @@ -975,8 +966,6 @@ func (s *HostService) DeleteHost(p *DeleteHostParams) (*DeleteHostResponse, erro type DeleteHostResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -995,14 +984,6 @@ func (r *DeleteHostResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteHostResponse return json.Unmarshal(b, (*alias)(r)) } @@ -1075,14 +1056,13 @@ func (s *HostService) DisableOutOfBandManagementForHost(p *DisableOutOfBandManag } type DisableOutOfBandManagementForHostResponse struct { + JobID string `json:"jobid"` Action string `json:"action"` Address string `json:"address"` Description string `json:"description"` Driver string `json:"driver"` Enabled bool `json:"enabled"` Hostid string `json:"hostid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Password string `json:"password"` Port string `json:"port"` Powerstate string `json:"powerstate"` @@ -1158,14 +1138,13 @@ func (s *HostService) EnableOutOfBandManagementForHost(p *EnableOutOfBandManagem } type EnableOutOfBandManagementForHostResponse struct { + JobID string `json:"jobid"` Action string `json:"action"` Address string `json:"address"` Description string `json:"description"` Driver string `json:"driver"` Enabled bool `json:"enabled"` Hostid string `json:"hostid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Password string `json:"password"` Port string `json:"port"` Powerstate string `json:"powerstate"` @@ -1279,8 +1258,6 @@ type FindHostsForMigrationResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Islocalstorageactive bool `json:"islocalstorageactive"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastpinged string `json:"lastpinged"` Managementserverid int64 `json:"managementserverid"` Memoryallocated string `json:"memoryallocated"` @@ -1431,8 +1408,6 @@ type DedicatedHost struct { Hostid string `json:"hostid"` Hostname string `json:"hostname"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` } type ListHostTagsParams struct { @@ -1547,11 +1522,9 @@ type ListHostTagsResponse struct { } type HostTag struct { - Hostid int64 `json:"hostid"` - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` + Hostid int64 `json:"hostid"` + Id string `json:"id"` + Name string `json:"name"` } type ListHostsParams struct { @@ -1898,8 +1871,6 @@ type Host struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Islocalstorageactive bool `json:"islocalstorageactive"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastannotated string `json:"lastannotated"` Lastpinged string `json:"lastpinged"` Managementserverid int64 `json:"managementserverid"` @@ -2010,6 +1981,7 @@ func (s *HostService) PrepareHostForMaintenance(p *PrepareHostForMaintenancePara } type PrepareHostForMaintenanceResponse struct { + JobID string `json:"jobid"` Annotation string `json:"annotation"` Averageload int64 `json:"averageload"` Capabilities string `json:"capabilities"` @@ -2038,8 +2010,6 @@ type PrepareHostForMaintenanceResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Islocalstorageactive bool `json:"islocalstorageactive"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastannotated string `json:"lastannotated"` Lastpinged string `json:"lastpinged"` Managementserverid int64 `json:"managementserverid"` @@ -2150,6 +2120,7 @@ func (s *HostService) ReconnectHost(p *ReconnectHostParams) (*ReconnectHostRespo } type ReconnectHostResponse struct { + JobID string `json:"jobid"` Annotation string `json:"annotation"` Averageload int64 `json:"averageload"` Capabilities string `json:"capabilities"` @@ -2178,8 +2149,6 @@ type ReconnectHostResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Islocalstorageactive bool `json:"islocalstorageactive"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastannotated string `json:"lastannotated"` Lastpinged string `json:"lastpinged"` Managementserverid int64 `json:"managementserverid"` @@ -2285,9 +2254,8 @@ func (s *HostService) ReleaseDedicatedHost(p *ReleaseDedicatedHostParams) (*Rele } type ReleaseDedicatedHostResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -2354,9 +2322,8 @@ func (s *HostService) ReleaseHostReservation(p *ReleaseHostReservationParams) (* } type ReleaseHostReservationResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -2492,8 +2459,6 @@ type UpdateHostResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Islocalstorageactive bool `json:"islocalstorageactive"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastannotated string `json:"lastannotated"` Lastpinged string `json:"lastpinged"` Managementserverid int64 `json:"managementserverid"` @@ -2631,8 +2596,6 @@ func (s *HostService) UpdateHostPassword(p *UpdateHostPasswordParams) (*UpdateHo type UpdateHostPasswordResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -2651,14 +2614,6 @@ func (r *UpdateHostPasswordResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias UpdateHostPasswordResponse return json.Unmarshal(b, (*alias)(r)) } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/HypervisorService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/HypervisorService.go index 5085dbd84..c457b3092 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/HypervisorService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/HypervisorService.go @@ -158,8 +158,6 @@ type HypervisorCapability struct { Hypervisor string `json:"hypervisor"` Hypervisorversion string `json:"hypervisorversion"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxdatavolumeslimit int `json:"maxdatavolumeslimit"` Maxguestslimit int64 `json:"maxguestslimit"` Maxhostspercluster int `json:"maxhostspercluster"` @@ -219,9 +217,7 @@ type ListHypervisorsResponse struct { } type Hypervisor struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` + Name string `json:"name"` } type UpdateHypervisorCapabilitiesParams struct { @@ -298,8 +294,6 @@ type UpdateHypervisorCapabilitiesResponse struct { Hypervisor string `json:"hypervisor"` Hypervisorversion string `json:"hypervisorversion"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxdatavolumeslimit int `json:"maxdatavolumeslimit"` Maxguestslimit int64 `json:"maxguestslimit"` Maxhostspercluster int `json:"maxhostspercluster"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ISOService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ISOService.go index 9c1c4f862..96db4bf5f 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ISOService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ISOService.go @@ -104,6 +104,7 @@ func (s *ISOService) AttachIso(p *AttachIsoParams) (*AttachIsoResponse, error) { } type AttachIsoResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []AttachIsoResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -135,8 +136,6 @@ type AttachIsoResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -146,7 +145,7 @@ type AttachIsoResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -160,7 +159,6 @@ type AttachIsoResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -213,33 +211,6 @@ type AttachIsoResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *AttachIsoResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias AttachIsoResponse - return json.Unmarshal(b, (*alias)(r)) -} - type CopyIsoParams struct { p map[string]interface{} } @@ -342,6 +313,7 @@ func (s *ISOService) CopyIso(p *CopyIsoParams) (*CopyIsoResponse, error) { } type CopyIsoResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Accountid string `json:"accountid"` Bits int `json:"bits"` @@ -365,8 +337,6 @@ type CopyIsoResponse struct { Isfeatured bool `json:"isfeatured"` Ispublic bool `json:"ispublic"` Isready bool `json:"isready"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Ostypeid string `json:"ostypeid"` Ostypename string `json:"ostypename"` @@ -376,45 +346,16 @@ type CopyIsoResponse struct { Project string `json:"project"` Projectid string `json:"projectid"` Removed string `json:"removed"` - Requireshvm bool `json:"requireshvm"` Size int64 `json:"size"` Sourcetemplateid string `json:"sourcetemplateid"` Sshkeyenabled bool `json:"sshkeyenabled"` Status string `json:"status"` - Tags []Tags `json:"tags"` Templatetag string `json:"templatetag"` Templatetype string `json:"templatetype"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } -func (r *CopyIsoResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias CopyIsoResponse - return json.Unmarshal(b, (*alias)(r)) -} - type DeleteIsoParams struct { p map[string]interface{} } @@ -489,9 +430,8 @@ func (s *ISOService) DeleteIso(p *DeleteIsoParams) (*DeleteIsoResponse, error) { } type DeleteIsoResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -563,6 +503,7 @@ func (s *ISOService) DetachIso(p *DetachIsoParams) (*DetachIsoResponse, error) { } type DetachIsoResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []DetachIsoResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -594,8 +535,6 @@ type DetachIsoResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -605,7 +544,7 @@ type DetachIsoResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -619,7 +558,6 @@ type DetachIsoResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -672,33 +610,6 @@ type DetachIsoResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *DetachIsoResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias DetachIsoResponse - return json.Unmarshal(b, (*alias)(r)) -} - type ExtractIsoParams struct { p map[string]interface{} } @@ -801,13 +712,12 @@ func (s *ISOService) ExtractIso(p *ExtractIsoParams) (*ExtractIsoResponse, error } type ExtractIsoResponse struct { + JobID string `json:"jobid"` Accountid string `json:"accountid"` Created string `json:"created"` ExtractId string `json:"extractId"` ExtractMode string `json:"extractMode"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Resultstring string `json:"resultstring"` State string `json:"state"` @@ -909,8 +819,6 @@ type IsoPermission struct { Domainid string `json:"domainid"` Id string `json:"id"` Ispublic bool `json:"ispublic"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Projectids []string `json:"projectids"` } @@ -1274,8 +1182,6 @@ type Iso struct { Isfeatured bool `json:"isfeatured"` Ispublic bool `json:"ispublic"` Isready bool `json:"isready"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Ostypeid string `json:"ostypeid"` Ostypename string `json:"ostypename"` @@ -1285,45 +1191,16 @@ type Iso struct { Project string `json:"project"` Projectid string `json:"projectid"` Removed string `json:"removed"` - Requireshvm bool `json:"requireshvm"` Size int64 `json:"size"` Sourcetemplateid string `json:"sourcetemplateid"` Sshkeyenabled bool `json:"sshkeyenabled"` Status string `json:"status"` - Tags []Tags `json:"tags"` Templatetag string `json:"templatetag"` Templatetype string `json:"templatetype"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } -func (r *Iso) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias Iso - return json.Unmarshal(b, (*alias)(r)) -} - type RegisterIsoParams struct { p map[string]interface{} } @@ -1378,10 +1255,6 @@ func (p *RegisterIsoParams) toURLValues() url.Values { if v, found := p.p["ostypeid"]; found { u.Set("ostypeid", v.(string)) } - if v, found := p.p["passwordenabled"]; found { - vv := strconv.FormatBool(v.(bool)) - u.Set("passwordenabled", vv) - } if v, found := p.p["projectid"]; found { u.Set("projectid", v.(string)) } @@ -1498,14 +1371,6 @@ func (p *RegisterIsoParams) SetOstypeid(v string) { return } -func (p *RegisterIsoParams) SetPasswordenabled(v bool) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["passwordenabled"] = v - return -} - func (p *RegisterIsoParams) SetProjectid(v string) { if p.p == nil { p.p = make(map[string]interface{}) @@ -1581,8 +1446,6 @@ type RegisterIsoResponse struct { Isfeatured bool `json:"isfeatured"` Ispublic bool `json:"ispublic"` Isready bool `json:"isready"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Ostypeid string `json:"ostypeid"` Ostypename string `json:"ostypename"` @@ -1592,45 +1455,16 @@ type RegisterIsoResponse struct { Project string `json:"project"` Projectid string `json:"projectid"` Removed string `json:"removed"` - Requireshvm bool `json:"requireshvm"` Size int64 `json:"size"` Sourcetemplateid string `json:"sourcetemplateid"` Sshkeyenabled bool `json:"sshkeyenabled"` Status string `json:"status"` - Tags []Tags `json:"tags"` Templatetag string `json:"templatetag"` Templatetype string `json:"templatetype"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } -func (r *RegisterIsoResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias RegisterIsoResponse - return json.Unmarshal(b, (*alias)(r)) -} - type UpdateIsoParams struct { p map[string]interface{} } @@ -1690,10 +1524,6 @@ func (p *UpdateIsoParams) toURLValues() url.Values { vv := strconv.Itoa(v.(int)) u.Set("sortkey", vv) } - if v, found := p.p["sshkeyenabled"]; found { - vv := strconv.FormatBool(v.(bool)) - u.Set("sshkeyenabled", vv) - } return u } @@ -1801,14 +1631,6 @@ func (p *UpdateIsoParams) SetSortkey(v int) { return } -func (p *UpdateIsoParams) SetSshkeyenabled(v bool) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["sshkeyenabled"] = v - return -} - // You should always use this function to get a new UpdateIsoParams instance, // as then you are sure you have configured all required params func (s *ISOService) NewUpdateIsoParams(id string) *UpdateIsoParams { @@ -1857,8 +1679,6 @@ type UpdateIsoResponse struct { Isfeatured bool `json:"isfeatured"` Ispublic bool `json:"ispublic"` Isready bool `json:"isready"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Ostypeid string `json:"ostypeid"` Ostypename string `json:"ostypename"` @@ -1868,45 +1688,16 @@ type UpdateIsoResponse struct { Project string `json:"project"` Projectid string `json:"projectid"` Removed string `json:"removed"` - Requireshvm bool `json:"requireshvm"` Size int64 `json:"size"` Sourcetemplateid string `json:"sourcetemplateid"` Sshkeyenabled bool `json:"sshkeyenabled"` Status string `json:"status"` - Tags []Tags `json:"tags"` Templatetag string `json:"templatetag"` Templatetype string `json:"templatetype"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } -func (r *UpdateIsoResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias UpdateIsoResponse - return json.Unmarshal(b, (*alias)(r)) -} - type UpdateIsoPermissionsParams struct { p map[string]interface{} } @@ -2027,8 +1818,6 @@ func (s *ISOService) UpdateIsoPermissions(p *UpdateIsoPermissionsParams) (*Updat type UpdateIsoPermissionsResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -2047,14 +1836,6 @@ func (r *UpdateIsoPermissionsResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias UpdateIsoPermissionsResponse return json.Unmarshal(b, (*alias)(r)) } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ImageStoreService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ImageStoreService.go index 62faac1e0..1f7b7fb76 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ImageStoreService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ImageStoreService.go @@ -121,8 +121,6 @@ func (s *ImageStoreService) AddImageStore(p *AddImageStoreParams) (*AddImageStor type AddImageStoreResponse struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Protocol string `json:"protocol"` Providername string `json:"providername"` @@ -300,8 +298,6 @@ func (s *ImageStoreService) AddImageStoreS3(p *AddImageStoreS3Params) (*AddImage type AddImageStoreS3Response struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Protocol string `json:"protocol"` Providername string `json:"providername"` @@ -408,8 +404,6 @@ func (s *ImageStoreService) CreateSecondaryStagingStore(p *CreateSecondaryStagin type CreateSecondaryStagingStoreResponse struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Protocol string `json:"protocol"` Providername string `json:"providername"` @@ -468,8 +462,6 @@ func (s *ImageStoreService) DeleteImageStore(p *DeleteImageStoreParams) (*Delete type DeleteImageStoreResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -488,14 +480,6 @@ func (r *DeleteImageStoreResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteImageStoreResponse return json.Unmarshal(b, (*alias)(r)) } @@ -549,8 +533,6 @@ func (s *ImageStoreService) DeleteSecondaryStagingStore(p *DeleteSecondaryStagin type DeleteSecondaryStagingStoreResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -569,14 +551,6 @@ func (r *DeleteSecondaryStagingStoreResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteSecondaryStagingStoreResponse return json.Unmarshal(b, (*alias)(r)) } @@ -796,8 +770,6 @@ type ListImageStoresResponse struct { type ImageStore struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Protocol string `json:"protocol"` Providername string `json:"providername"` @@ -1022,8 +994,6 @@ type ListSecondaryStagingStoresResponse struct { type SecondaryStagingStore struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Protocol string `json:"protocol"` Providername string `json:"providername"` @@ -1119,8 +1089,6 @@ func (s *ImageStoreService) UpdateCloudToUseObjectStore(p *UpdateCloudToUseObjec type UpdateCloudToUseObjectStoreResponse struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Protocol string `json:"protocol"` Providername string `json:"providername"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/InternalLBService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/InternalLBService.go index d68dde6e0..64df1cd22 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/InternalLBService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/InternalLBService.go @@ -105,11 +105,10 @@ func (s *InternalLBService) ConfigureInternalLoadBalancerElement(p *ConfigureInt } type InternalLoadBalancerElementResponse struct { - Enabled bool `json:"enabled"` - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Nspid string `json:"nspid"` + JobID string `json:"jobid"` + Enabled bool `json:"enabled"` + Id string `json:"id"` + Nspid string `json:"nspid"` } type CreateInternalLoadBalancerElementParams struct { @@ -180,11 +179,10 @@ func (s *InternalLBService) CreateInternalLoadBalancerElement(p *CreateInternalL } type CreateInternalLoadBalancerElementResponse struct { - Enabled bool `json:"enabled"` - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Nspid string `json:"nspid"` + JobID string `json:"jobid"` + Enabled bool `json:"enabled"` + Id string `json:"id"` + Nspid string `json:"nspid"` } type ListInternalLoadBalancerElementsParams struct { @@ -330,11 +328,9 @@ type ListInternalLoadBalancerElementsResponse struct { } type InternalLoadBalancerElement struct { - Enabled bool `json:"enabled"` - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Nspid string `json:"nspid"` + Enabled bool `json:"enabled"` + Id string `json:"id"` + Nspid string `json:"nspid"` } type ListInternalLoadBalancerVMsParams struct { @@ -672,8 +668,6 @@ type InternalLoadBalancerVM struct { Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` Isredundantrouter bool `json:"isredundantrouter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Linklocalip string `json:"linklocalip"` Linklocalmacaddress string `json:"linklocalmacaddress"` Linklocalnetmask string `json:"linklocalnetmask"` @@ -771,6 +765,7 @@ func (s *InternalLBService) StartInternalLoadBalancerVM(p *StartInternalLoadBala } type StartInternalLoadBalancerVMResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Created string `json:"created"` Dns1 string `json:"dns1"` @@ -790,8 +785,6 @@ type StartInternalLoadBalancerVMResponse struct { Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` Isredundantrouter bool `json:"isredundantrouter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Linklocalip string `json:"linklocalip"` Linklocalmacaddress string `json:"linklocalmacaddress"` Linklocalnetmask string `json:"linklocalnetmask"` @@ -901,6 +894,7 @@ func (s *InternalLBService) StopInternalLoadBalancerVM(p *StopInternalLoadBalanc } type StopInternalLoadBalancerVMResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Created string `json:"created"` Dns1 string `json:"dns1"` @@ -920,8 +914,6 @@ type StopInternalLoadBalancerVMResponse struct { Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` Isredundantrouter bool `json:"isredundantrouter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Linklocalip string `json:"linklocalip"` Linklocalmacaddress string `json:"linklocalmacaddress"` Linklocalnetmask string `json:"linklocalnetmask"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/LDAPService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/LDAPService.go index 1ebc024ae..baff7900d 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/LDAPService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/LDAPService.go @@ -95,11 +95,9 @@ func (s *LDAPService) AddLdapConfiguration(p *AddLdapConfigurationParams) (*AddL } type AddLdapConfigurationResponse struct { - Domainid string `json:"domainid"` - Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Port int `json:"port"` + Domainid string `json:"domainid"` + Hostname string `json:"hostname"` + Port int `json:"port"` } type DeleteLdapConfigurationParams struct { @@ -173,11 +171,9 @@ func (s *LDAPService) DeleteLdapConfiguration(p *DeleteLdapConfigurationParams) } type DeleteLdapConfigurationResponse struct { - Domainid string `json:"domainid"` - Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Port int `json:"port"` + Domainid string `json:"domainid"` + Hostname string `json:"hostname"` + Port int `json:"port"` } type ImportLdapUsersParams struct { @@ -337,8 +333,6 @@ type ImportLdapUsersResponse struct { Domain string `json:"domain"` Email string `json:"email"` Firstname string `json:"firstname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Principal string `json:"principal"` Username string `json:"username"` @@ -496,8 +490,6 @@ type LdapConfigResponse struct { Binddn string `json:"binddn"` Bindpass string `json:"bindpass"` Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Port string `json:"port"` Queryfilter string `json:"queryfilter"` Searchbase string `json:"searchbase"` @@ -672,8 +664,6 @@ type LdapCreateAccountResponse struct { Iptotal int64 `json:"iptotal"` Iscleanuprequired bool `json:"iscleanuprequired"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -780,8 +770,6 @@ type LdapRemoveResponse struct { Binddn string `json:"binddn"` Bindpass string `json:"bindpass"` Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Port string `json:"port"` Queryfilter string `json:"queryfilter"` Searchbase string `json:"searchbase"` @@ -897,8 +885,6 @@ type LinkDomainToLdapResponse struct { Accountid string `json:"accountid"` Accounttype int `json:"accounttype"` Domainid string `json:"domainid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Ldapdomain string `json:"ldapdomain"` Name string `json:"name"` Type string `json:"type"` @@ -1014,11 +1000,9 @@ type ListLdapConfigurationsResponse struct { } type LdapConfiguration struct { - Domainid string `json:"domainid"` - Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Port int `json:"port"` + Domainid string `json:"domainid"` + Hostname string `json:"hostname"` + Port int `json:"port"` } type ListLdapUsersParams struct { @@ -1111,8 +1095,6 @@ type LdapUser struct { Domain string `json:"domain"` Email string `json:"email"` Firstname string `json:"firstname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Principal string `json:"principal"` Username string `json:"username"` @@ -1204,8 +1186,6 @@ type SearchLdapResponse struct { Domain string `json:"domain"` Email string `json:"email"` Firstname string `json:"firstname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Principal string `json:"principal"` Username string `json:"username"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/LimitService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/LimitService.go index 7f8c99fff..23512715b 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/LimitService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/LimitService.go @@ -63,8 +63,6 @@ type GetApiLimitResponse struct { ApiAllowed int `json:"apiAllowed"` ApiIssued int `json:"apiIssued"` ExpireAfter int64 `json:"expireAfter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` } type ListResourceLimitsParams struct { @@ -238,8 +236,6 @@ type ResourceLimit struct { Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Max int64 `json:"max"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -299,8 +295,6 @@ type ResetApiLimitResponse struct { ApiAllowed int `json:"apiAllowed"` ApiIssued int `json:"apiIssued"` ExpireAfter int64 `json:"expireAfter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` } type UpdateResourceCountParams struct { @@ -388,8 +382,6 @@ type UpdateResourceCountResponse struct { Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` Resourcecount int64 `json:"resourcecount"` @@ -494,8 +486,6 @@ type UpdateResourceLimitResponse struct { Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Max int64 `json:"max"` Project string `json:"project"` Projectid string `json:"projectid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/LoadBalancerService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/LoadBalancerService.go index 08cf53bb1..e74e3a3d4 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/LoadBalancerService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/LoadBalancerService.go @@ -186,13 +186,12 @@ func (s *LoadBalancerService) AddNetscalerLoadBalancer(p *AddNetscalerLoadBalanc } type AddNetscalerLoadBalancerResponse struct { + JobID string `json:"jobid"` Gslbprovider bool `json:"gslbprovider"` Gslbproviderprivateip string `json:"gslbproviderprivateip"` Gslbproviderpublicip string `json:"gslbproviderpublicip"` Ipaddress string `json:"ipaddress"` Isexclusivegslbprovider bool `json:"isexclusivegslbprovider"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbdevicecapacity int64 `json:"lbdevicecapacity"` Lbdevicededicated bool `json:"lbdevicededicated"` Lbdeviceid string `json:"lbdeviceid"` @@ -280,9 +279,8 @@ func (s *LoadBalancerService) AssignCertToLoadBalancer(p *AssignCertToLoadBalanc } type AssignCertToLoadBalancerResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -378,9 +376,8 @@ func (s *LoadBalancerService) AssignToGlobalLoadBalancerRule(p *AssignToGlobalLo } type AssignToGlobalLoadBalancerRuleResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -475,9 +472,8 @@ func (s *LoadBalancerService) AssignToLoadBalancerRule(p *AssignToLoadBalancerRu } type AssignToLoadBalancerRuleResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -597,13 +593,12 @@ func (s *LoadBalancerService) ConfigureNetscalerLoadBalancer(p *ConfigureNetscal } type NetscalerLoadBalancerResponse struct { + JobID string `json:"jobid"` Gslbprovider bool `json:"gslbprovider"` Gslbproviderprivateip string `json:"gslbproviderprivateip"` Gslbproviderpublicip string `json:"gslbproviderpublicip"` Ipaddress string `json:"ipaddress"` Isexclusivegslbprovider bool `json:"isexclusivegslbprovider"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbdevicecapacity int64 `json:"lbdevicecapacity"` Lbdevicededicated bool `json:"lbdevicededicated"` Lbdeviceid string `json:"lbdeviceid"` @@ -776,6 +771,7 @@ func (s *LoadBalancerService) CreateGlobalLoadBalancerRule(p *CreateGlobalLoadBa } type CreateGlobalLoadBalancerRuleResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Description string `json:"description"` Domain string `json:"domain"` @@ -785,8 +781,6 @@ type CreateGlobalLoadBalancerRuleResponse struct { Gslbservicetype string `json:"gslbservicetype"` Gslbstickysessionmethodname string `json:"gslbstickysessionmethodname"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Loadbalancerrule []CreateGlobalLoadBalancerRuleResponseLoadbalancerrule `json:"loadbalancerrule"` Name string `json:"name"` Project string `json:"project"` @@ -968,12 +962,11 @@ func (s *LoadBalancerService) CreateLBHealthCheckPolicy(p *CreateLBHealthCheckPo } type CreateLBHealthCheckPolicyResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Healthcheckpolicy []CreateLBHealthCheckPolicyResponseHealthcheckpolicy `json:"healthcheckpolicy"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Zoneid string `json:"zoneid"` } @@ -1121,12 +1114,11 @@ func (s *LoadBalancerService) CreateLBStickinessPolicy(p *CreateLBStickinessPoli } type CreateLBStickinessPolicyResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Description string `json:"description"` Domain string `json:"domain"` Domainid string `json:"domainid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Name string `json:"name"` State string `json:"state"` @@ -1320,6 +1312,7 @@ func (s *LoadBalancerService) CreateLoadBalancer(p *CreateLoadBalancerParams) (* } type CreateLoadBalancerResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Algorithm string `json:"algorithm"` Description string `json:"description"` @@ -1327,8 +1320,6 @@ type CreateLoadBalancerResponse struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Loadbalancerinstance []CreateLoadBalancerResponseLoadbalancerinstance `json:"loadbalancerinstance"` Loadbalancerrule []CreateLoadBalancerResponseLoadbalancerrule `json:"loadbalancerrule"` Name string `json:"name"` @@ -1572,6 +1563,7 @@ func (s *LoadBalancerService) CreateLoadBalancerRule(p *CreateLoadBalancerRulePa } type CreateLoadBalancerRuleResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Algorithm string `json:"algorithm"` Cidrlist string `json:"cidrlist"` @@ -1580,8 +1572,6 @@ type CreateLoadBalancerRuleResponse struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Networkid string `json:"networkid"` Privateport string `json:"privateport"` @@ -1660,9 +1650,8 @@ func (s *LoadBalancerService) DeleteGlobalLoadBalancerRule(p *DeleteGlobalLoadBa } type DeleteGlobalLoadBalancerRuleResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1729,9 +1718,8 @@ func (s *LoadBalancerService) DeleteLBHealthCheckPolicy(p *DeleteLBHealthCheckPo } type DeleteLBHealthCheckPolicyResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1798,9 +1786,8 @@ func (s *LoadBalancerService) DeleteLBStickinessPolicy(p *DeleteLBStickinessPoli } type DeleteLBStickinessPolicyResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1867,9 +1854,8 @@ func (s *LoadBalancerService) DeleteLoadBalancer(p *DeleteLoadBalancerParams) (* } type DeleteLoadBalancerResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1936,9 +1922,8 @@ func (s *LoadBalancerService) DeleteLoadBalancerRule(p *DeleteLoadBalancerRulePa } type DeleteLoadBalancerRuleResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -2005,9 +1990,8 @@ func (s *LoadBalancerService) DeleteNetscalerLoadBalancer(p *DeleteNetscalerLoad } type DeleteNetscalerLoadBalancerResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -2060,8 +2044,6 @@ func (s *LoadBalancerService) DeleteSslCert(p *DeleteSslCertParams) (*DeleteSslC type DeleteSslCertResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -2080,14 +2062,6 @@ func (r *DeleteSslCertResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteSslCertResponse return json.Unmarshal(b, (*alias)(r)) } @@ -2356,8 +2330,6 @@ type GlobalLoadBalancerRule struct { Gslbservicetype string `json:"gslbservicetype"` Gslbstickysessionmethodname string `json:"gslbstickysessionmethodname"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Loadbalancerrule []GlobalLoadBalancerRuleLoadbalancerrule `json:"loadbalancerrule"` Name string `json:"name"` Project string `json:"project"` @@ -2536,8 +2508,6 @@ type LBHealthCheckPolicy struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Healthcheckpolicy []LBHealthCheckPolicyHealthcheckpolicy `json:"healthcheckpolicy"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Zoneid string `json:"zoneid"` } @@ -2701,8 +2671,6 @@ type LBStickinessPolicy struct { Description string `json:"description"` Domain string `json:"domain"` Domainid string `json:"domainid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Name string `json:"name"` State string `json:"state"` @@ -2866,8 +2834,6 @@ type ListLoadBalancerRuleInstancesResponse struct { } type LoadBalancerRuleInstance struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbvmipaddresses []string `json:"lbvmipaddresses"` Loadbalancerruleinstance *VirtualMachine `json:"loadbalancerruleinstance"` } @@ -3190,8 +3156,6 @@ type LoadBalancerRule struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Networkid string `json:"networkid"` Privateport string `json:"privateport"` @@ -3524,8 +3488,6 @@ type LoadBalancer struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Loadbalancerinstance []LoadBalancerLoadbalancerinstance `json:"loadbalancerinstance"` Loadbalancerrule []LoadBalancerLoadbalancerrule `json:"loadbalancerrule"` Name string `json:"name"` @@ -3653,8 +3615,6 @@ type NetscalerLoadBalancer struct { Gslbproviderpublicip string `json:"gslbproviderpublicip"` Ipaddress string `json:"ipaddress"` Isexclusivegslbprovider bool `json:"isexclusivegslbprovider"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbdevicecapacity int64 `json:"lbdevicecapacity"` Lbdevicededicated bool `json:"lbdevicededicated"` Lbdeviceid string `json:"lbdeviceid"` @@ -3759,8 +3719,6 @@ type SslCert struct { Domainid string `json:"domainid"` Fingerprint string `json:"fingerprint"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Loadbalancerrulelist []string `json:"loadbalancerrulelist"` Name string `json:"name"` Project string `json:"project"` @@ -3830,9 +3788,8 @@ func (s *LoadBalancerService) RemoveCertFromLoadBalancer(p *RemoveCertFromLoadBa } type RemoveCertFromLoadBalancerResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -3912,9 +3869,8 @@ func (s *LoadBalancerService) RemoveFromGlobalLoadBalancerRule(p *RemoveFromGlob } type RemoveFromGlobalLoadBalancerRuleResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -4009,9 +3965,8 @@ func (s *LoadBalancerService) RemoveFromLoadBalancerRule(p *RemoveFromLoadBalanc } type RemoveFromLoadBalancerRuleResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -4116,6 +4071,7 @@ func (s *LoadBalancerService) UpdateGlobalLoadBalancerRule(p *UpdateGlobalLoadBa } type UpdateGlobalLoadBalancerRuleResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Description string `json:"description"` Domain string `json:"domain"` @@ -4125,8 +4081,6 @@ type UpdateGlobalLoadBalancerRuleResponse struct { Gslbservicetype string `json:"gslbservicetype"` Gslbstickysessionmethodname string `json:"gslbstickysessionmethodname"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Loadbalancerrule []UpdateGlobalLoadBalancerRuleResponseLoadbalancerrule `json:"loadbalancerrule"` Name string `json:"name"` Project string `json:"project"` @@ -4249,12 +4203,11 @@ func (s *LoadBalancerService) UpdateLBHealthCheckPolicy(p *UpdateLBHealthCheckPo } type UpdateLBHealthCheckPolicyResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Healthcheckpolicy []UpdateLBHealthCheckPolicyResponseHealthcheckpolicy `json:"healthcheckpolicy"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Zoneid string `json:"zoneid"` } @@ -4362,12 +4315,11 @@ func (s *LoadBalancerService) UpdateLBStickinessPolicy(p *UpdateLBStickinessPoli } type UpdateLBStickinessPolicyResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Description string `json:"description"` Domain string `json:"domain"` Domainid string `json:"domainid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lbruleid string `json:"lbruleid"` Name string `json:"name"` State string `json:"state"` @@ -4476,6 +4428,7 @@ func (s *LoadBalancerService) UpdateLoadBalancer(p *UpdateLoadBalancerParams) (* } type UpdateLoadBalancerResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Algorithm string `json:"algorithm"` Description string `json:"description"` @@ -4483,8 +4436,6 @@ type UpdateLoadBalancerResponse struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Loadbalancerinstance []UpdateLoadBalancerResponseLoadbalancerinstance `json:"loadbalancerinstance"` Loadbalancerrule []UpdateLoadBalancerResponseLoadbalancerrule `json:"loadbalancerrule"` Name string `json:"name"` @@ -4644,6 +4595,7 @@ func (s *LoadBalancerService) UpdateLoadBalancerRule(p *UpdateLoadBalancerRulePa } type UpdateLoadBalancerRuleResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Algorithm string `json:"algorithm"` Cidrlist string `json:"cidrlist"` @@ -4652,8 +4604,6 @@ type UpdateLoadBalancerRuleResponse struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Networkid string `json:"networkid"` Privateport string `json:"privateport"` @@ -4803,8 +4753,6 @@ type UploadSslCertResponse struct { Domainid string `json:"domainid"` Fingerprint string `json:"fingerprint"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Loadbalancerrulelist []string `json:"loadbalancerrulelist"` Name string `json:"name"` Project string `json:"project"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NATService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NATService.go index f8c56c645..714dfa590 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NATService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NATService.go @@ -153,13 +153,12 @@ func (s *NATService) CreateIpForwardingRule(p *CreateIpForwardingRuleParams) (*C } type CreateIpForwardingRuleResponse struct { + JobID string `json:"jobid"` Cidrlist string `json:"cidrlist"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Privateendport string `json:"privateendport"` Privateport string `json:"privateport"` @@ -237,9 +236,8 @@ func (s *NATService) DeleteIpForwardingRule(p *DeleteIpForwardingRuleParams) (*D } type DeleteIpForwardingRuleResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -306,9 +304,8 @@ func (s *NATService) DisableStaticNat(p *DisableStaticNatParams) (*DisableStatic } type DisableStaticNatResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -395,8 +392,6 @@ func (s *NATService) EnableStaticNat(p *EnableStaticNatParams) (*EnableStaticNat type EnableStaticNatResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -415,14 +410,6 @@ func (r *EnableStaticNatResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias EnableStaticNatResponse return json.Unmarshal(b, (*alias)(r)) } @@ -631,8 +618,6 @@ type IpForwardingRule struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` Ipaddressid string `json:"ipaddressid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Privateendport string `json:"privateendport"` Privateport string `json:"privateport"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkACLService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkACLService.go index 73fc718b8..6d0e1547b 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkACLService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkACLService.go @@ -69,9 +69,6 @@ func (p *CreateNetworkACLParams) toURLValues() url.Values { if v, found := p.p["protocol"]; found { u.Set("protocol", v.(string)) } - if v, found := p.p["reason"]; found { - u.Set("reason", v.(string)) - } if v, found := p.p["startport"]; found { vv := strconv.Itoa(v.(int)) u.Set("startport", vv) @@ -162,14 +159,6 @@ func (p *CreateNetworkACLParams) SetProtocol(v string) { return } -func (p *CreateNetworkACLParams) SetReason(v string) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["reason"] = v - return -} - func (p *CreateNetworkACLParams) SetStartport(v int) { if p.p == nil { p.p = make(map[string]interface{}) @@ -231,6 +220,7 @@ func (s *NetworkACLService) CreateNetworkACL(p *CreateNetworkACLParams) (*Create } type CreateNetworkACLResponse struct { + JobID string `json:"jobid"` Aclid string `json:"aclid"` Action string `json:"action"` Cidrlist string `json:"cidrlist"` @@ -239,11 +229,8 @@ type CreateNetworkACLResponse struct { Icmpcode int `json:"icmpcode"` Icmptype int `json:"icmptype"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Number int `json:"number"` Protocol string `json:"protocol"` - Reason string `json:"reason"` Startport string `json:"startport"` State string `json:"state"` Tags []Tags `json:"tags"` @@ -353,11 +340,10 @@ func (s *NetworkACLService) CreateNetworkACLList(p *CreateNetworkACLListParams) } type CreateNetworkACLListResponse struct { + JobID string `json:"jobid"` Description string `json:"description"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Vpcid string `json:"vpcid"` } @@ -425,9 +411,8 @@ func (s *NetworkACLService) DeleteNetworkACL(p *DeleteNetworkACLParams) (*Delete } type DeleteNetworkACLResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -494,9 +479,8 @@ func (s *NetworkACLService) DeleteNetworkACLList(p *DeleteNetworkACLListParams) } type DeleteNetworkACLListResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -775,8 +759,6 @@ type NetworkACLList struct { Description string `json:"description"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Vpcid string `json:"vpcid"` } @@ -1049,11 +1031,8 @@ type NetworkACL struct { Icmpcode int `json:"icmpcode"` Icmptype int `json:"icmptype"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Number int `json:"number"` Protocol string `json:"protocol"` - Reason string `json:"reason"` Startport string `json:"startport"` State string `json:"state"` Tags []Tags `json:"tags"` @@ -1145,9 +1124,8 @@ func (s *NetworkACLService) ReplaceNetworkACLList(p *ReplaceNetworkACLListParams } type ReplaceNetworkACLListResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1193,16 +1171,9 @@ func (p *UpdateNetworkACLItemParams) toURLValues() url.Values { vv := strconv.Itoa(v.(int)) u.Set("number", vv) } - if v, found := p.p["partialupgrade"]; found { - vv := strconv.FormatBool(v.(bool)) - u.Set("partialupgrade", vv) - } if v, found := p.p["protocol"]; found { u.Set("protocol", v.(string)) } - if v, found := p.p["reason"]; found { - u.Set("reason", v.(string)) - } if v, found := p.p["startport"]; found { vv := strconv.Itoa(v.(int)) u.Set("startport", vv) @@ -1285,14 +1256,6 @@ func (p *UpdateNetworkACLItemParams) SetNumber(v int) { return } -func (p *UpdateNetworkACLItemParams) SetPartialupgrade(v bool) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["partialupgrade"] = v - return -} - func (p *UpdateNetworkACLItemParams) SetProtocol(v string) { if p.p == nil { p.p = make(map[string]interface{}) @@ -1301,14 +1264,6 @@ func (p *UpdateNetworkACLItemParams) SetProtocol(v string) { return } -func (p *UpdateNetworkACLItemParams) SetReason(v string) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["reason"] = v - return -} - func (p *UpdateNetworkACLItemParams) SetStartport(v int) { if p.p == nil { p.p = make(map[string]interface{}) @@ -1370,6 +1325,7 @@ func (s *NetworkACLService) UpdateNetworkACLItem(p *UpdateNetworkACLItemParams) } type UpdateNetworkACLItemResponse struct { + JobID string `json:"jobid"` Aclid string `json:"aclid"` Action string `json:"action"` Cidrlist string `json:"cidrlist"` @@ -1378,11 +1334,8 @@ type UpdateNetworkACLItemResponse struct { Icmpcode int `json:"icmpcode"` Icmptype int `json:"icmptype"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Number int `json:"number"` Protocol string `json:"protocol"` - Reason string `json:"reason"` Startport string `json:"startport"` State string `json:"state"` Tags []Tags `json:"tags"` @@ -1401,9 +1354,6 @@ func (p *UpdateNetworkACLListParams) toURLValues() url.Values { if v, found := p.p["customid"]; found { u.Set("customid", v.(string)) } - if v, found := p.p["description"]; found { - u.Set("description", v.(string)) - } if v, found := p.p["fordisplay"]; found { vv := strconv.FormatBool(v.(bool)) u.Set("fordisplay", vv) @@ -1411,9 +1361,6 @@ func (p *UpdateNetworkACLListParams) toURLValues() url.Values { if v, found := p.p["id"]; found { u.Set("id", v.(string)) } - if v, found := p.p["name"]; found { - u.Set("name", v.(string)) - } return u } @@ -1425,14 +1372,6 @@ func (p *UpdateNetworkACLListParams) SetCustomid(v string) { return } -func (p *UpdateNetworkACLListParams) SetDescription(v string) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["description"] = v - return -} - func (p *UpdateNetworkACLListParams) SetFordisplay(v bool) { if p.p == nil { p.p = make(map[string]interface{}) @@ -1449,14 +1388,6 @@ func (p *UpdateNetworkACLListParams) SetId(v string) { return } -func (p *UpdateNetworkACLListParams) SetName(v string) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["name"] = v - return -} - // You should always use this function to get a new UpdateNetworkACLListParams instance, // as then you are sure you have configured all required params func (s *NetworkACLService) NewUpdateNetworkACLListParams(id string) *UpdateNetworkACLListParams { @@ -1497,8 +1428,7 @@ func (s *NetworkACLService) UpdateNetworkACLList(p *UpdateNetworkACLListParams) } type UpdateNetworkACLListResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkDeviceService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkDeviceService.go index edb6adfe5..cea5a8acf 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkDeviceService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkDeviceService.go @@ -86,9 +86,7 @@ func (s *NetworkDeviceService) AddNetworkDevice(p *AddNetworkDeviceParams) (*Add } type AddNetworkDeviceResponse struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Id string `json:"id"` } type DeleteNetworkDeviceParams struct { @@ -140,8 +138,6 @@ func (s *NetworkDeviceService) DeleteNetworkDevice(p *DeleteNetworkDeviceParams) type DeleteNetworkDeviceResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -160,14 +156,6 @@ func (r *DeleteNetworkDeviceResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteNetworkDeviceResponse return json.Unmarshal(b, (*alias)(r)) } @@ -275,7 +263,5 @@ type ListNetworkDeviceResponse struct { } type NetworkDevice struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Id string `json:"id"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkOfferingService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkOfferingService.go index e4f7404d2..51ed208dd 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkOfferingService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkOfferingService.go @@ -324,8 +324,6 @@ type CreateNetworkOfferingResponse struct { Id string `json:"id"` Isdefault bool `json:"isdefault"` Ispersistent bool `json:"ispersistent"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxconnections int `json:"maxconnections"` Name string `json:"name"` Networkrate int `json:"networkrate"` @@ -411,8 +409,6 @@ func (s *NetworkOfferingService) DeleteNetworkOffering(p *DeleteNetworkOfferingP type DeleteNetworkOfferingResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -431,14 +427,6 @@ func (r *DeleteNetworkOfferingResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteNetworkOfferingResponse return json.Unmarshal(b, (*alias)(r)) } @@ -807,8 +795,6 @@ type NetworkOffering struct { Id string `json:"id"` Isdefault bool `json:"isdefault"` Ispersistent bool `json:"ispersistent"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxconnections int `json:"maxconnections"` Name string `json:"name"` Networkrate int `json:"networkrate"` @@ -994,8 +980,6 @@ type UpdateNetworkOfferingResponse struct { Id string `json:"id"` Isdefault bool `json:"isdefault"` Ispersistent bool `json:"ispersistent"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxconnections int `json:"maxconnections"` Name string `json:"name"` Networkrate int `json:"networkrate"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkService.go index 628aa1f82..aef044e78 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NetworkService.go @@ -127,11 +127,10 @@ func (s *NetworkService) AddNetworkServiceProvider(p *AddNetworkServiceProviderP } type AddNetworkServiceProviderResponse struct { + JobID string `json:"jobid"` Canenableindividualservice bool `json:"canenableindividualservice"` Destinationphysicalnetworkid string `json:"destinationphysicalnetworkid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Physicalnetworkid string `json:"physicalnetworkid"` Servicelist []string `json:"servicelist"` @@ -242,9 +241,8 @@ func (s *NetworkService) AddOpenDaylightController(p *AddOpenDaylightControllerP } type AddOpenDaylightControllerResponse struct { - Id string `json:"id"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Id string `json:"id"` Name string `json:"name"` Physicalnetworkid string `json:"physicalnetworkid"` Url string `json:"url"` @@ -605,8 +603,6 @@ type CreateNetworkResponse struct { Isdefault bool `json:"isdefault"` Ispersistent bool `json:"ispersistent"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Netmask string `json:"netmask"` Networkcidr string `json:"networkcidr"` @@ -808,12 +804,11 @@ func (s *NetworkService) CreatePhysicalNetwork(p *CreatePhysicalNetworkParams) ( } type CreatePhysicalNetworkResponse struct { + JobID string `json:"jobid"` Broadcastdomainrange string `json:"broadcastdomainrange"` Domainid string `json:"domainid"` Id string `json:"id"` Isolationmethods string `json:"isolationmethods"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Networkspeed string `json:"networkspeed"` State string `json:"state"` @@ -983,13 +978,12 @@ func (s *NetworkService) CreateServiceInstance(p *CreateServiceInstanceParams) ( } type CreateServiceInstanceResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Displayname string `json:"displayname"` Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -1122,11 +1116,10 @@ func (s *NetworkService) CreateStorageNetworkIpRange(p *CreateStorageNetworkIpRa } type CreateStorageNetworkIpRangeResponse struct { + JobID string `json:"jobid"` Endip string `json:"endip"` Gateway string `json:"gateway"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Netmask string `json:"netmask"` Networkid string `json:"networkid"` Podid string `json:"podid"` @@ -1229,8 +1222,6 @@ type DedicatePublicIpRangeResponse struct { Id string `json:"id"` Ip6cidr string `json:"ip6cidr"` Ip6gateway string `json:"ip6gateway"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Netmask string `json:"netmask"` Networkid string `json:"networkid"` Physicalnetworkid string `json:"physicalnetworkid"` @@ -1319,9 +1310,8 @@ func (s *NetworkService) DeleteNetwork(p *DeleteNetworkParams) (*DeleteNetworkRe } type DeleteNetworkResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1388,9 +1378,8 @@ func (s *NetworkService) DeleteNetworkServiceProvider(p *DeleteNetworkServicePro } type DeleteNetworkServiceProviderResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1462,9 +1451,8 @@ func (s *NetworkService) DeleteOpenDaylightController(p *DeleteOpenDaylightContr } type DeleteOpenDaylightControllerResponse struct { - Id string `json:"id"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Id string `json:"id"` Name string `json:"name"` Physicalnetworkid string `json:"physicalnetworkid"` Url string `json:"url"` @@ -1534,9 +1522,8 @@ func (s *NetworkService) DeletePhysicalNetwork(p *DeletePhysicalNetworkParams) ( } type DeletePhysicalNetworkResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1603,9 +1590,8 @@ func (s *NetworkService) DeleteStorageNetworkIpRange(p *DeleteStorageNetworkIpRa } type DeleteStorageNetworkIpRangeResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1755,8 +1741,6 @@ type NetscalerLoadBalancerNetwork struct { Isdefault bool `json:"isdefault"` Ispersistent bool `json:"ispersistent"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Netmask string `json:"netmask"` Networkcidr string `json:"networkcidr"` @@ -1886,9 +1870,7 @@ type ListNetworkIsolationMethodsResponse struct { } type NetworkIsolationMethod struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` + Name string `json:"name"` } type ListNetworkServiceProvidersParams struct { @@ -2039,8 +2021,6 @@ type NetworkServiceProvider struct { Canenableindividualservice bool `json:"canenableindividualservice"` Destinationphysicalnetworkid string `json:"destinationphysicalnetworkid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Physicalnetworkid string `json:"physicalnetworkid"` Servicelist []string `json:"servicelist"` @@ -2461,8 +2441,6 @@ type Network struct { Isdefault bool `json:"isdefault"` Ispersistent bool `json:"ispersistent"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Netmask string `json:"netmask"` Networkcidr string `json:"networkcidr"` @@ -2662,8 +2640,6 @@ type NiciraNvpDeviceNetwork struct { Isdefault bool `json:"isdefault"` Ispersistent bool `json:"ispersistent"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Netmask string `json:"netmask"` Networkcidr string `json:"networkcidr"` @@ -2814,8 +2790,6 @@ type ListOpenDaylightControllersResponse struct { type OpenDaylightController struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Physicalnetworkid string `json:"physicalnetworkid"` Url string `json:"url"` @@ -2968,8 +2942,6 @@ type PaloAltoFirewallNetwork struct { Isdefault bool `json:"isdefault"` Ispersistent bool `json:"ispersistent"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Netmask string `json:"netmask"` Networkcidr string `json:"networkcidr"` @@ -3219,8 +3191,6 @@ type PhysicalNetwork struct { Domainid string `json:"domainid"` Id string `json:"id"` Isolationmethods string `json:"isolationmethods"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Networkspeed string `json:"networkspeed"` State string `json:"state"` @@ -3374,8 +3344,6 @@ type StorageNetworkIpRange struct { Endip string `json:"endip"` Gateway string `json:"gateway"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Netmask string `json:"netmask"` Networkid string `json:"networkid"` Podid string `json:"podid"` @@ -3483,8 +3451,6 @@ type ListSupportedNetworkServicesResponse struct { type SupportedNetworkService struct { Capability []SupportedNetworkServiceCapability `json:"capability"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Provider []SupportedNetworkServiceProvider `json:"provider"` } @@ -3554,8 +3520,6 @@ func (s *NetworkService) ReleasePublicIpRange(p *ReleasePublicIpRangeParams) (*R type ReleasePublicIpRangeResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -3574,14 +3538,6 @@ func (r *ReleasePublicIpRangeResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias ReleasePublicIpRangeResponse return json.Unmarshal(b, (*alias)(r)) } @@ -3678,6 +3634,7 @@ func (s *NetworkService) RestartNetwork(p *RestartNetworkParams) (*RestartNetwor } type RestartNetworkResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Allocated string `json:"allocated"` Associatednetworkid string `json:"associatednetworkid"` @@ -3692,8 +3649,6 @@ type RestartNetworkResponse struct { Issourcenat bool `json:"issourcenat"` Isstaticnat bool `json:"isstaticnat"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Physicalnetworkid string `json:"physicalnetworkid"` Project string `json:"project"` @@ -3894,6 +3849,7 @@ func (s *NetworkService) UpdateNetwork(p *UpdateNetworkParams) (*UpdateNetworkRe } type UpdateNetworkResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Aclid string `json:"aclid"` Acltype string `json:"acltype"` @@ -3915,8 +3871,6 @@ type UpdateNetworkResponse struct { Isdefault bool `json:"isdefault"` Ispersistent bool `json:"ispersistent"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Netmask string `json:"netmask"` Networkcidr string `json:"networkcidr"` @@ -4061,11 +4015,10 @@ func (s *NetworkService) UpdateNetworkServiceProvider(p *UpdateNetworkServicePro } type UpdateNetworkServiceProviderResponse struct { + JobID string `json:"jobid"` Canenableindividualservice bool `json:"canenableindividualservice"` Destinationphysicalnetworkid string `json:"destinationphysicalnetworkid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Physicalnetworkid string `json:"physicalnetworkid"` Servicelist []string `json:"servicelist"` @@ -4185,12 +4138,11 @@ func (s *NetworkService) UpdatePhysicalNetwork(p *UpdatePhysicalNetworkParams) ( } type UpdatePhysicalNetworkResponse struct { + JobID string `json:"jobid"` Broadcastdomainrange string `json:"broadcastdomainrange"` Domainid string `json:"domainid"` Id string `json:"id"` Isolationmethods string `json:"isolationmethods"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Networkspeed string `json:"networkspeed"` State string `json:"state"` @@ -4312,11 +4264,10 @@ func (s *NetworkService) UpdateStorageNetworkIpRange(p *UpdateStorageNetworkIpRa } type UpdateStorageNetworkIpRangeResponse struct { + JobID string `json:"jobid"` Endip string `json:"endip"` Gateway string `json:"gateway"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Netmask string `json:"netmask"` Networkid string `json:"networkid"` Podid string `json:"podid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NicService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NicService.go index 722278a52..525f1b99b 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NicService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NicService.go @@ -101,10 +101,9 @@ func (s *NicService) AddIpToNic(p *AddIpToNicParams) (*AddIpToNicResponse, error } type AddIpToNicResponse struct { + JobID string `json:"jobid"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Networkid string `json:"networkid"` Nicid string `json:"nicid"` Secondaryip []struct { @@ -247,8 +246,6 @@ type Nic struct { Ipaddress string `json:"ipaddress"` Isdefault bool `json:"isdefault"` Isolationuri string `json:"isolationuri"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Macaddress string `json:"macaddress"` Netmask string `json:"netmask"` Networkid string `json:"networkid"` @@ -327,9 +324,8 @@ func (s *NicService) RemoveIpFromNic(p *RemoveIpFromNicParams) (*RemoveIpFromNic } type RemoveIpFromNicResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -412,6 +408,7 @@ func (s *NicService) UpdateVmNicIp(p *UpdateVmNicIpParams) (*UpdateVmNicIpRespon } type UpdateVmNicIpResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []UpdateVmNicIpResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -443,8 +440,6 @@ type UpdateVmNicIpResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -454,7 +449,7 @@ type UpdateVmNicIpResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -468,7 +463,6 @@ type UpdateVmNicIpResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -520,30 +514,3 @@ type UpdateVmNicIpResponseAffinitygroup struct { Type string `json:"type"` VirtualmachineIds []string `json:"virtualmachineIds"` } - -func (r *UpdateVmNicIpResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias UpdateVmNicIpResponse - return json.Unmarshal(b, (*alias)(r)) -} diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NiciraNVPService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NiciraNVPService.go index 2caa0d3f8..ec90845bc 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NiciraNVPService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NiciraNVPService.go @@ -160,9 +160,8 @@ func (s *NiciraNVPService) AddNiciraNvpDevice(p *AddNiciraNvpDeviceParams) (*Add } type AddNiciraNvpDeviceResponse struct { - Hostname string `json:"hostname"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Hostname string `json:"hostname"` L2gatewayserviceuuid string `json:"l2gatewayserviceuuid"` L3gatewayserviceuuid string `json:"l3gatewayserviceuuid"` Niciradevicename string `json:"niciradevicename"` @@ -235,9 +234,8 @@ func (s *NiciraNVPService) DeleteNiciraNvpDevice(p *DeleteNiciraNvpDeviceParams) } type DeleteNiciraNvpDeviceResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -340,8 +338,6 @@ type ListNiciraNvpDevicesResponse struct { type NiciraNvpDevice struct { Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` L2gatewayserviceuuid string `json:"l2gatewayserviceuuid"` L3gatewayserviceuuid string `json:"l3gatewayserviceuuid"` Niciradevicename string `json:"niciradevicename"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NuageVSPService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NuageVSPService.go index 975fd295d..31f4df2ad 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/NuageVSPService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/NuageVSPService.go @@ -174,11 +174,10 @@ func (s *NuageVSPService) AddNuageVspDevice(p *AddNuageVspDeviceParams) (*AddNua } type AddNuageVspDeviceResponse struct { + JobID string `json:"jobid"` Apiversion string `json:"apiversion"` Cmsid string `json:"cmsid"` Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Nuagedevicename string `json:"nuagedevicename"` Physicalnetworkid string `json:"physicalnetworkid"` Port int `json:"port"` @@ -251,9 +250,8 @@ func (s *NuageVSPService) DeleteNuageVspDevice(p *DeleteNuageVspDeviceParams) (* } type DeleteNuageVspDeviceResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -358,8 +356,6 @@ type NuageVspDevice struct { Apiversion string `json:"apiversion"` Cmsid string `json:"cmsid"` Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Nuagedevicename string `json:"nuagedevicename"` Physicalnetworkid string `json:"physicalnetworkid"` Port int `json:"port"` @@ -517,11 +513,10 @@ func (s *NuageVSPService) UpdateNuageVspDevice(p *UpdateNuageVspDeviceParams) (* } type UpdateNuageVspDeviceResponse struct { + JobID string `json:"jobid"` Apiversion string `json:"apiversion"` Cmsid string `json:"cmsid"` Hostname string `json:"hostname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Nuagedevicename string `json:"nuagedevicename"` Physicalnetworkid string `json:"physicalnetworkid"` Port int `json:"port"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/OutofbandManagementService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/OutofbandManagementService.go index 72af8ad95..eb12c45e1 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/OutofbandManagementService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/OutofbandManagementService.go @@ -101,14 +101,13 @@ func (s *OutofbandManagementService) ChangeOutOfBandManagementPassword(p *Change } type ChangeOutOfBandManagementPasswordResponse struct { + JobID string `json:"jobid"` Action string `json:"action"` Address string `json:"address"` Description string `json:"description"` Driver string `json:"driver"` Enabled bool `json:"enabled"` Hostid string `json:"hostid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Password string `json:"password"` Port string `json:"port"` Powerstate string `json:"powerstate"` @@ -230,8 +229,6 @@ type OutOfBandManagementResponse struct { Driver string `json:"driver"` Enabled bool `json:"enabled"` Hostid string `json:"hostid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Password string `json:"password"` Port string `json:"port"` Powerstate string `json:"powerstate"` @@ -331,14 +328,13 @@ func (s *OutofbandManagementService) IssueOutOfBandManagementPowerAction(p *Issu } type IssueOutOfBandManagementPowerActionResponse struct { + JobID string `json:"jobid"` Action string `json:"action"` Address string `json:"address"` Description string `json:"description"` Driver string `json:"driver"` Enabled bool `json:"enabled"` Hostid string `json:"hostid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Password string `json:"password"` Port string `json:"port"` Powerstate string `json:"powerstate"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/OvsElementService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/OvsElementService.go index 5181adc5c..cd5b22e1c 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/OvsElementService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/OvsElementService.go @@ -105,13 +105,12 @@ func (s *OvsElementService) ConfigureOvsElement(p *ConfigureOvsElementParams) (* } type OvsElementResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Enabled bool `json:"enabled"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Nspid string `json:"nspid"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -265,8 +264,6 @@ type OvsElement struct { Domainid string `json:"domainid"` Enabled bool `json:"enabled"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Nspid string `json:"nspid"` Project string `json:"project"` Projectid string `json:"projectid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/PodService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/PodService.go index c51139a11..377e2618e 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/PodService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/PodService.go @@ -148,8 +148,6 @@ type CreatePodResponse struct { Forsystemvms []string `json:"forsystemvms"` Gateway string `json:"gateway"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Netmask string `json:"netmask"` Startip []string `json:"startip"` @@ -264,12 +262,11 @@ func (s *PodService) DedicatePod(p *DedicatePodParams) (*DedicatePodResponse, er } type DedicatePodResponse struct { + JobID string `json:"jobid"` Accountid string `json:"accountid"` Affinitygroupid string `json:"affinitygroupid"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Podid string `json:"podid"` Podname string `json:"podname"` } @@ -323,8 +320,6 @@ func (s *PodService) DeletePod(p *DeletePodParams) (*DeletePodResponse, error) { type DeletePodResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -343,14 +338,6 @@ func (r *DeletePodResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeletePodResponse return json.Unmarshal(b, (*alias)(r)) } @@ -479,8 +466,6 @@ type DedicatedPod struct { Affinitygroupid string `json:"affinitygroupid"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Podid string `json:"podid"` Podname string `json:"podname"` } @@ -706,8 +691,6 @@ type Pod struct { Forsystemvms []string `json:"forsystemvms"` Gateway string `json:"gateway"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Netmask string `json:"netmask"` Startip []string `json:"startip"` @@ -794,9 +777,8 @@ func (s *PodService) ReleaseDedicatedPod(p *ReleaseDedicatedPodParams) (*Release } type ReleaseDedicatedPodResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -920,8 +902,6 @@ type UpdatePodResponse struct { Forsystemvms []string `json:"forsystemvms"` Gateway string `json:"gateway"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Netmask string `json:"netmask"` Startip []string `json:"startip"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/PoolService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/PoolService.go index 047f766d3..b235a2821 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/PoolService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/PoolService.go @@ -224,8 +224,6 @@ type CreateStoragePoolResponse struct { Hypervisor string `json:"hypervisor"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Overprovisionfactor string `json:"overprovisionfactor"` Path string `json:"path"` @@ -303,8 +301,6 @@ func (s *PoolService) DeleteStoragePool(p *DeleteStoragePoolParams) (*DeleteStor type DeleteStoragePoolResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -323,14 +319,6 @@ func (r *DeleteStoragePoolResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteStoragePoolResponse return json.Unmarshal(b, (*alias)(r)) } @@ -429,8 +417,6 @@ type FindStoragePoolsForMigrationResponse struct { Hypervisor string `json:"hypervisor"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Overprovisionfactor string `json:"overprovisionfactor"` Path string `json:"path"` @@ -705,8 +691,6 @@ type StoragePool struct { Hypervisor string `json:"hypervisor"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Overprovisionfactor string `json:"overprovisionfactor"` Path string `json:"path"` @@ -830,8 +814,6 @@ type UpdateStoragePoolResponse struct { Hypervisor string `json:"hypervisor"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Overprovisionfactor string `json:"overprovisionfactor"` Path string `json:"path"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/PortableIPService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/PortableIPService.go index c4f5214ce..6a9ddf782 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/PortableIPService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/PortableIPService.go @@ -152,11 +152,10 @@ func (s *PortableIPService) CreatePortableIpRange(p *CreatePortableIpRangeParams } type CreatePortableIpRangeResponse struct { + JobID string `json:"jobid"` Endip string `json:"endip"` Gateway string `json:"gateway"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Netmask string `json:"netmask"` Portableipaddress []CreatePortableIpRangeResponsePortableipaddress `json:"portableipaddress"` Regionid int `json:"regionid"` @@ -240,9 +239,8 @@ func (s *PortableIPService) DeletePortableIpRange(p *DeletePortableIpRangeParams } type DeletePortableIpRangeResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -381,8 +379,6 @@ type PortableIpRange struct { Endip string `json:"endip"` Gateway string `json:"gateway"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Netmask string `json:"netmask"` Portableipaddress []PortableIpRangePortableipaddress `json:"portableipaddress"` Regionid int `json:"regionid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ProjectService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ProjectService.go index 1c666ad24..de767a106 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ProjectService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ProjectService.go @@ -92,6 +92,7 @@ func (s *ProjectService) ActivateProject(p *ActivateProjectParams) (*ActivatePro } type ActivateProjectResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cpuavailable string `json:"cpuavailable"` Cpulimit string `json:"cpulimit"` @@ -103,8 +104,6 @@ type ActivateProjectResponse struct { Ipavailable string `json:"ipavailable"` Iplimit string `json:"iplimit"` Iptotal int64 `json:"iptotal"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -242,6 +241,7 @@ func (s *ProjectService) CreateProject(p *CreateProjectParams) (*CreateProjectRe } type CreateProjectResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cpuavailable string `json:"cpuavailable"` Cpulimit string `json:"cpulimit"` @@ -253,8 +253,6 @@ type CreateProjectResponse struct { Ipavailable string `json:"ipavailable"` Iplimit string `json:"iplimit"` Iptotal int64 `json:"iptotal"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -353,9 +351,8 @@ func (s *ProjectService) DeleteProject(p *DeleteProjectParams) (*DeleteProjectRe } type DeleteProjectResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -422,9 +419,8 @@ func (s *ProjectService) DeleteProjectInvitation(p *DeleteProjectInvitationParam } type DeleteProjectInvitationResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -633,8 +629,6 @@ type ProjectInvitation struct { Domainid string `json:"domainid"` Email string `json:"email"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` State string `json:"state"` @@ -916,8 +910,6 @@ type Project struct { Ipavailable string `json:"ipavailable"` Iplimit string `json:"iplimit"` Iptotal int64 `json:"iptotal"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -1021,6 +1013,7 @@ func (s *ProjectService) SuspendProject(p *SuspendProjectParams) (*SuspendProjec } type SuspendProjectResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cpuavailable string `json:"cpuavailable"` Cpulimit string `json:"cpulimit"` @@ -1032,8 +1025,6 @@ type SuspendProjectResponse struct { Ipavailable string `json:"ipavailable"` Iplimit string `json:"iplimit"` Iptotal int64 `json:"iptotal"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -1159,6 +1150,7 @@ func (s *ProjectService) UpdateProject(p *UpdateProjectParams) (*UpdateProjectRe } type UpdateProjectResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cpuavailable string `json:"cpuavailable"` Cpulimit string `json:"cpulimit"` @@ -1170,8 +1162,6 @@ type UpdateProjectResponse struct { Ipavailable string `json:"ipavailable"` Iplimit string `json:"iplimit"` Iptotal int64 `json:"iptotal"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memoryavailable string `json:"memoryavailable"` Memorylimit string `json:"memorylimit"` Memorytotal int64 `json:"memorytotal"` @@ -1304,8 +1294,7 @@ func (s *ProjectService) UpdateProjectInvitation(p *UpdateProjectInvitationParam } type UpdateProjectInvitationResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/QuotaService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/QuotaService.go index 048afc521..2e2f26ac7 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/QuotaService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/QuotaService.go @@ -57,7 +57,5 @@ func (s *QuotaService) QuotaIsEnabled(p *QuotaIsEnabledParams) (*QuotaIsEnabledR } type QuotaIsEnabledResponse struct { - Isenabled bool `json:"isenabled"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Isenabled bool `json:"isenabled"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/RegionService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/RegionService.go index 92d833873..244a8fa0c 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/RegionService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/RegionService.go @@ -98,8 +98,6 @@ type AddRegionResponse struct { Endpoint string `json:"endpoint"` Gslbserviceenabled bool `json:"gslbserviceenabled"` Id int `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Portableipserviceenabled bool `json:"portableipserviceenabled"` } @@ -206,8 +204,6 @@ type Region struct { Endpoint string `json:"endpoint"` Gslbserviceenabled bool `json:"gslbserviceenabled"` Id int `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Portableipserviceenabled bool `json:"portableipserviceenabled"` } @@ -262,8 +258,6 @@ func (s *RegionService) RemoveRegion(p *RemoveRegionParams) (*RemoveRegionRespon type RemoveRegionResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -282,14 +276,6 @@ func (r *RemoveRegionResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias RemoveRegionResponse return json.Unmarshal(b, (*alias)(r)) } @@ -368,8 +354,6 @@ type UpdateRegionResponse struct { Endpoint string `json:"endpoint"` Gslbserviceenabled bool `json:"gslbserviceenabled"` Id int `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Portableipserviceenabled bool `json:"portableipserviceenabled"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ResourcemetadataService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ResourcemetadataService.go index 822208e4f..6eef886fa 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ResourcemetadataService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ResourcemetadataService.go @@ -126,9 +126,8 @@ func (s *ResourcemetadataService) AddResourceDetail(p *AddResourceDetailParams) } type AddResourceDetailResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -180,8 +179,6 @@ func (s *ResourcemetadataService) GetVolumeSnapshotDetails(p *GetVolumeSnapshotD } type GetVolumeSnapshotDetailsResponse struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` VolumeiScsiName string `json:"volumeiScsiName"` } @@ -379,8 +376,6 @@ type ResourceDetail struct { Customer string `json:"customer"` Domain string `json:"domain"` Domainid string `json:"domainid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Key string `json:"key"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -475,8 +470,7 @@ func (s *ResourcemetadataService) RemoveResourceDetail(p *RemoveResourceDetailPa } type RemoveResourceDetailResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ResourcetagsService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ResourcetagsService.go index 9d7dc15ed..e49d26563 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ResourcetagsService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ResourcetagsService.go @@ -128,9 +128,8 @@ func (s *ResourcetagsService) CreateTags(p *CreateTagsParams) (*CreateTagsRespon } type CreateTagsResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -226,9 +225,8 @@ func (s *ResourcetagsService) DeleteTags(p *DeleteTagsParams) (*DeleteTagsRespon } type DeleteTagsResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -344,11 +342,9 @@ type ListStorageTagsResponse struct { } type StorageTag struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` - Poolid int64 `json:"poolid"` + Id string `json:"id"` + Name string `json:"name"` + Poolid int64 `json:"poolid"` } type ListTagsParams struct { @@ -543,8 +539,6 @@ type Tag struct { Customer string `json:"customer"` Domain string `json:"domain"` Domainid string `json:"domainid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Key string `json:"key"` Project string `json:"project"` Projectid string `json:"projectid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/RoleService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/RoleService.go index f40354d05..f348b1d6f 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/RoleService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/RoleService.go @@ -20,7 +20,6 @@ import ( "encoding/json" "fmt" "net/url" - "strconv" "strings" ) @@ -97,8 +96,6 @@ func (s *RoleService) CreateRole(p *CreateRoleParams) (*CreateRoleResponse, erro type CreateRoleResponse struct { Description string `json:"description"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Type string `json:"type"` } @@ -188,8 +185,6 @@ func (s *RoleService) CreateRolePermission(p *CreateRolePermissionParams) (*Crea type CreateRolePermissionResponse struct { Description string `json:"description"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Permission string `json:"permission"` Roleid string `json:"roleid"` Rolename string `json:"rolename"` @@ -245,8 +240,6 @@ func (s *RoleService) DeleteRole(p *DeleteRoleParams) (*DeleteRoleResponse, erro type DeleteRoleResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -265,14 +258,6 @@ func (r *DeleteRoleResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteRoleResponse return json.Unmarshal(b, (*alias)(r)) } @@ -326,8 +311,6 @@ func (s *RoleService) DeleteRolePermission(p *DeleteRolePermissionParams) (*Dele type DeleteRolePermissionResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -346,14 +329,6 @@ func (r *DeleteRolePermissionResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteRolePermissionResponse return json.Unmarshal(b, (*alias)(r)) } @@ -412,8 +387,6 @@ type ListRolePermissionsResponse struct { type RolePermission struct { Description string `json:"description"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Permission string `json:"permission"` Roleid string `json:"roleid"` Rolename string `json:"rolename"` @@ -579,8 +552,6 @@ type ListRolesResponse struct { type Role struct { Description string `json:"description"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Type string `json:"type"` } @@ -668,8 +639,6 @@ func (s *RoleService) UpdateRole(p *UpdateRoleParams) (*UpdateRoleResponse, erro type UpdateRoleResponse struct { Description string `json:"description"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Type string `json:"type"` } @@ -757,8 +726,6 @@ func (s *RoleService) UpdateRolePermission(p *UpdateRolePermissionParams) (*Upda type UpdateRolePermissionResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -777,14 +744,6 @@ func (r *UpdateRolePermissionResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias UpdateRolePermissionResponse return json.Unmarshal(b, (*alias)(r)) } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/RouterService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/RouterService.go index 963403bf6..bf37d75e5 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/RouterService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/RouterService.go @@ -103,8 +103,6 @@ type ChangeServiceForRouterResponse struct { Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` Isredundantrouter bool `json:"isredundantrouter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Linklocalip string `json:"linklocalip"` Linklocalmacaddress string `json:"linklocalmacaddress"` Linklocalnetmask string `json:"linklocalnetmask"` @@ -215,13 +213,12 @@ func (s *RouterService) ConfigureVirtualRouterElement(p *ConfigureVirtualRouterE } type VirtualRouterElementResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Enabled bool `json:"enabled"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Nspid string `json:"nspid"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -306,13 +303,12 @@ func (s *RouterService) CreateVirtualRouterElement(p *CreateVirtualRouterElement } type CreateVirtualRouterElementResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Enabled bool `json:"enabled"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Nspid string `json:"nspid"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -386,6 +382,7 @@ func (s *RouterService) DestroyRouter(p *DestroyRouterParams) (*DestroyRouterRes } type DestroyRouterResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Created string `json:"created"` Dns1 string `json:"dns1"` @@ -405,8 +402,6 @@ type DestroyRouterResponse struct { Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` Isredundantrouter bool `json:"isredundantrouter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Linklocalip string `json:"linklocalip"` Linklocalmacaddress string `json:"linklocalmacaddress"` Linklocalnetmask string `json:"linklocalnetmask"` @@ -793,8 +788,6 @@ type Router struct { Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` Isredundantrouter bool `json:"isredundantrouter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Linklocalip string `json:"linklocalip"` Linklocalmacaddress string `json:"linklocalmacaddress"` Linklocalnetmask string `json:"linklocalnetmask"` @@ -972,8 +965,6 @@ type VirtualRouterElement struct { Domainid string `json:"domainid"` Enabled bool `json:"enabled"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Nspid string `json:"nspid"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -1047,6 +1038,7 @@ func (s *RouterService) RebootRouter(p *RebootRouterParams) (*RebootRouterRespon } type RebootRouterResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Created string `json:"created"` Dns1 string `json:"dns1"` @@ -1066,8 +1058,6 @@ type RebootRouterResponse struct { Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` Isredundantrouter bool `json:"isredundantrouter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Linklocalip string `json:"linklocalip"` Linklocalmacaddress string `json:"linklocalmacaddress"` Linklocalnetmask string `json:"linklocalnetmask"` @@ -1165,6 +1155,7 @@ func (s *RouterService) StartRouter(p *StartRouterParams) (*StartRouterResponse, } type StartRouterResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Created string `json:"created"` Dns1 string `json:"dns1"` @@ -1184,8 +1175,6 @@ type StartRouterResponse struct { Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` Isredundantrouter bool `json:"isredundantrouter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Linklocalip string `json:"linklocalip"` Linklocalmacaddress string `json:"linklocalmacaddress"` Linklocalnetmask string `json:"linklocalnetmask"` @@ -1295,6 +1284,7 @@ func (s *RouterService) StopRouter(p *StopRouterParams) (*StopRouterResponse, er } type StopRouterResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Created string `json:"created"` Dns1 string `json:"dns1"` @@ -1314,8 +1304,6 @@ type StopRouterResponse struct { Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` Isredundantrouter bool `json:"isredundantrouter"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Linklocalip string `json:"linklocalip"` Linklocalmacaddress string `json:"linklocalmacaddress"` Linklocalnetmask string `json:"linklocalnetmask"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/SSHService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/SSHService.go index a69f7f2f0..f1f4ab48f 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/SSHService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/SSHService.go @@ -107,14 +107,7 @@ func (s *SSHService) CreateSSHKeyPair(p *CreateSSHKeyPairParams) (*CreateSSHKeyP } type CreateSSHKeyPairResponse struct { - Account string `json:"account"` - Domain string `json:"domain"` - Domainid string `json:"domainid"` - Fingerprint string `json:"fingerprint"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` - Privatekey string `json:"privatekey"` + Privatekey string `json:"privatekey"` } type DeleteSSHKeyPairParams struct { @@ -199,8 +192,6 @@ func (s *SSHService) DeleteSSHKeyPair(p *DeleteSSHKeyPairParams) (*DeleteSSHKeyP type DeleteSSHKeyPairResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -219,14 +210,6 @@ func (r *DeleteSSHKeyPairResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteSSHKeyPairResponse return json.Unmarshal(b, (*alias)(r)) } @@ -390,8 +373,6 @@ type SSHKeyPair struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Fingerprint string `json:"fingerprint"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` } @@ -496,8 +477,6 @@ type RegisterSSHKeyPairResponse struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Fingerprint string `json:"fingerprint"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` } @@ -614,6 +593,7 @@ func (s *SSHService) ResetSSHKeyForVirtualMachine(p *ResetSSHKeyForVirtualMachin } type ResetSSHKeyForVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []ResetSSHKeyForVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -645,8 +625,6 @@ type ResetSSHKeyForVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -656,7 +634,7 @@ type ResetSSHKeyForVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -670,7 +648,6 @@ type ResetSSHKeyForVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -722,30 +699,3 @@ type ResetSSHKeyForVirtualMachineResponseAffinitygroup struct { Type string `json:"type"` VirtualmachineIds []string `json:"virtualmachineIds"` } - -func (r *ResetSSHKeyForVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias ResetSSHKeyForVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/SecurityGroupService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/SecurityGroupService.go index 245f26311..125750474 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/SecurityGroupService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/SecurityGroupService.go @@ -259,13 +259,12 @@ func (s *SecurityGroupService) AuthorizeSecurityGroupEgress(p *AuthorizeSecurity } type AuthorizeSecurityGroupEgressResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidr string `json:"cidr"` Endport int `json:"endport"` Icmpcode int `json:"icmpcode"` Icmptype int `json:"icmptype"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Protocol string `json:"protocol"` Ruleid string `json:"ruleid"` Securitygroupname string `json:"securitygroupname"` @@ -476,13 +475,12 @@ func (s *SecurityGroupService) AuthorizeSecurityGroupIngress(p *AuthorizeSecurit } type AuthorizeSecurityGroupIngressResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidr string `json:"cidr"` Endport int `json:"endport"` Icmpcode int `json:"icmpcode"` Icmptype int `json:"icmptype"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Protocol string `json:"protocol"` Ruleid string `json:"ruleid"` Securitygroupname string `json:"securitygroupname"` @@ -593,8 +591,6 @@ type CreateSecurityGroupResponse struct { Egressrule []CreateSecurityGroupResponseRule `json:"egressrule"` Id string `json:"id"` Ingressrule []CreateSecurityGroupResponseRule `json:"ingressrule"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -708,8 +704,6 @@ func (s *SecurityGroupService) DeleteSecurityGroup(p *DeleteSecurityGroupParams) type DeleteSecurityGroupResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -728,14 +722,6 @@ func (r *DeleteSecurityGroupResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteSecurityGroupResponse return json.Unmarshal(b, (*alias)(r)) } @@ -1012,8 +998,6 @@ type SecurityGroup struct { Egressrule []SecurityGroupRule `json:"egressrule"` Id string `json:"id"` Ingressrule []SecurityGroupRule `json:"ingressrule"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -1098,9 +1082,8 @@ func (s *SecurityGroupService) RevokeSecurityGroupEgress(p *RevokeSecurityGroupE } type RevokeSecurityGroupEgressResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1167,8 +1150,7 @@ func (s *SecurityGroupService) RevokeSecurityGroupIngress(p *RevokeSecurityGroup } type RevokeSecurityGroupIngressResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ServiceOfferingService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ServiceOfferingService.go index ea9b4d964..1700f8d94 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ServiceOfferingService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ServiceOfferingService.go @@ -37,26 +37,10 @@ func (p *CreateServiceOfferingParams) toURLValues() url.Values { vv := strconv.FormatInt(v.(int64), 10) u.Set("bytesreadrate", vv) } - if v, found := p.p["bytesreadratemax"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("bytesreadratemax", vv) - } - if v, found := p.p["bytesreadratemaxlength"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("bytesreadratemaxlength", vv) - } if v, found := p.p["byteswriterate"]; found { vv := strconv.FormatInt(v.(int64), 10) u.Set("byteswriterate", vv) } - if v, found := p.p["byteswriteratemax"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("byteswriteratemax", vv) - } - if v, found := p.p["byteswriteratemaxlength"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("byteswriteratemaxlength", vv) - } if v, found := p.p["cpunumber"]; found { vv := strconv.Itoa(v.(int)) u.Set("cpunumber", vv) @@ -89,26 +73,10 @@ func (p *CreateServiceOfferingParams) toURLValues() url.Values { vv := strconv.FormatInt(v.(int64), 10) u.Set("iopsreadrate", vv) } - if v, found := p.p["iopsreadratemax"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("iopsreadratemax", vv) - } - if v, found := p.p["iopsreadratemaxlength"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("iopsreadratemaxlength", vv) - } if v, found := p.p["iopswriterate"]; found { vv := strconv.FormatInt(v.(int64), 10) u.Set("iopswriterate", vv) } - if v, found := p.p["iopswriteratemax"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("iopswriteratemax", vv) - } - if v, found := p.p["iopswriteratemaxlength"]; found { - vv := strconv.FormatInt(v.(int64), 10) - u.Set("iopswriteratemaxlength", vv) - } if v, found := p.p["issystem"]; found { vv := strconv.FormatBool(v.(bool)) u.Set("issystem", vv) @@ -175,22 +143,6 @@ func (p *CreateServiceOfferingParams) SetBytesreadrate(v int64) { return } -func (p *CreateServiceOfferingParams) SetBytesreadratemax(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["bytesreadratemax"] = v - return -} - -func (p *CreateServiceOfferingParams) SetBytesreadratemaxlength(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["bytesreadratemaxlength"] = v - return -} - func (p *CreateServiceOfferingParams) SetByteswriterate(v int64) { if p.p == nil { p.p = make(map[string]interface{}) @@ -199,22 +151,6 @@ func (p *CreateServiceOfferingParams) SetByteswriterate(v int64) { return } -func (p *CreateServiceOfferingParams) SetByteswriteratemax(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["byteswriteratemax"] = v - return -} - -func (p *CreateServiceOfferingParams) SetByteswriteratemaxlength(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["byteswriteratemaxlength"] = v - return -} - func (p *CreateServiceOfferingParams) SetCpunumber(v int) { if p.p == nil { p.p = make(map[string]interface{}) @@ -287,22 +223,6 @@ func (p *CreateServiceOfferingParams) SetIopsreadrate(v int64) { return } -func (p *CreateServiceOfferingParams) SetIopsreadratemax(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["iopsreadratemax"] = v - return -} - -func (p *CreateServiceOfferingParams) SetIopsreadratemaxlength(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["iopsreadratemaxlength"] = v - return -} - func (p *CreateServiceOfferingParams) SetIopswriterate(v int64) { if p.p == nil { p.p = make(map[string]interface{}) @@ -311,22 +231,6 @@ func (p *CreateServiceOfferingParams) SetIopswriterate(v int64) { return } -func (p *CreateServiceOfferingParams) SetIopswriteratemax(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["iopswriteratemax"] = v - return -} - -func (p *CreateServiceOfferingParams) SetIopswriteratemaxlength(v int64) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["iopswriteratemaxlength"] = v - return -} - func (p *CreateServiceOfferingParams) SetIssystem(v bool) { if p.p == nil { p.p = make(map[string]interface{}) @@ -469,47 +373,37 @@ func (s *ServiceOfferingService) CreateServiceOffering(p *CreateServiceOfferingP } type CreateServiceOfferingResponse struct { - Cpunumber int `json:"cpunumber"` - Cpuspeed int `json:"cpuspeed"` - Created string `json:"created"` - Defaultuse bool `json:"defaultuse"` - Deploymentplanner string `json:"deploymentplanner"` - DiskBytesReadRate int64 `json:"diskBytesReadRate"` - DiskBytesReadRateMax int64 `json:"diskBytesReadRateMax"` - DiskBytesReadRateMaxLength int64 `json:"diskBytesReadRateMaxLength"` - DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` - DiskBytesWriteRateMax int64 `json:"diskBytesWriteRateMax"` - DiskBytesWriteRateMaxLength int64 `json:"diskBytesWriteRateMaxLength"` - DiskIopsReadRate int64 `json:"diskIopsReadRate"` - DiskIopsReadRateMax int64 `json:"diskIopsReadRateMax"` - DiskIopsReadRateMaxLength int64 `json:"diskIopsReadRateMaxLength"` - DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` - DiskIopsWriteRateMax int64 `json:"diskIopsWriteRateMax"` - DiskIopsWriteRateMaxLength int64 `json:"diskIopsWriteRateMaxLength"` - Displaytext string `json:"displaytext"` - Domain string `json:"domain"` - Domainid string `json:"domainid"` - Hosttags string `json:"hosttags"` - Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` - Id string `json:"id"` - Iscustomized bool `json:"iscustomized"` - Iscustomizediops bool `json:"iscustomizediops"` - Issystem bool `json:"issystem"` - Isvolatile bool `json:"isvolatile"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Limitcpuuse bool `json:"limitcpuuse"` - Maxiops int64 `json:"maxiops"` - Memory int `json:"memory"` - Miniops int64 `json:"miniops"` - Name string `json:"name"` - Networkrate int `json:"networkrate"` - Offerha bool `json:"offerha"` - Provisioningtype string `json:"provisioningtype"` - Serviceofferingdetails map[string]string `json:"serviceofferingdetails"` - Storagetype string `json:"storagetype"` - Systemvmtype string `json:"systemvmtype"` - Tags string `json:"tags"` + Cpunumber int `json:"cpunumber"` + Cpuspeed int `json:"cpuspeed"` + Created string `json:"created"` + Defaultuse bool `json:"defaultuse"` + Deploymentplanner string `json:"deploymentplanner"` + DiskBytesReadRate int64 `json:"diskBytesReadRate"` + DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` + DiskIopsReadRate int64 `json:"diskIopsReadRate"` + DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` + Displaytext string `json:"displaytext"` + Domain string `json:"domain"` + Domainid string `json:"domainid"` + Hosttags string `json:"hosttags"` + Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` + Id string `json:"id"` + Iscustomized bool `json:"iscustomized"` + Iscustomizediops bool `json:"iscustomizediops"` + Issystem bool `json:"issystem"` + Isvolatile bool `json:"isvolatile"` + Limitcpuuse bool `json:"limitcpuuse"` + Maxiops int64 `json:"maxiops"` + Memory int `json:"memory"` + Miniops int64 `json:"miniops"` + Name string `json:"name"` + Networkrate int `json:"networkrate"` + Offerha bool `json:"offerha"` + Provisioningtype string `json:"provisioningtype"` + Serviceofferingdetails map[string]string `json:"serviceofferingdetails"` + Storagetype string `json:"storagetype"` + Systemvmtype string `json:"systemvmtype"` + Tags string `json:"tags"` } type DeleteServiceOfferingParams struct { @@ -561,8 +455,6 @@ func (s *ServiceOfferingService) DeleteServiceOffering(p *DeleteServiceOfferingP type DeleteServiceOfferingResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -581,14 +473,6 @@ func (r *DeleteServiceOfferingResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteServiceOfferingResponse return json.Unmarshal(b, (*alias)(r)) } @@ -843,47 +727,37 @@ type ListServiceOfferingsResponse struct { } type ServiceOffering struct { - Cpunumber int `json:"cpunumber"` - Cpuspeed int `json:"cpuspeed"` - Created string `json:"created"` - Defaultuse bool `json:"defaultuse"` - Deploymentplanner string `json:"deploymentplanner"` - DiskBytesReadRate int64 `json:"diskBytesReadRate"` - DiskBytesReadRateMax int64 `json:"diskBytesReadRateMax"` - DiskBytesReadRateMaxLength int64 `json:"diskBytesReadRateMaxLength"` - DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` - DiskBytesWriteRateMax int64 `json:"diskBytesWriteRateMax"` - DiskBytesWriteRateMaxLength int64 `json:"diskBytesWriteRateMaxLength"` - DiskIopsReadRate int64 `json:"diskIopsReadRate"` - DiskIopsReadRateMax int64 `json:"diskIopsReadRateMax"` - DiskIopsReadRateMaxLength int64 `json:"diskIopsReadRateMaxLength"` - DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` - DiskIopsWriteRateMax int64 `json:"diskIopsWriteRateMax"` - DiskIopsWriteRateMaxLength int64 `json:"diskIopsWriteRateMaxLength"` - Displaytext string `json:"displaytext"` - Domain string `json:"domain"` - Domainid string `json:"domainid"` - Hosttags string `json:"hosttags"` - Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` - Id string `json:"id"` - Iscustomized bool `json:"iscustomized"` - Iscustomizediops bool `json:"iscustomizediops"` - Issystem bool `json:"issystem"` - Isvolatile bool `json:"isvolatile"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Limitcpuuse bool `json:"limitcpuuse"` - Maxiops int64 `json:"maxiops"` - Memory int `json:"memory"` - Miniops int64 `json:"miniops"` - Name string `json:"name"` - Networkrate int `json:"networkrate"` - Offerha bool `json:"offerha"` - Provisioningtype string `json:"provisioningtype"` - Serviceofferingdetails map[string]string `json:"serviceofferingdetails"` - Storagetype string `json:"storagetype"` - Systemvmtype string `json:"systemvmtype"` - Tags string `json:"tags"` + Cpunumber int `json:"cpunumber"` + Cpuspeed int `json:"cpuspeed"` + Created string `json:"created"` + Defaultuse bool `json:"defaultuse"` + Deploymentplanner string `json:"deploymentplanner"` + DiskBytesReadRate int64 `json:"diskBytesReadRate"` + DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` + DiskIopsReadRate int64 `json:"diskIopsReadRate"` + DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` + Displaytext string `json:"displaytext"` + Domain string `json:"domain"` + Domainid string `json:"domainid"` + Hosttags string `json:"hosttags"` + Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` + Id string `json:"id"` + Iscustomized bool `json:"iscustomized"` + Iscustomizediops bool `json:"iscustomizediops"` + Issystem bool `json:"issystem"` + Isvolatile bool `json:"isvolatile"` + Limitcpuuse bool `json:"limitcpuuse"` + Maxiops int64 `json:"maxiops"` + Memory int `json:"memory"` + Miniops int64 `json:"miniops"` + Name string `json:"name"` + Networkrate int `json:"networkrate"` + Offerha bool `json:"offerha"` + Provisioningtype string `json:"provisioningtype"` + Serviceofferingdetails map[string]string `json:"serviceofferingdetails"` + Storagetype string `json:"storagetype"` + Systemvmtype string `json:"systemvmtype"` + Tags string `json:"tags"` } type UpdateServiceOfferingParams struct { @@ -968,45 +842,35 @@ func (s *ServiceOfferingService) UpdateServiceOffering(p *UpdateServiceOfferingP } type UpdateServiceOfferingResponse struct { - Cpunumber int `json:"cpunumber"` - Cpuspeed int `json:"cpuspeed"` - Created string `json:"created"` - Defaultuse bool `json:"defaultuse"` - Deploymentplanner string `json:"deploymentplanner"` - DiskBytesReadRate int64 `json:"diskBytesReadRate"` - DiskBytesReadRateMax int64 `json:"diskBytesReadRateMax"` - DiskBytesReadRateMaxLength int64 `json:"diskBytesReadRateMaxLength"` - DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` - DiskBytesWriteRateMax int64 `json:"diskBytesWriteRateMax"` - DiskBytesWriteRateMaxLength int64 `json:"diskBytesWriteRateMaxLength"` - DiskIopsReadRate int64 `json:"diskIopsReadRate"` - DiskIopsReadRateMax int64 `json:"diskIopsReadRateMax"` - DiskIopsReadRateMaxLength int64 `json:"diskIopsReadRateMaxLength"` - DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` - DiskIopsWriteRateMax int64 `json:"diskIopsWriteRateMax"` - DiskIopsWriteRateMaxLength int64 `json:"diskIopsWriteRateMaxLength"` - Displaytext string `json:"displaytext"` - Domain string `json:"domain"` - Domainid string `json:"domainid"` - Hosttags string `json:"hosttags"` - Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` - Id string `json:"id"` - Iscustomized bool `json:"iscustomized"` - Iscustomizediops bool `json:"iscustomizediops"` - Issystem bool `json:"issystem"` - Isvolatile bool `json:"isvolatile"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Limitcpuuse bool `json:"limitcpuuse"` - Maxiops int64 `json:"maxiops"` - Memory int `json:"memory"` - Miniops int64 `json:"miniops"` - Name string `json:"name"` - Networkrate int `json:"networkrate"` - Offerha bool `json:"offerha"` - Provisioningtype string `json:"provisioningtype"` - Serviceofferingdetails map[string]string `json:"serviceofferingdetails"` - Storagetype string `json:"storagetype"` - Systemvmtype string `json:"systemvmtype"` - Tags string `json:"tags"` + Cpunumber int `json:"cpunumber"` + Cpuspeed int `json:"cpuspeed"` + Created string `json:"created"` + Defaultuse bool `json:"defaultuse"` + Deploymentplanner string `json:"deploymentplanner"` + DiskBytesReadRate int64 `json:"diskBytesReadRate"` + DiskBytesWriteRate int64 `json:"diskBytesWriteRate"` + DiskIopsReadRate int64 `json:"diskIopsReadRate"` + DiskIopsWriteRate int64 `json:"diskIopsWriteRate"` + Displaytext string `json:"displaytext"` + Domain string `json:"domain"` + Domainid string `json:"domainid"` + Hosttags string `json:"hosttags"` + Hypervisorsnapshotreserve int `json:"hypervisorsnapshotreserve"` + Id string `json:"id"` + Iscustomized bool `json:"iscustomized"` + Iscustomizediops bool `json:"iscustomizediops"` + Issystem bool `json:"issystem"` + Isvolatile bool `json:"isvolatile"` + Limitcpuuse bool `json:"limitcpuuse"` + Maxiops int64 `json:"maxiops"` + Memory int `json:"memory"` + Miniops int64 `json:"miniops"` + Name string `json:"name"` + Networkrate int `json:"networkrate"` + Offerha bool `json:"offerha"` + Provisioningtype string `json:"provisioningtype"` + Serviceofferingdetails map[string]string `json:"serviceofferingdetails"` + Storagetype string `json:"storagetype"` + Systemvmtype string `json:"systemvmtype"` + Tags string `json:"tags"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/SnapshotService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/SnapshotService.go index 7733d8276..e3186e7e2 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/SnapshotService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/SnapshotService.go @@ -171,14 +171,13 @@ func (s *SnapshotService) CreateSnapshot(p *CreateSnapshotParams) (*CreateSnapsh } type CreateSnapshotResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Created string `json:"created"` Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` Intervaltype string `json:"intervaltype"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Locationtype string `json:"locationtype"` Name string `json:"name"` Osdisplayname string `json:"osdisplayname"` @@ -197,33 +196,6 @@ type CreateSnapshotResponse struct { Zoneid string `json:"zoneid"` } -func (r *CreateSnapshotResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias CreateSnapshotResponse - return json.Unmarshal(b, (*alias)(r)) -} - type CreateSnapshotPolicyParams struct { p map[string]interface{} } @@ -336,8 +308,6 @@ type CreateSnapshotPolicyResponse struct { Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Intervaltype int `json:"intervaltype"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxsnaps int `json:"maxsnaps"` Schedule string `json:"schedule"` Timezone string `json:"timezone"` @@ -458,6 +428,7 @@ func (s *SnapshotService) CreateVMSnapshot(p *CreateVMSnapshotParams) (*CreateVM } type CreateVMSnapshotResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Created string `json:"created"` Current bool `json:"current"` @@ -466,8 +437,6 @@ type CreateVMSnapshotResponse struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Parent string `json:"parent"` ParentName string `json:"parentName"` @@ -542,9 +511,8 @@ func (s *SnapshotService) DeleteSnapshot(p *DeleteSnapshotParams) (*DeleteSnapsh } type DeleteSnapshotResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -608,8 +576,6 @@ func (s *SnapshotService) DeleteSnapshotPolicies(p *DeleteSnapshotPoliciesParams type DeleteSnapshotPoliciesResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -628,14 +594,6 @@ func (r *DeleteSnapshotPoliciesResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteSnapshotPoliciesResponse return json.Unmarshal(b, (*alias)(r)) } @@ -703,9 +661,8 @@ func (s *SnapshotService) DeleteVMSnapshot(p *DeleteVMSnapshotParams) (*DeleteVM } type DeleteVMSnapshotResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -855,8 +812,6 @@ type SnapshotPolicy struct { Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Intervaltype int `json:"intervaltype"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxsnaps int `json:"maxsnaps"` Schedule string `json:"schedule"` Timezone string `json:"timezone"` @@ -1179,8 +1134,6 @@ type Snapshot struct { Domainid string `json:"domainid"` Id string `json:"id"` Intervaltype string `json:"intervaltype"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Locationtype string `json:"locationtype"` Name string `json:"name"` Osdisplayname string `json:"osdisplayname"` @@ -1199,33 +1152,6 @@ type Snapshot struct { Zoneid string `json:"zoneid"` } -func (r *Snapshot) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias Snapshot - return json.Unmarshal(b, (*alias)(r)) -} - type ListVMSnapshotParams struct { p map[string]interface{} } @@ -1475,8 +1401,6 @@ type VMSnapshot struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Parent string `json:"parent"` ParentName string `json:"parentName"` @@ -1556,14 +1480,13 @@ func (s *SnapshotService) RevertSnapshot(p *RevertSnapshotParams) (*RevertSnapsh } type RevertSnapshotResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Created string `json:"created"` Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` Intervaltype string `json:"intervaltype"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Locationtype string `json:"locationtype"` Name string `json:"name"` Osdisplayname string `json:"osdisplayname"` @@ -1582,33 +1505,6 @@ type RevertSnapshotResponse struct { Zoneid string `json:"zoneid"` } -func (r *RevertSnapshotResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias RevertSnapshotResponse - return json.Unmarshal(b, (*alias)(r)) -} - type RevertToVMSnapshotParams struct { p map[string]interface{} } @@ -1677,6 +1573,7 @@ func (s *SnapshotService) RevertToVMSnapshot(p *RevertToVMSnapshotParams) (*Reve } type RevertToVMSnapshotResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []RevertToVMSnapshotResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -1708,8 +1605,6 @@ type RevertToVMSnapshotResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -1719,7 +1614,7 @@ type RevertToVMSnapshotResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -1733,7 +1628,6 @@ type RevertToVMSnapshotResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -1786,33 +1680,6 @@ type RevertToVMSnapshotResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *RevertToVMSnapshotResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias RevertToVMSnapshotResponse - return json.Unmarshal(b, (*alias)(r)) -} - type UpdateSnapshotPolicyParams struct { p map[string]interface{} } @@ -1903,11 +1770,10 @@ func (s *SnapshotService) UpdateSnapshotPolicy(p *UpdateSnapshotPolicyParams) (* } type UpdateSnapshotPolicyResponse struct { + JobID string `json:"jobid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Intervaltype int `json:"intervaltype"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxsnaps int `json:"maxsnaps"` Schedule string `json:"schedule"` Timezone string `json:"timezone"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/StoragePoolService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/StoragePoolService.go index efd606b06..4938f14ff 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/StoragePoolService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/StoragePoolService.go @@ -90,6 +90,7 @@ func (s *StoragePoolService) CancelStorageMaintenance(p *CancelStorageMaintenanc } type CancelStorageMaintenanceResponse struct { + JobID string `json:"jobid"` Allocatediops int64 `json:"allocatediops"` Capacityiops int64 `json:"capacityiops"` Clusterid string `json:"clusterid"` @@ -101,8 +102,6 @@ type CancelStorageMaintenanceResponse struct { Hypervisor string `json:"hypervisor"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Overprovisionfactor string `json:"overprovisionfactor"` Path string `json:"path"` @@ -187,6 +186,7 @@ func (s *StoragePoolService) EnableStorageMaintenance(p *EnableStorageMaintenanc } type EnableStorageMaintenanceResponse struct { + JobID string `json:"jobid"` Allocatediops int64 `json:"allocatediops"` Capacityiops int64 `json:"capacityiops"` Clusterid string `json:"clusterid"` @@ -198,8 +198,6 @@ type EnableStorageMaintenanceResponse struct { Hypervisor string `json:"hypervisor"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Overprovisionfactor string `json:"overprovisionfactor"` Path string `json:"path"` @@ -304,8 +302,6 @@ type ListStorageProvidersResponse struct { } type StorageProvider struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` - Type string `json:"type"` + Name string `json:"name"` + Type string `json:"type"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/StratosphereSSPService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/StratosphereSSPService.go index 81d10596f..8a4d4914c 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/StratosphereSSPService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/StratosphereSSPService.go @@ -19,7 +19,6 @@ package cloudstack import ( "encoding/json" "net/url" - "strconv" ) type AddStratosphereSspParams struct { @@ -127,12 +126,10 @@ func (s *StratosphereSSPService) AddStratosphereSsp(p *AddStratosphereSspParams) } type AddStratosphereSspResponse struct { - Hostid string `json:"hostid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` - Url string `json:"url"` - Zoneid string `json:"zoneid"` + Hostid string `json:"hostid"` + Name string `json:"name"` + Url string `json:"url"` + Zoneid string `json:"zoneid"` } type DeleteStratosphereSspParams struct { @@ -184,8 +181,6 @@ func (s *StratosphereSSPService) DeleteStratosphereSsp(p *DeleteStratosphereSspP type DeleteStratosphereSspResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -204,14 +199,6 @@ func (r *DeleteStratosphereSspResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteStratosphereSspResponse return json.Unmarshal(b, (*alias)(r)) } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/SwiftService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/SwiftService.go index ded2b9589..e3161d95c 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/SwiftService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/SwiftService.go @@ -105,8 +105,6 @@ func (s *SwiftService) AddSwift(p *AddSwiftParams) (*AddSwiftResponse, error) { type AddSwiftResponse struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Protocol string `json:"protocol"` Providername string `json:"providername"` @@ -241,8 +239,6 @@ type ListSwiftsResponse struct { type Swift struct { Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Protocol string `json:"protocol"` Providername string `json:"providername"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/SystemCapacityService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/SystemCapacityService.go index c6d8ff9d7..686521c51 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/SystemCapacityService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/SystemCapacityService.go @@ -171,8 +171,6 @@ type Capacity struct { Capacityused int64 `json:"capacityused"` Clusterid string `json:"clusterid"` Clustername string `json:"clustername"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Percentused string `json:"percentused"` Podid string `json:"podid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/TemplateService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/TemplateService.go index 2b8d76432..2c40bbdee 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/TemplateService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/TemplateService.go @@ -126,6 +126,7 @@ func (s *TemplateService) CopyTemplate(p *CopyTemplateParams) (*CopyTemplateResp } type CopyTemplateResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Accountid string `json:"accountid"` Bits int `json:"bits"` @@ -149,8 +150,6 @@ type CopyTemplateResponse struct { Isfeatured bool `json:"isfeatured"` Ispublic bool `json:"ispublic"` Isready bool `json:"isready"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Ostypeid string `json:"ostypeid"` Ostypename string `json:"ostypename"` @@ -160,45 +159,16 @@ type CopyTemplateResponse struct { Project string `json:"project"` Projectid string `json:"projectid"` Removed string `json:"removed"` - Requireshvm bool `json:"requireshvm"` Size int64 `json:"size"` Sourcetemplateid string `json:"sourcetemplateid"` Sshkeyenabled bool `json:"sshkeyenabled"` Status string `json:"status"` - Tags []Tags `json:"tags"` Templatetag string `json:"templatetag"` Templatetype string `json:"templatetype"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } -func (r *CopyTemplateResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias CopyTemplateResponse - return json.Unmarshal(b, (*alias)(r)) -} - type CreateTemplateParams struct { p map[string]interface{} } @@ -254,10 +224,6 @@ func (p *CreateTemplateParams) toURLValues() url.Values { if v, found := p.p["snapshotid"]; found { u.Set("snapshotid", v.(string)) } - if v, found := p.p["sshkeyenabled"]; found { - vv := strconv.FormatBool(v.(bool)) - u.Set("sshkeyenabled", vv) - } if v, found := p.p["templatetag"]; found { u.Set("templatetag", v.(string)) } @@ -369,14 +335,6 @@ func (p *CreateTemplateParams) SetSnapshotid(v string) { return } -func (p *CreateTemplateParams) SetSshkeyenabled(v bool) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["sshkeyenabled"] = v - return -} - func (p *CreateTemplateParams) SetTemplatetag(v string) { if p.p == nil { p.p = make(map[string]interface{}) @@ -456,6 +414,7 @@ func (s *TemplateService) CreateTemplate(p *CreateTemplateParams) (*CreateTempla } type CreateTemplateResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Accountid string `json:"accountid"` Bits int `json:"bits"` @@ -479,8 +438,6 @@ type CreateTemplateResponse struct { Isfeatured bool `json:"isfeatured"` Ispublic bool `json:"ispublic"` Isready bool `json:"isready"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Ostypeid string `json:"ostypeid"` Ostypename string `json:"ostypename"` @@ -490,45 +447,16 @@ type CreateTemplateResponse struct { Project string `json:"project"` Projectid string `json:"projectid"` Removed string `json:"removed"` - Requireshvm bool `json:"requireshvm"` Size int64 `json:"size"` Sourcetemplateid string `json:"sourcetemplateid"` Sshkeyenabled bool `json:"sshkeyenabled"` Status string `json:"status"` - Tags []Tags `json:"tags"` Templatetag string `json:"templatetag"` Templatetype string `json:"templatetype"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } -func (r *CreateTemplateResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias CreateTemplateResponse - return json.Unmarshal(b, (*alias)(r)) -} - type DeleteTemplateParams struct { p map[string]interface{} } @@ -615,9 +543,8 @@ func (s *TemplateService) DeleteTemplate(p *DeleteTemplateParams) (*DeleteTempla } type DeleteTemplateResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -723,13 +650,12 @@ func (s *TemplateService) ExtractTemplate(p *ExtractTemplateParams) (*ExtractTem } type ExtractTemplateResponse struct { + JobID string `json:"jobid"` Accountid string `json:"accountid"` Created string `json:"created"` ExtractId string `json:"extractId"` ExtractMode string `json:"extractMode"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Resultstring string `json:"resultstring"` State string `json:"state"` @@ -1029,8 +955,6 @@ func (s *TemplateService) GetUploadParamsForTemplate(p *GetUploadParamsForTempla type GetUploadParamsForTemplateResponse struct { Expires string `json:"expires"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Metadata string `json:"metadata"` PostURL string `json:"postURL"` Signature string `json:"signature"` @@ -1126,8 +1050,6 @@ type TemplatePermission struct { Domainid string `json:"domainid"` Id string `json:"id"` Ispublic bool `json:"ispublic"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Projectids []string `json:"projectids"` } @@ -1480,8 +1402,6 @@ type Template struct { Isfeatured bool `json:"isfeatured"` Ispublic bool `json:"ispublic"` Isready bool `json:"isready"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Ostypeid string `json:"ostypeid"` Ostypename string `json:"ostypename"` @@ -1491,45 +1411,16 @@ type Template struct { Project string `json:"project"` Projectid string `json:"projectid"` Removed string `json:"removed"` - Requireshvm bool `json:"requireshvm"` Size int64 `json:"size"` Sourcetemplateid string `json:"sourcetemplateid"` Sshkeyenabled bool `json:"sshkeyenabled"` Status string `json:"status"` - Tags []Tags `json:"tags"` Templatetag string `json:"templatetag"` Templatetype string `json:"templatetype"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } -func (r *Template) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias Template - return json.Unmarshal(b, (*alias)(r)) -} - type PrepareTemplateParams struct { p map[string]interface{} } @@ -1624,8 +1515,6 @@ type PrepareTemplateResponse struct { Isfeatured bool `json:"isfeatured"` Ispublic bool `json:"ispublic"` Isready bool `json:"isready"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Ostypeid string `json:"ostypeid"` Ostypename string `json:"ostypename"` @@ -1635,45 +1524,16 @@ type PrepareTemplateResponse struct { Project string `json:"project"` Projectid string `json:"projectid"` Removed string `json:"removed"` - Requireshvm bool `json:"requireshvm"` Size int64 `json:"size"` Sourcetemplateid string `json:"sourcetemplateid"` Sshkeyenabled bool `json:"sshkeyenabled"` Status string `json:"status"` - Tags []Tags `json:"tags"` Templatetag string `json:"templatetag"` Templatetype string `json:"templatetype"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } -func (r *PrepareTemplateResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias PrepareTemplateResponse - return json.Unmarshal(b, (*alias)(r)) -} - type RegisterTemplateParams struct { p map[string]interface{} } @@ -2023,8 +1883,6 @@ type RegisterTemplate struct { Isfeatured bool `json:"isfeatured"` Ispublic bool `json:"ispublic"` Isready bool `json:"isready"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Ostypeid string `json:"ostypeid"` Ostypename string `json:"ostypename"` @@ -2034,45 +1892,16 @@ type RegisterTemplate struct { Project string `json:"project"` Projectid string `json:"projectid"` Removed string `json:"removed"` - Requireshvm bool `json:"requireshvm"` Size int64 `json:"size"` Sourcetemplateid string `json:"sourcetemplateid"` Sshkeyenabled bool `json:"sshkeyenabled"` Status string `json:"status"` - Tags []Tags `json:"tags"` Templatetag string `json:"templatetag"` Templatetype string `json:"templatetype"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } -func (r *RegisterTemplate) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias RegisterTemplate - return json.Unmarshal(b, (*alias)(r)) -} - type UpdateTemplateParams struct { p map[string]interface{} } @@ -2132,10 +1961,6 @@ func (p *UpdateTemplateParams) toURLValues() url.Values { vv := strconv.Itoa(v.(int)) u.Set("sortkey", vv) } - if v, found := p.p["sshkeyenabled"]; found { - vv := strconv.FormatBool(v.(bool)) - u.Set("sshkeyenabled", vv) - } return u } @@ -2243,14 +2068,6 @@ func (p *UpdateTemplateParams) SetSortkey(v int) { return } -func (p *UpdateTemplateParams) SetSshkeyenabled(v bool) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["sshkeyenabled"] = v - return -} - // You should always use this function to get a new UpdateTemplateParams instance, // as then you are sure you have configured all required params func (s *TemplateService) NewUpdateTemplateParams(id string) *UpdateTemplateParams { @@ -2299,8 +2116,6 @@ type UpdateTemplateResponse struct { Isfeatured bool `json:"isfeatured"` Ispublic bool `json:"ispublic"` Isready bool `json:"isready"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Ostypeid string `json:"ostypeid"` Ostypename string `json:"ostypename"` @@ -2310,45 +2125,16 @@ type UpdateTemplateResponse struct { Project string `json:"project"` Projectid string `json:"projectid"` Removed string `json:"removed"` - Requireshvm bool `json:"requireshvm"` Size int64 `json:"size"` Sourcetemplateid string `json:"sourcetemplateid"` Sshkeyenabled bool `json:"sshkeyenabled"` Status string `json:"status"` - Tags []Tags `json:"tags"` Templatetag string `json:"templatetag"` Templatetype string `json:"templatetype"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } -func (r *UpdateTemplateResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias UpdateTemplateResponse - return json.Unmarshal(b, (*alias)(r)) -} - type UpdateTemplatePermissionsParams struct { p map[string]interface{} } @@ -2469,8 +2255,6 @@ func (s *TemplateService) UpdateTemplatePermissions(p *UpdateTemplatePermissions type UpdateTemplatePermissionsResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -2489,14 +2273,6 @@ func (r *UpdateTemplatePermissionsResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias UpdateTemplatePermissionsResponse return json.Unmarshal(b, (*alias)(r)) } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/UCSService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/UCSService.go index bf109f04d..c3e1ed449 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/UCSService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/UCSService.go @@ -119,12 +119,10 @@ func (s *UCSService) AddUcsManager(p *AddUcsManagerParams) (*AddUcsManagerRespon } type AddUcsManagerResponse struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` - Url string `json:"url"` - Zoneid string `json:"zoneid"` + Id string `json:"id"` + Name string `json:"name"` + Url string `json:"url"` + Zoneid string `json:"zoneid"` } type AssociateUcsProfileToBladeParams struct { @@ -219,11 +217,10 @@ func (s *UCSService) AssociateUcsProfileToBlade(p *AssociateUcsProfileToBladePar } type AssociateUcsProfileToBladeResponse struct { + JobID string `json:"jobid"` Bladedn string `json:"bladedn"` Hostid string `json:"hostid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Profiledn string `json:"profiledn"` Ucsmanagerid string `json:"ucsmanagerid"` } @@ -277,8 +274,6 @@ func (s *UCSService) DeleteUcsManager(p *DeleteUcsManagerParams) (*DeleteUcsMana type DeleteUcsManagerResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -297,14 +292,6 @@ func (r *DeleteUcsManagerResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteUcsManagerResponse return json.Unmarshal(b, (*alias)(r)) } @@ -400,8 +387,6 @@ type UcsBlade struct { Bladedn string `json:"bladedn"` Hostid string `json:"hostid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Profiledn string `json:"profiledn"` Ucsmanagerid string `json:"ucsmanagerid"` } @@ -587,12 +572,10 @@ type ListUcsManagersResponse struct { } type UcsManager struct { - Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Name string `json:"name"` - Url string `json:"url"` - Zoneid string `json:"zoneid"` + Id string `json:"id"` + Name string `json:"name"` + Url string `json:"url"` + Zoneid string `json:"zoneid"` } type ListUcsProfilesParams struct { @@ -683,7 +666,5 @@ type ListUcsProfilesResponse struct { } type UcsProfile struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Ucsdn string `json:"ucsdn"` + Ucsdn string `json:"ucsdn"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/UsageService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/UsageService.go index e6632e77a..63a99ae5a 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/UsageService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/UsageService.go @@ -107,8 +107,6 @@ func (s *UsageService) AddTrafficMonitor(p *AddTrafficMonitorParams) (*AddTraffi type AddTrafficMonitorResponse struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Numretries string `json:"numretries"` Timeout string `json:"timeout"` Zoneid string `json:"zoneid"` @@ -271,10 +269,9 @@ func (s *UsageService) AddTrafficType(p *AddTrafficTypeParams) (*AddTrafficTypeR } type AddTrafficTypeResponse struct { + JobID string `json:"jobid"` Hypervnetworklabel string `json:"hypervnetworklabel"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Kvmnetworklabel string `json:"kvmnetworklabel"` Ovm3networklabel string `json:"ovm3networklabel"` Physicalnetworkid string `json:"physicalnetworkid"` @@ -332,8 +329,6 @@ func (s *UsageService) DeleteTrafficMonitor(p *DeleteTrafficMonitorParams) (*Del type DeleteTrafficMonitorResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -352,14 +347,6 @@ func (r *DeleteTrafficMonitorResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteTrafficMonitorResponse return json.Unmarshal(b, (*alias)(r)) } @@ -427,9 +414,8 @@ func (s *UsageService) DeleteTrafficType(p *DeleteTrafficTypeParams) (*DeleteTra } type DeleteTrafficTypeResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -505,8 +491,6 @@ func (s *UsageService) GenerateUsageRecords(p *GenerateUsageRecordsParams) (*Gen type GenerateUsageRecordsResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -525,14 +509,6 @@ func (r *GenerateUsageRecordsResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias GenerateUsageRecordsResponse return json.Unmarshal(b, (*alias)(r)) } @@ -627,8 +603,6 @@ type ListTrafficMonitorsResponse struct { type TrafficMonitor struct { Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Numretries string `json:"numretries"` Timeout string `json:"timeout"` Zoneid string `json:"zoneid"` @@ -721,8 +695,6 @@ type ListTrafficTypeImplementorsResponse struct { } type TrafficTypeImplementor struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Traffictype string `json:"traffictype"` Traffictypeimplementor string `json:"traffictypeimplementor"` } @@ -855,8 +827,6 @@ type TrafficType struct { Canenableindividualservice bool `json:"canenableindividualservice"` Destinationphysicalnetworkid string `json:"destinationphysicalnetworkid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Physicalnetworkid string `json:"physicalnetworkid"` Servicelist []string `json:"servicelist"` @@ -1053,8 +1023,6 @@ type UsageRecord struct { Isdefault bool `json:"isdefault"` Issourcenat bool `json:"issourcenat"` Issystem bool `json:"issystem"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Memory int64 `json:"memory"` Name string `json:"name"` Networkid string `json:"networkid"` @@ -1064,7 +1032,6 @@ type UsageRecord struct { Rawusage string `json:"rawusage"` Size int64 `json:"size"` Startdate string `json:"startdate"` - Tags []Tags `json:"tags"` Templateid string `json:"templateid"` Type string `json:"type"` Usage string `json:"usage"` @@ -1117,8 +1084,6 @@ type ListUsageTypesResponse struct { type UsageType struct { Description string `json:"description"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Usagetypeid int `json:"usagetypeid"` } @@ -1172,8 +1137,6 @@ func (s *UsageService) RemoveRawUsageRecords(p *RemoveRawUsageRecordsParams) (*R type RemoveRawUsageRecordsResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -1192,14 +1155,6 @@ func (r *RemoveRawUsageRecordsResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias RemoveRawUsageRecordsResponse return json.Unmarshal(b, (*alias)(r)) } @@ -1327,10 +1282,9 @@ func (s *UsageService) UpdateTrafficType(p *UpdateTrafficTypeParams) (*UpdateTra } type UpdateTrafficTypeResponse struct { + JobID string `json:"jobid"` Hypervnetworklabel string `json:"hypervnetworklabel"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Kvmnetworklabel string `json:"kvmnetworklabel"` Ovm3networklabel string `json:"ovm3networklabel"` Physicalnetworkid string `json:"physicalnetworkid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/UserService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/UserService.go index cf121e66f..ba98845b3 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/UserService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/UserService.go @@ -181,8 +181,6 @@ type CreateUserResponse struct { Id string `json:"id"` Iscallerchilddomain bool `json:"iscallerchilddomain"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Roleid string `json:"roleid"` Rolename string `json:"rolename"` @@ -243,8 +241,6 @@ func (s *UserService) DeleteUser(p *DeleteUserParams) (*DeleteUserResponse, erro type DeleteUserResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -263,14 +259,6 @@ func (r *DeleteUserResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteUserResponse return json.Unmarshal(b, (*alias)(r)) } @@ -343,6 +331,7 @@ func (s *UserService) DisableUser(p *DisableUserParams) (*DisableUserResponse, e } type DisableUserResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Accountid string `json:"accountid"` Accounttype int `json:"accounttype"` @@ -355,8 +344,6 @@ type DisableUserResponse struct { Id string `json:"id"` Iscallerchilddomain bool `json:"iscallerchilddomain"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Roleid string `json:"roleid"` Rolename string `json:"rolename"` @@ -428,8 +415,6 @@ type EnableUserResponse struct { Id string `json:"id"` Iscallerchilddomain bool `json:"iscallerchilddomain"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Roleid string `json:"roleid"` Rolename string `json:"rolename"` @@ -501,8 +486,6 @@ type GetUserResponse struct { Id string `json:"id"` Iscallerchilddomain bool `json:"iscallerchilddomain"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Roleid string `json:"roleid"` Rolename string `json:"rolename"` @@ -562,8 +545,6 @@ func (s *UserService) GetVirtualMachineUserData(p *GetVirtualMachineUserDataPara } type GetVirtualMachineUserDataResponse struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Userdata string `json:"userdata"` Virtualmachineid string `json:"virtualmachineid"` } @@ -780,8 +761,6 @@ type User struct { Id string `json:"id"` Iscallerchilddomain bool `json:"iscallerchilddomain"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Roleid string `json:"roleid"` Rolename string `json:"rolename"` @@ -853,8 +832,6 @@ type LockUserResponse struct { Id string `json:"id"` Iscallerchilddomain bool `json:"iscallerchilddomain"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Roleid string `json:"roleid"` Rolename string `json:"rolename"` @@ -919,8 +896,6 @@ func (s *UserService) RegisterUserKeys(p *RegisterUserKeysParams) (*RegisterUser type RegisterUserKeysResponse struct { Apikey string `json:"apikey"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Secretkey string `json:"secretkey"` } @@ -933,9 +908,6 @@ func (p *UpdateUserParams) toURLValues() url.Values { if p.p == nil { return u } - if v, found := p.p["currentpassword"]; found { - u.Set("currentpassword", v.(string)) - } if v, found := p.p["email"]; found { u.Set("email", v.(string)) } @@ -966,14 +938,6 @@ func (p *UpdateUserParams) toURLValues() url.Values { return u } -func (p *UpdateUserParams) SetCurrentpassword(v string) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["currentpassword"] = v - return -} - func (p *UpdateUserParams) SetEmail(v string) { if p.p == nil { p.p = make(map[string]interface{}) @@ -1083,8 +1047,6 @@ type UpdateUserResponse struct { Id string `json:"id"` Iscallerchilddomain bool `json:"iscallerchilddomain"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Lastname string `json:"lastname"` Roleid string `json:"roleid"` Rolename string `json:"rolename"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VLANService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VLANService.go index 15555c40b..754b19e7d 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VLANService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VLANService.go @@ -272,8 +272,6 @@ type CreateVlanIpRangeResponse struct { Id string `json:"id"` Ip6cidr string `json:"ip6cidr"` Ip6gateway string `json:"ip6gateway"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Netmask string `json:"netmask"` Networkid string `json:"networkid"` Physicalnetworkid string `json:"physicalnetworkid"` @@ -385,8 +383,6 @@ type DedicateGuestVlanRangeResponse struct { Domainid string `json:"domainid"` Guestvlanrange string `json:"guestvlanrange"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Physicalnetworkid int64 `json:"physicalnetworkid"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -442,8 +438,6 @@ func (s *VLANService) DeleteVlanIpRange(p *DeleteVlanIpRangeParams) (*DeleteVlan type DeleteVlanIpRangeResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -462,14 +456,6 @@ func (r *DeleteVlanIpRangeResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteVlanIpRangeResponse return json.Unmarshal(b, (*alias)(r)) } @@ -665,8 +651,6 @@ type DedicatedGuestVlanRange struct { Domainid string `json:"domainid"` Guestvlanrange string `json:"guestvlanrange"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Physicalnetworkid int64 `json:"physicalnetworkid"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -905,8 +889,6 @@ type VlanIpRange struct { Id string `json:"id"` Ip6cidr string `json:"ip6cidr"` Ip6gateway string `json:"ip6gateway"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Netmask string `json:"netmask"` Networkid string `json:"networkid"` Physicalnetworkid string `json:"physicalnetworkid"` @@ -983,8 +965,7 @@ func (s *VLANService) ReleaseDedicatedGuestVlanRange(p *ReleaseDedicatedGuestVla } type ReleaseDedicatedGuestVlanRangeResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VMGroupService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VMGroupService.go index 450010a7b..83c32381c 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VMGroupService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VMGroupService.go @@ -110,8 +110,6 @@ type CreateInstanceGroupResponse struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -166,8 +164,6 @@ func (s *VMGroupService) DeleteInstanceGroup(p *DeleteInstanceGroupParams) (*Del type DeleteInstanceGroupResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -186,14 +182,6 @@ func (r *DeleteInstanceGroupResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteInstanceGroupResponse return json.Unmarshal(b, (*alias)(r)) } @@ -441,8 +429,6 @@ type InstanceGroup struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -512,8 +498,6 @@ type UpdateInstanceGroupResponse struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VPCService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VPCService.go index 4ce00e2e1..149bb4fe5 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VPCService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VPCService.go @@ -185,6 +185,7 @@ func (s *VPCService) CreatePrivateGateway(p *CreatePrivateGatewayParams) (*Creat } type CreatePrivateGatewayResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Aclid string `json:"aclid"` Domain string `json:"domain"` @@ -192,8 +193,6 @@ type CreatePrivateGatewayResponse struct { Gateway string `json:"gateway"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Netmask string `json:"netmask"` Physicalnetworkid string `json:"physicalnetworkid"` Project string `json:"project"` @@ -286,14 +285,13 @@ func (s *VPCService) CreateStaticRoute(p *CreateStaticRouteParams) (*CreateStati } type CreateStaticRouteResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidr string `json:"cidr"` Domain string `json:"domain"` Domainid string `json:"domainid"` Gatewayid string `json:"gatewayid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` State string `json:"state"` @@ -485,6 +483,7 @@ func (s *VPCService) CreateVPC(p *CreateVPCParams) (*CreateVPCResponse, error) { } type CreateVPCResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidr string `json:"cidr"` Created string `json:"created"` @@ -494,8 +493,6 @@ type CreateVPCResponse struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Network []CreateVPCResponseNetwork `json:"network"` Networkdomain string `json:"networkdomain"` @@ -745,13 +742,12 @@ func (s *VPCService) CreateVPCOffering(p *CreateVPCOfferingParams) (*CreateVPCOf } type CreateVPCOfferingResponse struct { + JobID string `json:"jobid"` Created string `json:"created"` Displaytext string `json:"displaytext"` Distributedvpcrouter bool `json:"distributedvpcrouter"` Id string `json:"id"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Service []CreateVPCOfferingResponseService `json:"service"` State string `json:"state"` @@ -843,9 +839,8 @@ func (s *VPCService) DeletePrivateGateway(p *DeletePrivateGatewayParams) (*Delet } type DeletePrivateGatewayResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -912,9 +907,8 @@ func (s *VPCService) DeleteStaticRoute(p *DeleteStaticRouteParams) (*DeleteStati } type DeleteStaticRouteResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -981,9 +975,8 @@ func (s *VPCService) DeleteVPC(p *DeleteVPCParams) (*DeleteVPCResponse, error) { } type DeleteVPCResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1050,9 +1043,8 @@ func (s *VPCService) DeleteVPCOffering(p *DeleteVPCOfferingParams) (*DeleteVPCOf } type DeleteVPCOfferingResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1284,8 +1276,6 @@ type PrivateGateway struct { Gateway string `json:"gateway"` Id string `json:"id"` Ipaddress string `json:"ipaddress"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Netmask string `json:"netmask"` Physicalnetworkid string `json:"physicalnetworkid"` Project string `json:"project"` @@ -1519,8 +1509,6 @@ type StaticRoute struct { Domainid string `json:"domainid"` Gatewayid string `json:"gatewayid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` State string `json:"state"` @@ -1760,8 +1748,6 @@ type VPCOffering struct { Distributedvpcrouter bool `json:"distributedvpcrouter"` Id string `json:"id"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Service []VPCOfferingService `json:"service"` State string `json:"state"` @@ -2144,8 +2130,6 @@ type VPC struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Network []VPCNetwork `json:"network"` Networkdomain string `json:"networkdomain"` @@ -2351,6 +2335,7 @@ func (s *VPCService) RestartVPC(p *RestartVPCParams) (*RestartVPCResponse, error } type RestartVPCResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidr string `json:"cidr"` Created string `json:"created"` @@ -2360,8 +2345,6 @@ type RestartVPCResponse struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Network []RestartVPCResponseNetwork `json:"network"` Networkdomain string `json:"networkdomain"` @@ -2588,6 +2571,7 @@ func (s *VPCService) UpdateVPC(p *UpdateVPCParams) (*UpdateVPCResponse, error) { } type UpdateVPCResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidr string `json:"cidr"` Created string `json:"created"` @@ -2597,8 +2581,6 @@ type UpdateVPCResponse struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Network []UpdateVPCResponseNetwork `json:"network"` Networkdomain string `json:"networkdomain"` @@ -2813,13 +2795,12 @@ func (s *VPCService) UpdateVPCOffering(p *UpdateVPCOfferingParams) (*UpdateVPCOf } type UpdateVPCOfferingResponse struct { + JobID string `json:"jobid"` Created string `json:"created"` Displaytext string `json:"displaytext"` Distributedvpcrouter bool `json:"distributedvpcrouter"` Id string `json:"id"` Isdefault bool `json:"isdefault"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Service []UpdateVPCOfferingResponseService `json:"service"` State string `json:"state"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VPNService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VPNService.go index 01f651a66..796de853c 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VPNService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VPNService.go @@ -137,12 +137,11 @@ func (s *VPNService) AddVpnUser(p *AddVpnUserParams) (*AddVpnUserResponse, error } type AddVpnUserResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` State string `json:"state"` @@ -274,14 +273,13 @@ func (s *VPNService) CreateRemoteAccessVpn(p *CreateRemoteAccessVpnParams) (*Cre } type CreateRemoteAccessVpnResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Iprange string `json:"iprange"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Presharedkey string `json:"presharedkey"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -394,6 +392,7 @@ func (s *VPNService) CreateVpnConnection(p *CreateVpnConnectionParams) (*CreateV } type CreateVpnConnectionResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidrlist string `json:"cidrlist"` Created string `json:"created"` @@ -409,8 +408,6 @@ type CreateVpnConnectionResponse struct { Ikelifetime int64 `json:"ikelifetime"` Ikepolicy string `json:"ikepolicy"` Ipsecpsk string `json:"ipsecpsk"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Passive bool `json:"passive"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -629,6 +626,7 @@ func (s *VPNService) CreateVpnCustomerGateway(p *CreateVpnCustomerGatewayParams) } type CreateVpnCustomerGatewayResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidrlist string `json:"cidrlist"` Domain string `json:"domain"` @@ -643,8 +641,6 @@ type CreateVpnCustomerGatewayResponse struct { Ikepolicy string `json:"ikepolicy"` Ipaddress string `json:"ipaddress"` Ipsecpsk string `json:"ipsecpsk"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -731,13 +727,12 @@ func (s *VPNService) CreateVpnGateway(p *CreateVpnGatewayParams) (*CreateVpnGate } type CreateVpnGatewayResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` Publicip string `json:"publicip"` @@ -808,9 +803,8 @@ func (s *VPNService) DeleteRemoteAccessVpn(p *DeleteRemoteAccessVpnParams) (*Del } type DeleteRemoteAccessVpnResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -877,9 +871,8 @@ func (s *VPNService) DeleteVpnConnection(p *DeleteVpnConnectionParams) (*DeleteV } type DeleteVpnConnectionResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -946,9 +939,8 @@ func (s *VPNService) DeleteVpnCustomerGateway(p *DeleteVpnCustomerGatewayParams) } type DeleteVpnCustomerGatewayResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1015,9 +1007,8 @@ func (s *VPNService) DeleteVpnGateway(p *DeleteVpnGatewayParams) (*DeleteVpnGate } type DeleteVpnGatewayResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1238,8 +1229,6 @@ type RemoteAccessVpn struct { Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Iprange string `json:"iprange"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Presharedkey string `json:"presharedkey"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -1463,8 +1452,6 @@ type VpnConnection struct { Ikelifetime int64 `json:"ikelifetime"` Ikepolicy string `json:"ikepolicy"` Ipsecpsk string `json:"ipsecpsk"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Passive bool `json:"passive"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -1716,8 +1703,6 @@ type VpnCustomerGateway struct { Ikepolicy string `json:"ikepolicy"` Ipaddress string `json:"ipaddress"` Ipsecpsk string `json:"ipsecpsk"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -1929,8 +1914,6 @@ type VpnGateway struct { Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` Publicip string `json:"publicip"` @@ -2130,8 +2113,6 @@ type VpnUser struct { Domain string `json:"domain"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` State string `json:"state"` @@ -2234,9 +2215,8 @@ func (s *VPNService) RemoveVpnUser(p *RemoveVpnUserParams) (*RemoveVpnUserRespon } type RemoveVpnUserResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -2330,6 +2310,7 @@ func (s *VPNService) ResetVpnConnection(p *ResetVpnConnectionParams) (*ResetVpnC } type ResetVpnConnectionResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidrlist string `json:"cidrlist"` Created string `json:"created"` @@ -2345,8 +2326,6 @@ type ResetVpnConnectionResponse struct { Ikelifetime int64 `json:"ikelifetime"` Ikepolicy string `json:"ikepolicy"` Ipsecpsk string `json:"ipsecpsk"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Passive bool `json:"passive"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -2448,14 +2427,13 @@ func (s *VPNService) UpdateRemoteAccessVpn(p *UpdateRemoteAccessVpnParams) (*Upd } type UpdateRemoteAccessVpnResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` Iprange string `json:"iprange"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Presharedkey string `json:"presharedkey"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -2555,6 +2533,7 @@ func (s *VPNService) UpdateVpnConnection(p *UpdateVpnConnectionParams) (*UpdateV } type UpdateVpnConnectionResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidrlist string `json:"cidrlist"` Created string `json:"created"` @@ -2570,8 +2549,6 @@ type UpdateVpnConnectionResponse struct { Ikelifetime int64 `json:"ikelifetime"` Ikepolicy string `json:"ikepolicy"` Ipsecpsk string `json:"ipsecpsk"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Passive bool `json:"passive"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -2791,6 +2768,7 @@ func (s *VPNService) UpdateVpnCustomerGateway(p *UpdateVpnCustomerGatewayParams) } type UpdateVpnCustomerGatewayResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Cidrlist string `json:"cidrlist"` Domain string `json:"domain"` @@ -2805,8 +2783,6 @@ type UpdateVpnCustomerGatewayResponse struct { Ikepolicy string `json:"ikepolicy"` Ipaddress string `json:"ipaddress"` Ipsecpsk string `json:"ipsecpsk"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Project string `json:"project"` Projectid string `json:"projectid"` @@ -2904,13 +2880,12 @@ func (s *VPNService) UpdateVpnGateway(p *UpdateVpnGatewayParams) (*UpdateVpnGate } type UpdateVpnGatewayResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Domain string `json:"domain"` Domainid string `json:"domainid"` Fordisplay bool `json:"fordisplay"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Project string `json:"project"` Projectid string `json:"projectid"` Publicip string `json:"publicip"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VirtualMachineService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VirtualMachineService.go index 431de3ad8..638d81482 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VirtualMachineService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VirtualMachineService.go @@ -142,6 +142,7 @@ func (s *VirtualMachineService) AddNicToVirtualMachine(p *AddNicToVirtualMachine } type AddNicToVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []AddNicToVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -173,8 +174,6 @@ type AddNicToVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -184,7 +183,7 @@ type AddNicToVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -198,7 +197,6 @@ type AddNicToVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -251,33 +249,6 @@ type AddNicToVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *AddNicToVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias AddNicToVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type AssignVirtualMachineParams struct { p map[string]interface{} } @@ -414,8 +385,6 @@ type AssignVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -425,7 +394,7 @@ type AssignVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -439,7 +408,6 @@ type AssignVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -492,33 +460,6 @@ type AssignVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *AssignVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias AssignVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type ChangeServiceForVirtualMachineParams struct { p map[string]interface{} } @@ -625,8 +566,6 @@ type ChangeServiceForVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -636,7 +575,7 @@ type ChangeServiceForVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -650,7 +589,6 @@ type ChangeServiceForVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -703,33 +641,6 @@ type ChangeServiceForVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *ChangeServiceForVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias ChangeServiceForVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type CleanVMReservationsParams struct { p map[string]interface{} } @@ -781,9 +692,8 @@ func (s *VirtualMachineService) CleanVMReservations(p *CleanVMReservationsParams } type CleanVMReservationsResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -849,9 +759,6 @@ func (p *DeployVirtualMachineParams) toURLValues() url.Values { if v, found := p.p["domainid"]; found { u.Set("domainid", v.(string)) } - if v, found := p.p["extraconfig"]; found { - u.Set("extraconfig", v.(string)) - } if v, found := p.p["group"]; found { u.Set("group", v.(string)) } @@ -1025,14 +932,6 @@ func (p *DeployVirtualMachineParams) SetDomainid(v string) { return } -func (p *DeployVirtualMachineParams) SetExtraconfig(v string) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["extraconfig"] = v - return -} - func (p *DeployVirtualMachineParams) SetGroup(v string) { if p.p == nil { p.p = make(map[string]interface{}) @@ -1248,6 +1147,7 @@ func (s *VirtualMachineService) DeployVirtualMachine(p *DeployVirtualMachinePara } type DeployVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []DeployVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -1279,8 +1179,6 @@ type DeployVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -1290,7 +1188,7 @@ type DeployVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -1304,7 +1202,6 @@ type DeployVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -1357,33 +1254,6 @@ type DeployVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *DeployVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias DeployVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type DestroyVirtualMachineParams struct { p map[string]interface{} } @@ -1400,10 +1270,6 @@ func (p *DestroyVirtualMachineParams) toURLValues() url.Values { if v, found := p.p["id"]; found { u.Set("id", v.(string)) } - if v, found := p.p["volumeids"]; found { - vv := strings.Join(v.([]string), ",") - u.Set("volumeids", vv) - } return u } @@ -1423,14 +1289,6 @@ func (p *DestroyVirtualMachineParams) SetId(v string) { return } -func (p *DestroyVirtualMachineParams) SetVolumeids(v []string) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["volumeids"] = v - return -} - // You should always use this function to get a new DestroyVirtualMachineParams instance, // as then you are sure you have configured all required params func (s *VirtualMachineService) NewDestroyVirtualMachineParams(id string) *DestroyVirtualMachineParams { @@ -1476,6 +1334,7 @@ func (s *VirtualMachineService) DestroyVirtualMachine(p *DestroyVirtualMachinePa } type DestroyVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []DestroyVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -1507,8 +1366,6 @@ type DestroyVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -1518,7 +1375,7 @@ type DestroyVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -1532,7 +1389,6 @@ type DestroyVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -1585,33 +1441,6 @@ type DestroyVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *DestroyVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias DestroyVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type ExpungeVirtualMachineParams struct { p map[string]interface{} } @@ -1675,9 +1504,8 @@ func (s *VirtualMachineService) ExpungeVirtualMachine(p *ExpungeVirtualMachinePa } type ExpungeVirtualMachineResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1730,8 +1558,6 @@ func (s *VirtualMachineService) GetVMPassword(p *GetVMPasswordParams) (*GetVMPas type GetVMPasswordResponse struct { Encryptedpassword string `json:"encryptedpassword"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` } type ListVirtualMachinesParams struct { @@ -2232,8 +2058,6 @@ type VirtualMachine struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -2243,7 +2067,7 @@ type VirtualMachine struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -2257,7 +2081,6 @@ type VirtualMachine struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -2310,33 +2133,6 @@ type VirtualMachineAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *VirtualMachine) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias VirtualMachine - return json.Unmarshal(b, (*alias)(r)) -} - type MigrateVirtualMachineParams struct { p map[string]interface{} } @@ -2427,6 +2223,7 @@ func (s *VirtualMachineService) MigrateVirtualMachine(p *MigrateVirtualMachinePa } type MigrateVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []MigrateVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -2458,8 +2255,6 @@ type MigrateVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -2469,7 +2264,7 @@ type MigrateVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -2483,7 +2278,6 @@ type MigrateVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -2536,33 +2330,6 @@ type MigrateVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *MigrateVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias MigrateVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type MigrateVirtualMachineWithVolumeParams struct { p map[string]interface{} } @@ -2659,6 +2426,7 @@ func (s *VirtualMachineService) MigrateVirtualMachineWithVolume(p *MigrateVirtua } type MigrateVirtualMachineWithVolumeResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []MigrateVirtualMachineWithVolumeResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -2690,8 +2458,6 @@ type MigrateVirtualMachineWithVolumeResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -2701,7 +2467,7 @@ type MigrateVirtualMachineWithVolumeResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -2715,7 +2481,6 @@ type MigrateVirtualMachineWithVolumeResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -2768,33 +2533,6 @@ type MigrateVirtualMachineWithVolumeResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *MigrateVirtualMachineWithVolumeResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias MigrateVirtualMachineWithVolumeResponse - return json.Unmarshal(b, (*alias)(r)) -} - type RebootVirtualMachineParams struct { p map[string]interface{} } @@ -2863,6 +2601,7 @@ func (s *VirtualMachineService) RebootVirtualMachine(p *RebootVirtualMachinePara } type RebootVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []RebootVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -2894,8 +2633,6 @@ type RebootVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -2905,7 +2642,7 @@ type RebootVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -2919,7 +2656,6 @@ type RebootVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -2972,33 +2708,6 @@ type RebootVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *RebootVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias RebootVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type RecoverVirtualMachineParams struct { p map[string]interface{} } @@ -3078,8 +2787,6 @@ type RecoverVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -3089,7 +2796,7 @@ type RecoverVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -3103,7 +2810,6 @@ type RecoverVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -3156,33 +2862,6 @@ type RecoverVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *RecoverVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias RecoverVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type RemoveNicFromVirtualMachineParams struct { p map[string]interface{} } @@ -3263,6 +2942,7 @@ func (s *VirtualMachineService) RemoveNicFromVirtualMachine(p *RemoveNicFromVirt } type RemoveNicFromVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []RemoveNicFromVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -3294,8 +2974,6 @@ type RemoveNicFromVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -3305,7 +2983,7 @@ type RemoveNicFromVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -3319,7 +2997,6 @@ type RemoveNicFromVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -3372,33 +3049,6 @@ type RemoveNicFromVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *RemoveNicFromVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias RemoveNicFromVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type ResetPasswordForVirtualMachineParams struct { p map[string]interface{} } @@ -3467,6 +3117,7 @@ func (s *VirtualMachineService) ResetPasswordForVirtualMachine(p *ResetPasswordF } type ResetPasswordForVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []ResetPasswordForVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -3498,8 +3149,6 @@ type ResetPasswordForVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -3509,7 +3158,7 @@ type ResetPasswordForVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -3523,7 +3172,6 @@ type ResetPasswordForVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -3576,33 +3224,6 @@ type ResetPasswordForVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *ResetPasswordForVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias ResetPasswordForVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type RestoreVirtualMachineParams struct { p map[string]interface{} } @@ -3682,6 +3303,7 @@ func (s *VirtualMachineService) RestoreVirtualMachine(p *RestoreVirtualMachinePa } type RestoreVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []RestoreVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -3713,8 +3335,6 @@ type RestoreVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -3724,7 +3344,7 @@ type RestoreVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -3738,7 +3358,6 @@ type RestoreVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -3791,33 +3410,6 @@ type RestoreVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *RestoreVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias RestoreVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type ScaleVirtualMachineParams struct { p map[string]interface{} } @@ -3908,9 +3500,8 @@ func (s *VirtualMachineService) ScaleVirtualMachine(p *ScaleVirtualMachineParams } type ScaleVirtualMachineResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -4004,6 +3595,7 @@ func (s *VirtualMachineService) StartVirtualMachine(p *StartVirtualMachineParams } type StartVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []StartVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -4035,8 +3627,6 @@ type StartVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -4046,7 +3636,7 @@ type StartVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -4060,7 +3650,6 @@ type StartVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -4113,33 +3702,6 @@ type StartVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *StartVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias StartVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type StopVirtualMachineParams struct { p map[string]interface{} } @@ -4220,6 +3782,7 @@ func (s *VirtualMachineService) StopVirtualMachine(p *StopVirtualMachineParams) } type StopVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []StopVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -4251,8 +3814,6 @@ type StopVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -4262,7 +3823,7 @@ type StopVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -4276,7 +3837,6 @@ type StopVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -4329,33 +3889,6 @@ type StopVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *StopVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias StopVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type UpdateDefaultNicForVirtualMachineParams struct { p map[string]interface{} } @@ -4436,6 +3969,7 @@ func (s *VirtualMachineService) UpdateDefaultNicForVirtualMachine(p *UpdateDefau } type UpdateDefaultNicForVirtualMachineResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Affinitygroup []UpdateDefaultNicForVirtualMachineResponseAffinitygroup `json:"affinitygroup"` Cpunumber int `json:"cpunumber"` @@ -4467,8 +4001,6 @@ type UpdateDefaultNicForVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -4478,7 +4010,7 @@ type UpdateDefaultNicForVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -4492,7 +4024,6 @@ type UpdateDefaultNicForVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -4545,33 +4076,6 @@ type UpdateDefaultNicForVirtualMachineResponseAffinitygroup struct { VirtualmachineIds []string `json:"virtualmachineIds"` } -func (r *UpdateDefaultNicForVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias UpdateDefaultNicForVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} - type UpdateVirtualMachineParams struct { p map[string]interface{} } @@ -4610,9 +4114,6 @@ func (p *UpdateVirtualMachineParams) toURLValues() url.Values { vv := strconv.FormatBool(v.(bool)) u.Set("displayvm", vv) } - if v, found := p.p["extraconfig"]; found { - u.Set("extraconfig", v.(string)) - } if v, found := p.p["group"]; found { u.Set("group", v.(string)) } @@ -4698,14 +4199,6 @@ func (p *UpdateVirtualMachineParams) SetDisplayvm(v bool) { return } -func (p *UpdateVirtualMachineParams) SetExtraconfig(v string) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["extraconfig"] = v - return -} - func (p *UpdateVirtualMachineParams) SetGroup(v string) { if p.p == nil { p.p = make(map[string]interface{}) @@ -4842,8 +4335,6 @@ type UpdateVirtualMachineResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Keypair string `json:"keypair"` Memory int `json:"memory"` Memoryintfreekbs int64 `json:"memoryintfreekbs"` @@ -4853,7 +4344,7 @@ type UpdateVirtualMachineResponse struct { Networkkbsread int64 `json:"networkkbsread"` Networkkbswrite int64 `json:"networkkbswrite"` Nic []Nic `json:"nic"` - Ostypeid string `json:"ostypeid"` + Ostypeid int64 `json:"ostypeid"` Password string `json:"password"` Passwordenabled bool `json:"passwordenabled"` Project string `json:"project"` @@ -4867,7 +4358,6 @@ type UpdateVirtualMachineResponse struct { Serviceofferingname string `json:"serviceofferingname"` Servicestate string `json:"servicestate"` State string `json:"state"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -4919,30 +4409,3 @@ type UpdateVirtualMachineResponseAffinitygroup struct { Type string `json:"type"` VirtualmachineIds []string `json:"virtualmachineIds"` } - -func (r *UpdateVirtualMachineResponse) UnmarshalJSON(b []byte) error { - var m map[string]interface{} - err := json.Unmarshal(b, &m) - if err != nil { - return err - } - - if success, ok := m["success"].(string); ok { - m["success"] = success == "true" - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - - type alias UpdateVirtualMachineResponse - return json.Unmarshal(b, (*alias)(r)) -} diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VolumeService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VolumeService.go index e95c5e0d1..e7cf73f7c 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/VolumeService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/VolumeService.go @@ -116,6 +116,7 @@ func (s *VolumeService) AttachVolume(p *AttachVolumeParams) (*AttachVolumeRespon } type AttachVolumeResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Attached string `json:"attached"` Chaininfo string `json:"chaininfo"` @@ -140,8 +141,6 @@ type AttachVolumeResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxiops int64 `json:"maxiops"` Miniops int64 `json:"miniops"` Name string `json:"name"` @@ -163,7 +162,6 @@ type AttachVolumeResponse struct { Storage string `json:"storage"` Storageid string `json:"storageid"` Storagetype string `json:"storagetype"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -381,6 +379,7 @@ func (s *VolumeService) CreateVolume(p *CreateVolumeParams) (*CreateVolumeRespon } type CreateVolumeResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Attached string `json:"attached"` Chaininfo string `json:"chaininfo"` @@ -405,8 +404,6 @@ type CreateVolumeResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxiops int64 `json:"maxiops"` Miniops int64 `json:"miniops"` Name string `json:"name"` @@ -428,7 +425,6 @@ type CreateVolumeResponse struct { Storage string `json:"storage"` Storageid string `json:"storageid"` Storagetype string `json:"storagetype"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -492,8 +488,6 @@ func (s *VolumeService) DeleteVolume(p *DeleteVolumeParams) (*DeleteVolumeRespon type DeleteVolumeResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -512,14 +506,6 @@ func (r *DeleteVolumeResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteVolumeResponse return json.Unmarshal(b, (*alias)(r)) } @@ -614,6 +600,7 @@ func (s *VolumeService) DetachVolume(p *DetachVolumeParams) (*DetachVolumeRespon } type DetachVolumeResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Attached string `json:"attached"` Chaininfo string `json:"chaininfo"` @@ -638,8 +625,6 @@ type DetachVolumeResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxiops int64 `json:"maxiops"` Miniops int64 `json:"miniops"` Name string `json:"name"` @@ -661,7 +646,6 @@ type DetachVolumeResponse struct { Storage string `json:"storage"` Storageid string `json:"storageid"` Storagetype string `json:"storagetype"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -779,13 +763,12 @@ func (s *VolumeService) ExtractVolume(p *ExtractVolumeParams) (*ExtractVolumeRes } type ExtractVolumeResponse struct { + JobID string `json:"jobid"` Accountid string `json:"accountid"` Created string `json:"created"` ExtractId string `json:"extractId"` ExtractMode string `json:"extractMode"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Name string `json:"name"` Resultstring string `json:"resultstring"` State string `json:"state"` @@ -845,9 +828,7 @@ func (s *VolumeService) GetPathForVolume(p *GetPathForVolumeParams) (*GetPathFor } type GetPathForVolumeResponse struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - Path string `json:"path"` + Path string `json:"path"` } type GetSolidFireVolumeSizeParams struct { @@ -898,9 +879,7 @@ func (s *VolumeService) GetSolidFireVolumeSize(p *GetSolidFireVolumeSizeParams) } type GetSolidFireVolumeSizeResponse struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` - SolidFireVolumeSize int64 `json:"solidFireVolumeSize"` + SolidFireVolumeSize int64 `json:"solidFireVolumeSize"` } type GetUploadParamsForVolumeParams struct { @@ -1043,8 +1022,6 @@ func (s *VolumeService) GetUploadParamsForVolume(p *GetUploadParamsForVolumePara type GetUploadParamsForVolumeResponse struct { Expires string `json:"expires"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Metadata string `json:"metadata"` PostURL string `json:"postURL"` Signature string `json:"signature"` @@ -1098,8 +1075,6 @@ func (s *VolumeService) GetVolumeiScsiName(p *GetVolumeiScsiNameParams) (*GetVol } type GetVolumeiScsiNameResponse struct { - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` VolumeiScsiName string `json:"volumeiScsiName"` } @@ -1493,8 +1468,6 @@ type Volume struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxiops int64 `json:"maxiops"` Miniops int64 `json:"miniops"` Name string `json:"name"` @@ -1516,7 +1489,6 @@ type Volume struct { Storage string `json:"storage"` Storageid string `json:"storageid"` Storagetype string `json:"storagetype"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -1544,9 +1516,6 @@ func (p *MigrateVolumeParams) toURLValues() url.Values { vv := strconv.FormatBool(v.(bool)) u.Set("livemigrate", vv) } - if v, found := p.p["newdiskofferingid"]; found { - u.Set("newdiskofferingid", v.(string)) - } if v, found := p.p["storageid"]; found { u.Set("storageid", v.(string)) } @@ -1564,14 +1533,6 @@ func (p *MigrateVolumeParams) SetLivemigrate(v bool) { return } -func (p *MigrateVolumeParams) SetNewdiskofferingid(v string) { - if p.p == nil { - p.p = make(map[string]interface{}) - } - p.p["newdiskofferingid"] = v - return -} - func (p *MigrateVolumeParams) SetStorageid(v string) { if p.p == nil { p.p = make(map[string]interface{}) @@ -1634,6 +1595,7 @@ func (s *VolumeService) MigrateVolume(p *MigrateVolumeParams) (*MigrateVolumeRes } type MigrateVolumeResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Attached string `json:"attached"` Chaininfo string `json:"chaininfo"` @@ -1658,8 +1620,6 @@ type MigrateVolumeResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxiops int64 `json:"maxiops"` Miniops int64 `json:"miniops"` Name string `json:"name"` @@ -1681,7 +1641,6 @@ type MigrateVolumeResponse struct { Storage string `json:"storage"` Storageid string `json:"storageid"` Storagetype string `json:"storagetype"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -1823,6 +1782,7 @@ func (s *VolumeService) ResizeVolume(p *ResizeVolumeParams) (*ResizeVolumeRespon } type ResizeVolumeResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Attached string `json:"attached"` Chaininfo string `json:"chaininfo"` @@ -1847,8 +1807,6 @@ type ResizeVolumeResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxiops int64 `json:"maxiops"` Miniops int64 `json:"miniops"` Name string `json:"name"` @@ -1870,7 +1828,6 @@ type ResizeVolumeResponse struct { Storage string `json:"storage"` Storageid string `json:"storageid"` Storagetype string `json:"storagetype"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -2019,6 +1976,7 @@ func (s *VolumeService) UpdateVolume(p *UpdateVolumeParams) (*UpdateVolumeRespon } type UpdateVolumeResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Attached string `json:"attached"` Chaininfo string `json:"chaininfo"` @@ -2043,8 +2001,6 @@ type UpdateVolumeResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxiops int64 `json:"maxiops"` Miniops int64 `json:"miniops"` Name string `json:"name"` @@ -2066,7 +2022,6 @@ type UpdateVolumeResponse struct { Storage string `json:"storage"` Storageid string `json:"storageid"` Storagetype string `json:"storagetype"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` @@ -2251,6 +2206,7 @@ func (s *VolumeService) UploadVolume(p *UploadVolumeParams) (*UploadVolumeRespon } type UploadVolumeResponse struct { + JobID string `json:"jobid"` Account string `json:"account"` Attached string `json:"attached"` Chaininfo string `json:"chaininfo"` @@ -2275,8 +2231,6 @@ type UploadVolumeResponse struct { Isodisplaytext string `json:"isodisplaytext"` Isoid string `json:"isoid"` Isoname string `json:"isoname"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Maxiops int64 `json:"maxiops"` Miniops int64 `json:"miniops"` Name string `json:"name"` @@ -2298,7 +2252,6 @@ type UploadVolumeResponse struct { Storage string `json:"storage"` Storageid string `json:"storageid"` Storagetype string `json:"storagetype"` - Tags []Tags `json:"tags"` Templatedisplaytext string `json:"templatedisplaytext"` Templateid string `json:"templateid"` Templatename string `json:"templatename"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ZoneService.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ZoneService.go index fff7f4046..1d8029d41 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/ZoneService.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/ZoneService.go @@ -236,8 +236,6 @@ type CreateZoneResponse struct { Internaldns2 string `json:"internaldns2"` Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Localstorageenabled bool `json:"localstorageenabled"` Name string `json:"name"` Networktype string `json:"networktype"` @@ -353,12 +351,11 @@ func (s *ZoneService) DedicateZone(p *DedicateZoneParams) (*DedicateZoneResponse } type DedicateZoneResponse struct { + JobID string `json:"jobid"` Accountid string `json:"accountid"` Affinitygroupid string `json:"affinitygroupid"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } @@ -412,8 +409,6 @@ func (s *ZoneService) DeleteZone(p *DeleteZoneParams) (*DeleteZoneResponse, erro type DeleteZoneResponse struct { Displaytext string `json:"displaytext"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Success bool `json:"success"` } @@ -432,14 +427,6 @@ func (r *DeleteZoneResponse) UnmarshalJSON(b []byte) error { } } - if ostypeid, ok := m["ostypeid"].(float64); ok { - m["ostypeid"] = strconv.Itoa(int(ostypeid)) - b, err = json.Marshal(m) - if err != nil { - return err - } - } - type alias DeleteZoneResponse return json.Unmarshal(b, (*alias)(r)) } @@ -512,14 +499,13 @@ func (s *ZoneService) DisableOutOfBandManagementForZone(p *DisableOutOfBandManag } type DisableOutOfBandManagementForZoneResponse struct { + JobID string `json:"jobid"` Action string `json:"action"` Address string `json:"address"` Description string `json:"description"` Driver string `json:"driver"` Enabled bool `json:"enabled"` Hostid string `json:"hostid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Password string `json:"password"` Port string `json:"port"` Powerstate string `json:"powerstate"` @@ -595,14 +581,13 @@ func (s *ZoneService) EnableOutOfBandManagementForZone(p *EnableOutOfBandManagem } type EnableOutOfBandManagementForZoneResponse struct { + JobID string `json:"jobid"` Action string `json:"action"` Address string `json:"address"` Description string `json:"description"` Driver string `json:"driver"` Enabled bool `json:"enabled"` Hostid string `json:"hostid"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Password string `json:"password"` Port string `json:"port"` Powerstate string `json:"powerstate"` @@ -734,8 +719,6 @@ type DedicatedZone struct { Affinitygroupid string `json:"affinitygroupid"` Domainid string `json:"domainid"` Id string `json:"id"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Zoneid string `json:"zoneid"` Zonename string `json:"zonename"` } @@ -999,8 +982,6 @@ type Zone struct { Internaldns2 string `json:"internaldns2"` Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Localstorageenabled bool `json:"localstorageenabled"` Name string `json:"name"` Networktype string `json:"networktype"` @@ -1088,9 +1069,8 @@ func (s *ZoneService) ReleaseDedicatedZone(p *ReleaseDedicatedZoneParams) (*Rele } type ReleaseDedicatedZoneResponse struct { - Displaytext string `json:"displaytext"` JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` + Displaytext string `json:"displaytext"` Success bool `json:"success"` } @@ -1330,8 +1310,6 @@ type UpdateZoneResponse struct { Internaldns2 string `json:"internaldns2"` Ip6dns1 string `json:"ip6dns1"` Ip6dns2 string `json:"ip6dns2"` - JobID string `json:"jobid"` - Jobstatus int `json:"jobstatus"` Localstorageenabled bool `json:"localstorageenabled"` Name string `json:"name"` Networktype string `json:"networktype"` diff --git a/vendor/github.com/xanzy/go-cloudstack/cloudstack/cloudstack.go b/vendor/github.com/xanzy/go-cloudstack/cloudstack/cloudstack.go index e3dcb4e9d..04bbac3a8 100644 --- a/vendor/github.com/xanzy/go-cloudstack/cloudstack/cloudstack.go +++ b/vendor/github.com/xanzy/go-cloudstack/cloudstack/cloudstack.go @@ -156,7 +156,7 @@ func newClient(apiurl string, apikey string, secret string, async bool, verifyss }).DialContext, MaxIdleConns: 100, IdleConnTimeout: 90 * time.Second, - TLSClientConfig: &tls.Config{InsecureSkipVerify: !verifyssl}, + TLSClientConfig: &tls.Config{InsecureSkipVerify: !verifyssl}, // If verifyssl is true, skipping the verify should be false and vice versa TLSHandshakeTimeout: 10 * time.Second, ExpectContinueTimeout: 1 * time.Second, }, @@ -419,34 +419,6 @@ func getRawValue(b json.RawMessage) (json.RawMessage, error) { return nil, fmt.Errorf("Unable to extract the raw value from:\n\n%s\n\n", string(b)) } -// DomainIDSetter is an interface that every type that can set a domain ID must implement -type DomainIDSetter interface { - SetDomainid(string) -} - -// WithDomain takes either a domain name or ID and sets the `domainid` parameter -func WithDomain(domain string) OptionFunc { - return func(cs *CloudStackClient, p interface{}) error { - ps, ok := p.(DomainIDSetter) - - if !ok || domain == "" { - return nil - } - - if !IsID(domain) { - id, _, err := cs.Domain.GetDomainID(domain) - if err != nil { - return err - } - domain = id - } - - ps.SetDomainid(domain) - - return nil - } -} - // ProjectIDSetter is an interface that every type that can set a project ID must implement type ProjectIDSetter interface { SetProjectid(string) diff --git a/vendor/modules.txt b/vendor/modules.txt index 109f3e21f..50c1bf48b 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -511,6 +511,9 @@ github.com/hashicorp/packer-plugin-ansible/provisioner/ansible-local ## explicit github.com/hashicorp/packer-plugin-chef/provisioner/chef-client github.com/hashicorp/packer-plugin-chef/provisioner/chef-solo +# github.com/hashicorp/packer-plugin-cloudstack v0.0.1 +## explicit +github.com/hashicorp/packer-plugin-cloudstack/builder/cloudstack # github.com/hashicorp/packer-plugin-docker v0.0.7 ## explicit github.com/hashicorp/packer-plugin-docker/builder/docker @@ -864,8 +867,7 @@ github.com/vmware/govmomi/vim25/progress github.com/vmware/govmomi/vim25/soap github.com/vmware/govmomi/vim25/types github.com/vmware/govmomi/vim25/xml -# github.com/xanzy/go-cloudstack v0.0.0-20190526095453-42f262b63ed0 -## explicit +# github.com/xanzy/go-cloudstack v2.4.1+incompatible github.com/xanzy/go-cloudstack/cloudstack # github.com/yandex-cloud/go-genproto v0.0.0-20200915125933-33de72a328bd ## explicit diff --git a/website/data/docs-nav-data.json b/website/data/docs-nav-data.json index 231b7f676..6bd633eb0 100644 --- a/website/data/docs-nav-data.json +++ b/website/data/docs-nav-data.json @@ -696,10 +696,6 @@ } ] }, - { - "title": "CloudStack", - "path": "builders/cloudstack" - }, { "title": "DigitalOcean", "path": "builders/digitalocean" diff --git a/website/data/docs-remote-plugins.json b/website/data/docs-remote-plugins.json index 6f8fec1e4..a322f7dc5 100644 --- a/website/data/docs-remote-plugins.json +++ b/website/data/docs-remote-plugins.json @@ -23,12 +23,21 @@ "path": "chef", "repo": "hashicorp/packer-plugin-chef", "version": "latest", - "pluginTier": "community" + "pluginTier": "community", + "version": "latest" + }, + { + "title": "Cloudstack", + "path": "cloudstack", + "repo": "hashicorp/packer-plugin-cloudstack", + "pluginTier": "community", + "version": "latest" }, { "title": "Docker", "path": "docker", "repo": "hashicorp/packer-plugin-docker", + "version": "latest" }, {