mirror of
https://github.com/hashicorp/vault.git
synced 2026-02-19 02:49:18 -05:00
mod: update plugin versions for 1.7.0 (#11046)
* mod: update plugin versions for 1.7.0 * command/agent: fix TestCFEndToEnd test
This commit is contained in:
parent
2b9b8f355b
commit
46d9dfd933
234 changed files with 13992 additions and 6848 deletions
|
|
@ -64,7 +64,7 @@ func TestCFEndToEnd(t *testing.T) {
|
|||
}()
|
||||
|
||||
// Start a mock server representing their API.
|
||||
mockCFAPI := cfAPI.MockServer(false)
|
||||
mockCFAPI := cfAPI.MockServer(false, nil)
|
||||
defer mockCFAPI.Close()
|
||||
|
||||
// Configure a CA certificate like a Vault operator would in setting up CF.
|
||||
|
|
|
|||
47
go.mod
47
go.mod
|
|
@ -11,8 +11,8 @@ require (
|
|||
cloud.google.com/go/spanner v1.5.1
|
||||
cloud.google.com/go/storage v1.6.0
|
||||
github.com/Azure/azure-storage-blob-go v0.11.0
|
||||
github.com/Azure/go-autorest/autorest v0.11.10
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.5
|
||||
github.com/Azure/go-autorest/autorest v0.11.17
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.11
|
||||
github.com/Microsoft/hcsshim v0.8.14 // indirect
|
||||
github.com/NYTimes/gziphandler v1.1.1
|
||||
github.com/SAP/go-hdb v0.14.1
|
||||
|
|
@ -45,7 +45,7 @@ require (
|
|||
github.com/fullsailor/pkcs7 v0.0.0-20190404230743-d7302db945fa
|
||||
github.com/ghodss/yaml v1.0.1-0.20190212211648-25d852aebe32
|
||||
github.com/go-errors/errors v1.0.1
|
||||
github.com/go-ldap/ldap/v3 v3.1.10
|
||||
github.com/go-ldap/ldap/v3 v3.2.4
|
||||
github.com/go-ole/go-ole v1.2.4 // indirect
|
||||
github.com/go-sql-driver/mysql v1.5.0
|
||||
github.com/go-test/deep v1.0.7
|
||||
|
|
@ -57,10 +57,10 @@ require (
|
|||
github.com/hashicorp/consul/api v1.4.0
|
||||
github.com/hashicorp/errwrap v1.1.0
|
||||
github.com/hashicorp/go-bindata v3.0.8-0.20180209072458-bf7910af8997+incompatible
|
||||
github.com/hashicorp/go-cleanhttp v0.5.1
|
||||
github.com/hashicorp/go-cleanhttp v0.5.2
|
||||
github.com/hashicorp/go-discover v0.0.0-20201029210230-738cb3105cd0
|
||||
github.com/hashicorp/go-gcp-common v0.6.0
|
||||
github.com/hashicorp/go-hclog v0.14.1
|
||||
github.com/hashicorp/go-hclog v0.15.0
|
||||
github.com/hashicorp/go-kms-wrapping v0.5.16
|
||||
github.com/hashicorp/go-memdb v1.0.2
|
||||
github.com/hashicorp/go-msgpack v0.5.5
|
||||
|
|
@ -78,27 +78,27 @@ require (
|
|||
github.com/hashicorp/raft-autopilot v0.1.2
|
||||
github.com/hashicorp/raft-snapshot v1.0.3
|
||||
github.com/hashicorp/serf v0.9.5 // indirect
|
||||
github.com/hashicorp/vault-plugin-auth-alicloud v0.7.0
|
||||
github.com/hashicorp/vault-plugin-auth-azure v0.6.0
|
||||
github.com/hashicorp/vault-plugin-auth-centrify v0.7.0
|
||||
github.com/hashicorp/vault-plugin-auth-cf v0.7.0
|
||||
github.com/hashicorp/vault-plugin-auth-gcp v0.8.0
|
||||
github.com/hashicorp/vault-plugin-auth-jwt v0.7.2-0.20210212182451-0d0819f8e5e3
|
||||
github.com/hashicorp/vault-plugin-auth-kerberos v0.2.0
|
||||
github.com/hashicorp/vault-plugin-auth-kubernetes v0.8.0
|
||||
github.com/hashicorp/vault-plugin-auth-oci v0.6.0
|
||||
github.com/hashicorp/vault-plugin-auth-alicloud v0.8.0
|
||||
github.com/hashicorp/vault-plugin-auth-azure v0.7.2
|
||||
github.com/hashicorp/vault-plugin-auth-centrify v0.8.0
|
||||
github.com/hashicorp/vault-plugin-auth-cf v0.8.0
|
||||
github.com/hashicorp/vault-plugin-auth-gcp v0.9.0
|
||||
github.com/hashicorp/vault-plugin-auth-jwt v0.9.0
|
||||
github.com/hashicorp/vault-plugin-auth-kerberos v0.3.0
|
||||
github.com/hashicorp/vault-plugin-auth-kubernetes v0.9.0
|
||||
github.com/hashicorp/vault-plugin-auth-oci v0.7.0
|
||||
github.com/hashicorp/vault-plugin-database-couchbase v0.3.0
|
||||
github.com/hashicorp/vault-plugin-database-elasticsearch v0.6.1
|
||||
github.com/hashicorp/vault-plugin-database-mongodbatlas v0.2.1
|
||||
github.com/hashicorp/vault-plugin-database-elasticsearch v0.7.0
|
||||
github.com/hashicorp/vault-plugin-database-mongodbatlas v0.3.0
|
||||
github.com/hashicorp/vault-plugin-database-snowflake v0.1.1
|
||||
github.com/hashicorp/vault-plugin-mock v0.16.1
|
||||
github.com/hashicorp/vault-plugin-secrets-ad v0.8.0
|
||||
github.com/hashicorp/vault-plugin-secrets-alicloud v0.7.0
|
||||
github.com/hashicorp/vault-plugin-secrets-azure v0.8.1
|
||||
github.com/hashicorp/vault-plugin-secrets-gcp v0.6.6-0.20210121193032-bb12fd5092bd
|
||||
github.com/hashicorp/vault-plugin-secrets-gcpkms v0.7.0
|
||||
github.com/hashicorp/vault-plugin-secrets-kv v0.7.0
|
||||
github.com/hashicorp/vault-plugin-secrets-mongodbatlas v0.2.0
|
||||
github.com/hashicorp/vault-plugin-secrets-ad v0.9.0
|
||||
github.com/hashicorp/vault-plugin-secrets-alicloud v0.8.0
|
||||
github.com/hashicorp/vault-plugin-secrets-azure v0.9.0
|
||||
github.com/hashicorp/vault-plugin-secrets-gcp v0.9.0
|
||||
github.com/hashicorp/vault-plugin-secrets-gcpkms v0.8.0
|
||||
github.com/hashicorp/vault-plugin-secrets-kv v0.8.0
|
||||
github.com/hashicorp/vault-plugin-secrets-mongodbatlas v0.3.0
|
||||
github.com/hashicorp/vault-plugin-secrets-openldap v0.4.0
|
||||
github.com/hashicorp/vault-plugin-secrets-terraform v0.1.0
|
||||
github.com/hashicorp/vault/api v1.0.5-0.20210210214158-405eced08457
|
||||
|
|
@ -156,7 +156,6 @@ require (
|
|||
go.etcd.io/etcd v0.5.0-alpha.5.0.20200425165423-262c93980547
|
||||
go.mongodb.org/mongo-driver v1.4.6
|
||||
go.uber.org/atomic v1.6.0
|
||||
go.uber.org/zap v1.14.1 // indirect
|
||||
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83
|
||||
golang.org/x/net v0.0.0-20201110031124-69a78807bb2b
|
||||
golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d
|
||||
|
|
|
|||
110
go.sum
110
go.sum
|
|
@ -42,6 +42,8 @@ github.com/Azure/azure-pipeline-go v0.2.3/go.mod h1:x841ezTBIMG6O3lAcl8ATHnsOPVl
|
|||
github.com/Azure/azure-sdk-for-go v36.2.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
|
||||
github.com/Azure/azure-sdk-for-go v44.0.0+incompatible h1:e82Yv2HNpS0kuyeCrV29OPKvEiqfs2/uJHic3/3iKdg=
|
||||
github.com/Azure/azure-sdk-for-go v44.0.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
|
||||
github.com/Azure/azure-sdk-for-go v51.1.0+incompatible h1:7uk6GWtUqKg6weLv2dbKnzwb0ml1Qn70AdtRccZ543w=
|
||||
github.com/Azure/azure-sdk-for-go v51.1.0+incompatible/go.mod h1:9XXNKU+eRnpl9moKnB4QOLf1HestfXbmab5FXxiDBjc=
|
||||
github.com/Azure/azure-storage-blob-go v0.11.0 h1:WCTHKKNkHlzm7lzUNXRSD11784LwJqdrxnwWJxsJQHg=
|
||||
github.com/Azure/azure-storage-blob-go v0.11.0/go.mod h1:A0u4VjtpgZJ7Y7um/+ix2DHBuEKFC6sEIlj0xc13a4Q=
|
||||
github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78 h1:w+iIsaOQNcT7OZ575w+acHgRric5iCyQh+xv+KJ4HB8=
|
||||
|
|
@ -53,8 +55,8 @@ github.com/Azure/go-autorest/autorest v0.9.2/go.mod h1:xyHB1BMZT0cuDHU7I0+g046+B
|
|||
github.com/Azure/go-autorest/autorest v0.9.3/go.mod h1:GsRuLYvwzLjjjRoWEIyMUaYq8GNUx2nRB378IPt/1p0=
|
||||
github.com/Azure/go-autorest/autorest v0.10.1/go.mod h1:/FALq9T/kS7b5J5qsQ+RSTUdAmGFqi0vUdVNNx8q630=
|
||||
github.com/Azure/go-autorest/autorest v0.11.0/go.mod h1:JFgpikqFJ/MleTTxwepExTKnFUKKszPS8UavbQYUMuw=
|
||||
github.com/Azure/go-autorest/autorest v0.11.10 h1:j5sGbX7uj1ieYYkQ3Mpvewd4DCsEQ+ZeJpqnSM9pjnM=
|
||||
github.com/Azure/go-autorest/autorest v0.11.10/go.mod h1:eipySxLmqSyC5s5k1CLupqet0PSENBEDP93LQ9a8QYw=
|
||||
github.com/Azure/go-autorest/autorest v0.11.17 h1:2zCdHwNgRH+St1J+ZMf66xI8aLr/5KMy+wWLH97zwYM=
|
||||
github.com/Azure/go-autorest/autorest v0.11.17/go.mod h1:eipySxLmqSyC5s5k1CLupqet0PSENBEDP93LQ9a8QYw=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.5.0/go.mod h1:8Z9fGy2MpX0PvDjB1pEgQTmVqjGhiHBW7RJJEciWzS0=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.6.0/go.mod h1:Z6vX6WXXuyieHAXwMj0S6HY6e6wcHn37qQMBQlvY3lc=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.7.0/go.mod h1:Z6vX6WXXuyieHAXwMj0S6HY6e6wcHn37qQMBQlvY3lc=
|
||||
|
|
@ -65,14 +67,20 @@ github.com/Azure/go-autorest/autorest/adal v0.9.0/go.mod h1:/c022QCutn2P7uY+/oQW
|
|||
github.com/Azure/go-autorest/autorest/adal v0.9.2/go.mod h1:/3SMAM86bP6wC9Ev35peQDUeqFZBMH07vvUOmg4z/fE=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.5 h1:Y3bBUV4rTuxenJJs41HU3qmqsb+auo+a3Lz+PlJPpL0=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.5/go.mod h1:B7KF7jKIeC9Mct5spmyCB/A8CG/sEz1vwIRGv/bbw7A=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.11 h1:L4/pmq7poLdsy41Bj1FayKvBhayuWRYkx9HU5i4Ybl0=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.11/go.mod h1:nBKAnTomx8gDtl+3ZCJv2v0KACFHWTB2drffI1B68Pk=
|
||||
github.com/Azure/go-autorest/autorest/azure/auth v0.4.0/go.mod h1:Oo5cRhLvZteXzI2itUm5ziqsoIxRkzrt3t61FeZaS18=
|
||||
github.com/Azure/go-autorest/autorest/azure/auth v0.4.2/go.mod h1:90gmfKdlmKgfjUpnCEpOJzsUEjrWDSLwHIG73tSXddM=
|
||||
github.com/Azure/go-autorest/autorest/azure/auth v0.5.0 h1:nSMjYIe24eBYasAIxt859TxyXef/IqoH+8/g4+LmcVs=
|
||||
github.com/Azure/go-autorest/autorest/azure/auth v0.5.0/go.mod h1:QRTvSZQpxqm8mSErhnbI+tANIBAKP7B+UIE2z4ypUO0=
|
||||
github.com/Azure/go-autorest/autorest/azure/auth v0.5.7 h1:8DQB8yl7aLQuP+nuR5e2RO6454OvFlSTXXaNHshc16s=
|
||||
github.com/Azure/go-autorest/autorest/azure/auth v0.5.7/go.mod h1:AkzUsqkrdmNhfP2i54HqINVQopw0CLDnvHpJ88Zz1eI=
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.3.0/go.mod h1:rNYMNAefZMRowqCV0cVhr/YDW5dD7afFq9nXAXL4ykE=
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.3.1/go.mod h1:ZG5p860J94/0kI9mNJVoIoLgXcirM2gF5i2kWloofxw=
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.4.0 h1:Ml+UCrnlKD+cJmSzrZ/RDcDw86NjkRUpnFh7V5JUhzU=
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.4.0/go.mod h1:JljT387FplPzBA31vUcvsetLKF3pec5bdAxjVU4kI2s=
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.4.2 h1:dMOmEJfkLKW/7JsokJqkyoYSgmR08hi9KrhjZb+JALY=
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.4.2/go.mod h1:7qkJkT+j6b+hIpzMOwPChJhTqS8VbsqqgULzMNRugoM=
|
||||
github.com/Azure/go-autorest/autorest/date v0.1.0/go.mod h1:plvfp3oPSKwf2DNjlBjWF/7vwR+cUD/ELuzDCXwHUVA=
|
||||
github.com/Azure/go-autorest/autorest/date v0.2.0/go.mod h1:vcORJHLJEh643/Ioh9+vPmf1Ij9AEBM5FuBIXLmIy0g=
|
||||
github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
|
||||
|
|
@ -89,12 +97,16 @@ github.com/Azure/go-autorest/autorest/to v0.4.0/go.mod h1:fE8iZBn7LQR7zH/9XU2NcP
|
|||
github.com/Azure/go-autorest/autorest/validation v0.2.0/go.mod h1:3EEqHnBxQGHXRYq3HT1WyXAvT7LLY3tl70hw6tQIbjI=
|
||||
github.com/Azure/go-autorest/autorest/validation v0.3.0 h1:3I9AAI63HfcLtphd9g39ruUwRI+Ca+z/f36KHPFRUss=
|
||||
github.com/Azure/go-autorest/autorest/validation v0.3.0/go.mod h1:yhLgjC0Wda5DYXl6JAsWyUe4KVNffhoDhG0zVzUMo3E=
|
||||
github.com/Azure/go-autorest/autorest/validation v0.3.1 h1:AgyqjAd94fwNAoTjl/WQXg4VvFeRFpO+UhNyRXqF1ac=
|
||||
github.com/Azure/go-autorest/autorest/validation v0.3.1/go.mod h1:yhLgjC0Wda5DYXl6JAsWyUe4KVNffhoDhG0zVzUMo3E=
|
||||
github.com/Azure/go-autorest/logger v0.1.0/go.mod h1:oExouG+K6PryycPJfVSxi/koC6LSNgds39diKLz7Vrc=
|
||||
github.com/Azure/go-autorest/logger v0.2.0 h1:e4RVHVZKC5p6UANLJHkM4OfR1UKZPj8Wt8Pcx+3oqrE=
|
||||
github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
|
||||
github.com/Azure/go-autorest/tracing v0.5.0/go.mod h1:r/s2XiOKccPW3HrqB+W0TQzfbtp2fGCgRFtBroKn4Dk=
|
||||
github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
|
||||
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
|
||||
github.com/Azure/go-ntlmssp v0.0.0-20200615164410-66371956d46c h1:/IBSNwUN8+eKzUzbJPqhK839ygXJ82sde8x3ogr6R28=
|
||||
github.com/Azure/go-ntlmssp v0.0.0-20200615164410-66371956d46c/go.mod h1:chxPXzSsl7ZWRAuOIE23GDNzjWuZquvFlgA8xmpunjU=
|
||||
github.com/BurntSushi/toml v0.3.1 h1:WXkYYl6Yr3qBf1K79EBnL4mak0OimBfB0XUf9Vl28OQ=
|
||||
github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU=
|
||||
github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo=
|
||||
|
|
@ -260,7 +272,6 @@ github.com/containerd/typeurl v0.0.0-20180627222232-a93fcdb778cd/go.mod h1:Cm3kw
|
|||
github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk=
|
||||
github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
|
||||
github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk=
|
||||
github.com/coreos/go-oidc v2.0.0+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc=
|
||||
github.com/coreos/go-oidc v2.2.1+incompatible h1:mh48q/BqXqgjVHpy2ZY7WnWAbenxRjsz9N1i1YxjHAk=
|
||||
github.com/coreos/go-oidc v2.2.1+incompatible/go.mod h1:CgnwVTmzoESiwO9qyAFEMiHoZ1nMCKZlZ9V6mm3/LKc=
|
||||
github.com/coreos/go-semver v0.2.0 h1:3Jm3tLmsgAYcjC+4Up7hJrFBPr+n7rAqYeSw/SZazuY=
|
||||
|
|
@ -298,6 +309,8 @@ github.com/digitalocean/godo v1.7.5 h1:JOQbAO6QT1GGjor0doT0mXefX2FgUDPOpYh2RaXA+
|
|||
github.com/digitalocean/godo v1.7.5/go.mod h1:h6faOIcZ8lWIwNQ+DN7b3CgX4Kwby5T+nbpNqkUIozU=
|
||||
github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
|
||||
github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
|
||||
github.com/dimchansky/utfbom v1.1.1 h1:vV6w1AhK4VMnhBno/TPVCoK9U/LP0PkLCS9tbxHdi/U=
|
||||
github.com/dimchansky/utfbom v1.1.1/go.mod h1:SxdoEBH5qIqFocHMyGOXVAybYJdr71b1Q/j0mACtrfE=
|
||||
github.com/dnaeon/go-vcr v1.0.1 h1:r8L/HqC0Hje5AXMu1ooW8oyQyOFv4GxqpL0nRP7SLLY=
|
||||
github.com/dnaeon/go-vcr v1.0.1/go.mod h1:aBB1+wY4s93YsC3HHjMBMrwTj2R9FHDzUr9KyGc8n1E=
|
||||
github.com/docker/distribution v2.7.1+incompatible h1:a5mlkVzth6W5A4fOsS3D2EO5BUmsJpcB+cRlLU7cSug=
|
||||
|
|
@ -363,6 +376,8 @@ github.com/ghodss/yaml v1.0.1-0.20190212211648-25d852aebe32/go.mod h1:GIjDIg/heH
|
|||
github.com/go-asn1-ber/asn1-ber v1.3.1/go.mod h1:hEBeB/ic+5LoWskz+yKT7vGhhPYkProFKoKdwZRWMe0=
|
||||
github.com/go-asn1-ber/asn1-ber v1.4.1 h1:qP/QDxOtmMoJVgXHCXNzDpA0+wkgYB2x5QoLMVOciyw=
|
||||
github.com/go-asn1-ber/asn1-ber v1.4.1/go.mod h1:hEBeB/ic+5LoWskz+yKT7vGhhPYkProFKoKdwZRWMe0=
|
||||
github.com/go-asn1-ber/asn1-ber v1.5.1 h1:pDbRAunXzIUXfx4CB2QJFv5IuPiuoW+sWvr/Us009o8=
|
||||
github.com/go-asn1-ber/asn1-ber v1.5.1/go.mod h1:hEBeB/ic+5LoWskz+yKT7vGhhPYkProFKoKdwZRWMe0=
|
||||
github.com/go-errors/errors v1.0.1 h1:LUHzmkK3GUKUrL/1gfBUxAHzcev3apQlezX/+O7ma6w=
|
||||
github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q=
|
||||
github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU=
|
||||
|
|
@ -375,6 +390,8 @@ github.com/go-ldap/ldap/v3 v3.1.3/go.mod h1:3rbOH3jRS2u6jg2rJnKAMLE/xQyCKIveG2Sa
|
|||
github.com/go-ldap/ldap/v3 v3.1.7/go.mod h1:5Zun81jBTabRaI8lzN7E1JjyEl1g6zI6u9pd8luAK4Q=
|
||||
github.com/go-ldap/ldap/v3 v3.1.10 h1:7WsKqasmPThNvdl0Q5GPpbTDD/ZD98CfuawrMIuh7qQ=
|
||||
github.com/go-ldap/ldap/v3 v3.1.10/go.mod h1:5Zun81jBTabRaI8lzN7E1JjyEl1g6zI6u9pd8luAK4Q=
|
||||
github.com/go-ldap/ldap/v3 v3.2.4 h1:PFavAq2xTgzo/loE8qNXcQaofAaqIpI4WgaLdv+1l3E=
|
||||
github.com/go-ldap/ldap/v3 v3.2.4/go.mod h1:iYS1MdmrmceOJ1QOTnRXrIs7i3kloqtmGQjRvjKpyMg=
|
||||
github.com/go-ldap/ldif v0.0.0-20200320164324-fd88d9b715b3 h1:sfz1YppV05y4sYaW7kXZtrocU/+vimnIWt4cxAYh7+o=
|
||||
github.com/go-ldap/ldif v0.0.0-20200320164324-fd88d9b715b3/go.mod h1:ZXFhGda43Z2TVbfGZefXyMJzsDHhCh0go3bZUcwTx7o=
|
||||
github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE=
|
||||
|
|
@ -569,6 +586,8 @@ github.com/hashicorp/go-bindata v3.0.8-0.20180209072458-bf7910af8997+incompatibl
|
|||
github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
|
||||
github.com/hashicorp/go-cleanhttp v0.5.1 h1:dH3aiDG9Jvb5r5+bYHsikaOUIpcM0xvgMXVoDkXMzJM=
|
||||
github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
|
||||
github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ=
|
||||
github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48=
|
||||
github.com/hashicorp/go-discover v0.0.0-20201029210230-738cb3105cd0 h1:UgODETBAoROFMSSVgg0v8vVpD9Tol8FtYcAeomcWJtY=
|
||||
github.com/hashicorp/go-discover v0.0.0-20201029210230-738cb3105cd0/go.mod h1:D4eo8/CN92vm9/9UDG+ldX1/fMFa4kpl8qzyTolus8o=
|
||||
github.com/hashicorp/go-gatedio v0.5.0 h1:Jm1X5yP4yCqqWj5L1TgW7iZwCVPGtVc+mro5r/XX7Tg=
|
||||
|
|
@ -583,6 +602,8 @@ github.com/hashicorp/go-hclog v0.9.2/go.mod h1:5CU+agLiy3J7N7QjHK5d05KxGsuXiQLrj
|
|||
github.com/hashicorp/go-hclog v0.12.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ=
|
||||
github.com/hashicorp/go-hclog v0.14.1 h1:nQcJDQwIAGnmoUWp8ubocEX40cCml/17YkF6csQLReU=
|
||||
github.com/hashicorp/go-hclog v0.14.1/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ=
|
||||
github.com/hashicorp/go-hclog v0.15.0 h1:qMuK0wxsoW4D0ddCCYwPSTm4KQv1X1ke3WmPWZ0Mvsk=
|
||||
github.com/hashicorp/go-hclog v0.15.0/go.mod h1:whpDNt7SSdeAju8AWKIWsul05p54N/39EeqMAyrmvFQ=
|
||||
github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
|
||||
github.com/hashicorp/go-immutable-radix v1.1.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
|
||||
github.com/hashicorp/go-immutable-radix v1.3.0 h1:8exGP7ego3OmkfksihtSouGMZ+hQrhxx+FVELeXpVPE=
|
||||
|
|
@ -650,8 +671,6 @@ github.com/hashicorp/nomad/api v0.0.0-20191220223628-edc62acd919d h1:BXqsASWhyiA
|
|||
github.com/hashicorp/nomad/api v0.0.0-20191220223628-edc62acd919d/go.mod h1:WKCL+tLVhN1D+APwH3JiTRZoxcdwRk86bWu1LVCUPaE=
|
||||
github.com/hashicorp/raft v1.0.1/go.mod h1:DVSAWItjLjTOkVbSpWQ0j0kUADIvDaCtBxIcbNAQLkI=
|
||||
github.com/hashicorp/raft v1.1.2-0.20191002163536-9c6bd3e3eb17/go.mod h1:vPAJM8Asw6u8LxC3eJCUZmRP/E4QmUGE1R7g7k8sG/8=
|
||||
github.com/hashicorp/raft v1.1.3-0.20201002073007-f367681f9c48 h1:TpaG+HAdfQyreWNaxIlMU6myVKo2ciBDFdRyc+Z90OI=
|
||||
github.com/hashicorp/raft v1.1.3-0.20201002073007-f367681f9c48/go.mod h1:vPAJM8Asw6u8LxC3eJCUZmRP/E4QmUGE1R7g7k8sG/8=
|
||||
github.com/hashicorp/raft v1.2.0 h1:mHzHIrF0S91d3A7RPBvuqkgB4d/7oFJZyvf1Q4m7GA0=
|
||||
github.com/hashicorp/raft v1.2.0/go.mod h1:vPAJM8Asw6u8LxC3eJCUZmRP/E4QmUGE1R7g7k8sG/8=
|
||||
github.com/hashicorp/raft-autopilot v0.1.2 h1:yeqdUjWLjVJkBM+mcVxqwxi+w+aHsb9cEON2dz69OCs=
|
||||
|
|
@ -664,49 +683,49 @@ github.com/hashicorp/serf v0.9.4 h1:xrZ4ZR0wT5Dz8oQHHdfOzr0ei1jMToWlFFz3hh/DI7I=
|
|||
github.com/hashicorp/serf v0.9.4/go.mod h1:UWDWwZeL5cuWDJdl0C6wrvrUwEqtQ4ZKBKKENpqIUyk=
|
||||
github.com/hashicorp/serf v0.9.5 h1:EBWvyu9tcRszt3Bxp3KNssBMP1KuHWyO51lz9+786iM=
|
||||
github.com/hashicorp/serf v0.9.5/go.mod h1:UWDWwZeL5cuWDJdl0C6wrvrUwEqtQ4ZKBKKENpqIUyk=
|
||||
github.com/hashicorp/vault-plugin-auth-alicloud v0.7.0 h1:qCTaVIb+FUWatLXszACH47Q/yTMrbedHt0CMGX9X41w=
|
||||
github.com/hashicorp/vault-plugin-auth-alicloud v0.7.0/go.mod h1:lyfBMcULXKJfVu8dNo1w9bUikV5oem5HKmJoWwXupnY=
|
||||
github.com/hashicorp/vault-plugin-auth-azure v0.6.0 h1:LWUAYV+Td30+AnwjlBiYDk3j4XMDKOyk+OZyBSXU8tk=
|
||||
github.com/hashicorp/vault-plugin-auth-azure v0.6.0/go.mod h1:xUpcusehlkR1cNbA+wNta9W4slS64pYe7CXx5UYM2OQ=
|
||||
github.com/hashicorp/vault-plugin-auth-centrify v0.7.0 h1:VBAijPjklpKomM+hxmR/rqZG/aZFJe+V5NxbFcZmRqI=
|
||||
github.com/hashicorp/vault-plugin-auth-centrify v0.7.0/go.mod h1:tLY05v1tC+sfeeE6DF8RAC/MGw4gflomYfA28b4VULw=
|
||||
github.com/hashicorp/vault-plugin-auth-cf v0.7.0 h1:DiL63W12LnYxInY3xjCRprlHNkNw+g5v38nh3o9yf38=
|
||||
github.com/hashicorp/vault-plugin-auth-cf v0.7.0/go.mod h1:exPUMj8yNohKM7yRiHa7OfxQmyDI9Pj8+08qB4hGlVw=
|
||||
github.com/hashicorp/vault-plugin-auth-alicloud v0.8.0 h1:UZH3bYGanW5UNpGloqS4FUnQH/ZphIiL5uSsVAUj1bY=
|
||||
github.com/hashicorp/vault-plugin-auth-alicloud v0.8.0/go.mod h1:lyfBMcULXKJfVu8dNo1w9bUikV5oem5HKmJoWwXupnY=
|
||||
github.com/hashicorp/vault-plugin-auth-azure v0.7.2 h1:Fxd6tVYtNaBSDhP+RKxSRZ7VsBekZQKmyXwcPSWTlm0=
|
||||
github.com/hashicorp/vault-plugin-auth-azure v0.7.2/go.mod h1:B8T1Xfy4SDWnor9CABIPmGseyBCOsuxJTtloxnDevQM=
|
||||
github.com/hashicorp/vault-plugin-auth-centrify v0.8.0 h1:6Gxp/O+JqNhGKUavjLS02EehiRYskijnAiFFkpkMcxk=
|
||||
github.com/hashicorp/vault-plugin-auth-centrify v0.8.0/go.mod h1:tLY05v1tC+sfeeE6DF8RAC/MGw4gflomYfA28b4VULw=
|
||||
github.com/hashicorp/vault-plugin-auth-cf v0.8.0 h1:eLMI+dLuvuIWpv8yjnL+hsxJN3vir1S7jv5Ae2vil0A=
|
||||
github.com/hashicorp/vault-plugin-auth-cf v0.8.0/go.mod h1:exPUMj8yNohKM7yRiHa7OfxQmyDI9Pj8+08qB4hGlVw=
|
||||
github.com/hashicorp/vault-plugin-auth-gcp v0.5.1/go.mod h1:eLj92eX8MPI4vY1jaazVLF2sVbSAJ3LRHLRhF/pUmlI=
|
||||
github.com/hashicorp/vault-plugin-auth-gcp v0.8.0 h1:E9EHvC9jCDNix/pB9NKYYLMUkpfv65TSDk2rVvtkdzU=
|
||||
github.com/hashicorp/vault-plugin-auth-gcp v0.8.0/go.mod h1:sHDguHmyGScoalGLEjuxvDCrMPVlw2c3f+ieeiHcv6w=
|
||||
github.com/hashicorp/vault-plugin-auth-jwt v0.7.2-0.20210212182451-0d0819f8e5e3 h1:Lc2wDPfAiiiFRAkQlu1aXrBRHn/BFvjAXZXKrmtY7zs=
|
||||
github.com/hashicorp/vault-plugin-auth-jwt v0.7.2-0.20210212182451-0d0819f8e5e3/go.mod h1:Gn6ELc1X5nmZ/pxoXf0nA4lG2gwuGnY6SNyW40tR/ws=
|
||||
github.com/hashicorp/vault-plugin-auth-kerberos v0.2.0 h1:7ct50ngVFTeO7EJ3N9PvPHeHc+2cANTHi2+9RwIUIHM=
|
||||
github.com/hashicorp/vault-plugin-auth-kerberos v0.2.0/go.mod h1:IM/n7LY1rIM4MVzOfSH6cRmY/C2rGkrjGrEr0B/yO9c=
|
||||
github.com/hashicorp/vault-plugin-auth-kubernetes v0.8.0 h1:v1jOqR70chxRxONey7g/v0/57MneP05z2dfw6qmlE+8=
|
||||
github.com/hashicorp/vault-plugin-auth-kubernetes v0.8.0/go.mod h1:2c/k3nsoGPKV+zpAWCiajt4e66vncEq8Li/eKLqErAc=
|
||||
github.com/hashicorp/vault-plugin-auth-oci v0.6.0 h1:ag69AcGbWvFADQ0TQxiJiJAztCiY5/CXMItF02oi5oY=
|
||||
github.com/hashicorp/vault-plugin-auth-oci v0.6.0/go.mod h1:Cn5cjR279Y+snw8LTaiLTko3KGrbigRbsQPOd2D5xDw=
|
||||
github.com/hashicorp/vault-plugin-auth-gcp v0.9.0 h1:57uJ2Vqo+M+W7pD8xEONKJ1BBGS8V4xpm7VU56A9RWA=
|
||||
github.com/hashicorp/vault-plugin-auth-gcp v0.9.0/go.mod h1:sHDguHmyGScoalGLEjuxvDCrMPVlw2c3f+ieeiHcv6w=
|
||||
github.com/hashicorp/vault-plugin-auth-jwt v0.9.0 h1:82+2S9k06YAT/+yNJtDZQ+X5Hny+WZqtEkdhp2svlDI=
|
||||
github.com/hashicorp/vault-plugin-auth-jwt v0.9.0/go.mod h1:Gn6ELc1X5nmZ/pxoXf0nA4lG2gwuGnY6SNyW40tR/ws=
|
||||
github.com/hashicorp/vault-plugin-auth-kerberos v0.3.0 h1:QxW0gRevydrNfRvo1qI6p0jQkhedLUgiWqpCN36RXoQ=
|
||||
github.com/hashicorp/vault-plugin-auth-kerberos v0.3.0/go.mod h1:h+7pLm4Z2EeKHOGPefX0bGzdUQCMBUlvM/BpSMNgTFw=
|
||||
github.com/hashicorp/vault-plugin-auth-kubernetes v0.9.0 h1:X/eXFuJqVW8YN73ohTaI5YyCwcjd6C3mpnMv/elkNrw=
|
||||
github.com/hashicorp/vault-plugin-auth-kubernetes v0.9.0/go.mod h1:2c/k3nsoGPKV+zpAWCiajt4e66vncEq8Li/eKLqErAc=
|
||||
github.com/hashicorp/vault-plugin-auth-oci v0.7.0 h1:saDgrjPcGbZ3ts2mZ/Cpf3PKaRPQ3PDo5/rOo9Xms7U=
|
||||
github.com/hashicorp/vault-plugin-auth-oci v0.7.0/go.mod h1:Cn5cjR279Y+snw8LTaiLTko3KGrbigRbsQPOd2D5xDw=
|
||||
github.com/hashicorp/vault-plugin-database-couchbase v0.3.0 h1:C3Lfwr7xtdhOTnOf+UgFZWDyBwTGqk0BuzG2GhNHD6k=
|
||||
github.com/hashicorp/vault-plugin-database-couchbase v0.3.0/go.mod h1:Seivjno/BOtkqX41d/DDYtTg6zNoxIgNaUVZ3ObZYi4=
|
||||
github.com/hashicorp/vault-plugin-database-elasticsearch v0.6.1 h1:C3NF3pVF7/Emxy2r6nPDkR5Njfh+uviFggcr4yHaDhs=
|
||||
github.com/hashicorp/vault-plugin-database-elasticsearch v0.6.1/go.mod h1:813Nvr1IQqAKdlk3yIY97M5WyxMhWOrXtYioPf9PqJg=
|
||||
github.com/hashicorp/vault-plugin-database-mongodbatlas v0.2.1 h1:Yc8ZJJINvCH6JcJ8uvNkZ6W33KYzVdG4zI98dvbQ8lE=
|
||||
github.com/hashicorp/vault-plugin-database-mongodbatlas v0.2.1/go.mod h1:2So20ndRRsDAMDyG52az6nd7NwFOZTQER9EsrgPCgVg=
|
||||
github.com/hashicorp/vault-plugin-database-elasticsearch v0.7.0 h1:EYicFs5dl4Ax1uQMw+EfbCCrarScVrqdGS471KKXDDo=
|
||||
github.com/hashicorp/vault-plugin-database-elasticsearch v0.7.0/go.mod h1:813Nvr1IQqAKdlk3yIY97M5WyxMhWOrXtYioPf9PqJg=
|
||||
github.com/hashicorp/vault-plugin-database-mongodbatlas v0.3.0 h1:qSTM0f71zhyYILdw2HiVw5zUumC+5QeI0F2vzDJvcUY=
|
||||
github.com/hashicorp/vault-plugin-database-mongodbatlas v0.3.0/go.mod h1:ewrdsH4iFG5TGZu7euYf4BCzLl+hoFkaKaOGuF0UcjI=
|
||||
github.com/hashicorp/vault-plugin-database-snowflake v0.1.1 h1:QKNjvd1GuI69u7ZLNTnvZ2LoBg9ENX7C/U+sgH40QBU=
|
||||
github.com/hashicorp/vault-plugin-database-snowflake v0.1.1/go.mod h1:gUfFbYrFFxITKxeLJe2IHPnNkmSG5ldVF1OOxp1WW3c=
|
||||
github.com/hashicorp/vault-plugin-mock v0.16.1 h1:5QQvSUHxDjEEbrd2REOeacqyJnCLPD51IQzy71hx8P0=
|
||||
github.com/hashicorp/vault-plugin-mock v0.16.1/go.mod h1:83G4JKlOwUtxVourn5euQfze3ZWyXcUiLj2wqrKSDIM=
|
||||
github.com/hashicorp/vault-plugin-secrets-ad v0.8.0 h1:SBOxEjYtxkipmp8AC7Yy3vjBVM5H24YM48WKCSCV+zA=
|
||||
github.com/hashicorp/vault-plugin-secrets-ad v0.8.0/go.mod h1:L5L6NoJFxRvgxhuA2sWhloc3sbgmE7KxhNcoRxcaH9U=
|
||||
github.com/hashicorp/vault-plugin-secrets-alicloud v0.7.0 h1:VoB3Q11LX+wF5w5TC8j3LYh6PNfeL1XM0zQAMaT04sY=
|
||||
github.com/hashicorp/vault-plugin-secrets-alicloud v0.7.0/go.mod h1:SSkKpSTOMnX84PfgYiWHgwVg+YMhxHNjo+YCJGNBoZk=
|
||||
github.com/hashicorp/vault-plugin-secrets-azure v0.8.1 h1:OVPAfhr4NVNu/CP8lR+QEk3l4uocP+gHRKQtKiB1AUo=
|
||||
github.com/hashicorp/vault-plugin-secrets-azure v0.8.1/go.mod h1:4jCVjTG809NCQ8mrSnbBtX17gX1Iush+558BVO6MJeo=
|
||||
github.com/hashicorp/vault-plugin-secrets-gcp v0.6.6-0.20210121193032-bb12fd5092bd h1:l+yD2mcdsZrtUhakzylE/7cMN6bJMZJU06l2w4MeXNA=
|
||||
github.com/hashicorp/vault-plugin-secrets-gcp v0.6.6-0.20210121193032-bb12fd5092bd/go.mod h1:psRQ/dm5XatoUKLDUeWrpP9icMJNtu/jmscUr37YGK4=
|
||||
github.com/hashicorp/vault-plugin-secrets-gcpkms v0.7.0 h1:dKPQIr6tLcMmhNKdc2A9pbwaIFLooC80UfNZL+jWMlA=
|
||||
github.com/hashicorp/vault-plugin-secrets-gcpkms v0.7.0/go.mod h1:hhwps56f2ATeC4Smgghrc5JH9dXR31b4ehSf1HblP5Q=
|
||||
github.com/hashicorp/vault-plugin-secrets-kv v0.7.0 h1:Sq5CmKWxQu+MtO6AXYM+STPHGnrGD50iKuwzaw87OVM=
|
||||
github.com/hashicorp/vault-plugin-secrets-kv v0.7.0/go.mod h1:B/Cybh5aVF7LNAMHwVBxY8t7r2eL0C6HVGgTyP4nKK4=
|
||||
github.com/hashicorp/vault-plugin-secrets-mongodbatlas v0.2.0 h1:uTtKxt5qfwTj6PqwnwPdU0fg1lIaaoqTtauuNpI2Epc=
|
||||
github.com/hashicorp/vault-plugin-secrets-mongodbatlas v0.2.0/go.mod h1:JOqn2mWJJbTp9NaC0CSCc3q5HQA99LfeSqgpC3YS+oA=
|
||||
github.com/hashicorp/vault-plugin-secrets-ad v0.9.0 h1:pmui4uYI7zol5yk5u0crqSClqDmhdHp3LVh7vQssrQ0=
|
||||
github.com/hashicorp/vault-plugin-secrets-ad v0.9.0/go.mod h1:L5L6NoJFxRvgxhuA2sWhloc3sbgmE7KxhNcoRxcaH9U=
|
||||
github.com/hashicorp/vault-plugin-secrets-alicloud v0.8.0 h1:dg1vrZl+XwGipfjet7M9UqGM8nCDx4FNnN7zlqiHQWU=
|
||||
github.com/hashicorp/vault-plugin-secrets-alicloud v0.8.0/go.mod h1:SSkKpSTOMnX84PfgYiWHgwVg+YMhxHNjo+YCJGNBoZk=
|
||||
github.com/hashicorp/vault-plugin-secrets-azure v0.9.0 h1:RfJsZ9DoOhJutvHx3KDSuCXZqZEWKyu3Pksa9F5fjYo=
|
||||
github.com/hashicorp/vault-plugin-secrets-azure v0.9.0/go.mod h1:4jCVjTG809NCQ8mrSnbBtX17gX1Iush+558BVO6MJeo=
|
||||
github.com/hashicorp/vault-plugin-secrets-gcp v0.9.0 h1:gfaTe+QNNk+wZLec0k9pUt2VSBKPB237F/Dh0a1u8ic=
|
||||
github.com/hashicorp/vault-plugin-secrets-gcp v0.9.0/go.mod h1:psRQ/dm5XatoUKLDUeWrpP9icMJNtu/jmscUr37YGK4=
|
||||
github.com/hashicorp/vault-plugin-secrets-gcpkms v0.8.0 h1:yoMAcYkdvuo0LMiPaD4OCNRO8ekkYVMhSo+GswZrgb4=
|
||||
github.com/hashicorp/vault-plugin-secrets-gcpkms v0.8.0/go.mod h1:hhwps56f2ATeC4Smgghrc5JH9dXR31b4ehSf1HblP5Q=
|
||||
github.com/hashicorp/vault-plugin-secrets-kv v0.8.0 h1:9AWMN1+n4z6p/YX6d5/gaD5QulymrP11Q2XlNa4TXT0=
|
||||
github.com/hashicorp/vault-plugin-secrets-kv v0.8.0/go.mod h1:B/Cybh5aVF7LNAMHwVBxY8t7r2eL0C6HVGgTyP4nKK4=
|
||||
github.com/hashicorp/vault-plugin-secrets-mongodbatlas v0.3.0 h1:fge/+aIH0yrTPpfpkuCoQ8wV1gUcr3t8J9T5IFnbtZo=
|
||||
github.com/hashicorp/vault-plugin-secrets-mongodbatlas v0.3.0/go.mod h1:4mdgPqlkO+vfFX1cFAWcxkeqz6JAtZgKxL/67q/58Oo=
|
||||
github.com/hashicorp/vault-plugin-secrets-openldap v0.4.0 h1:av7AhykZLA/lSQpxStGP+bGdNNuAEhAejZdBVrzw3p0=
|
||||
github.com/hashicorp/vault-plugin-secrets-openldap v0.4.0/go.mod h1:GiFI8Bxwx3+fn0A3SyVp9XdYQhm3cOgN8GzwKxyJ9So=
|
||||
github.com/hashicorp/vault-plugin-secrets-terraform v0.1.0 h1:g+r6TKJsD2aM0kUNWByuL4ffZTbZH/xO/sqDwTltOu0=
|
||||
|
|
@ -1016,7 +1035,6 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN
|
|||
github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI=
|
||||
github.com/posener/complete v1.2.3 h1:NP0eAhjcjImqslEwo/1hq7gpajME0fTLTezBKDqfXqo=
|
||||
github.com/posener/complete v1.2.3/go.mod h1:WZIdtGGp+qx0sLrYKtIRAruyNpv6hFCicSgv7Sy7s/s=
|
||||
github.com/pquerna/cachecontrol v0.0.0-20180517163645-1555304b9b35/go.mod h1:prYjPmNq4d1NPVmpShWobRqXY3q7Vp+80DqgxxUrUIA=
|
||||
github.com/pquerna/cachecontrol v0.0.0-20201205024021-ac21108117ac h1:jWKYCNlX4J5s8M0nHYkh7Y7c9gRVDEb3mq51j5J0F5M=
|
||||
github.com/pquerna/cachecontrol v0.0.0-20201205024021-ac21108117ac/go.mod h1:hoLfEwdY11HjRfKFH6KqnPsfxlo3BP6bJehpDv8t6sQ=
|
||||
github.com/pquerna/otp v1.2.1-0.20191009055518-468c2dd2b58d h1:PinQItctnaL2LtkaSM678+ZLLy5TajwOeXzWvYC7tII=
|
||||
|
|
@ -1198,8 +1216,8 @@ go.etcd.io/bbolt v1.3.5/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ=
|
|||
go.etcd.io/etcd v0.0.0-20191023171146-3cf2f69b5738/go.mod h1:dnLIgRNXwCJa5e+c6mIZCrds/GIG4ncV9HhK5PX7jPg=
|
||||
go.etcd.io/etcd v0.5.0-alpha.5.0.20200425165423-262c93980547 h1:s71VGheLtWmCYsnNjf+s7XE8HsrZnd3EYGrLGWVm7nY=
|
||||
go.etcd.io/etcd v0.5.0-alpha.5.0.20200425165423-262c93980547/go.mod h1:YoUyTScD3Vcv2RBm3eGVOq7i1ULiz3OuXoQFWOirmAM=
|
||||
go.mongodb.org/atlas v0.5.0 h1:WoeXdXSLCyquhSqSqTa0PwpjxWZbm70E1Gkbx+w3Sco=
|
||||
go.mongodb.org/atlas v0.5.0/go.mod h1:CIaBeO8GLHhtYLw7xSSXsw7N90Z4MFY87Oy9qcPyuEs=
|
||||
go.mongodb.org/atlas v0.7.1 h1:hNBtwtKgmhB9vmSX/JyN/cArmhzyy4ihKpmXSMIc4mw=
|
||||
go.mongodb.org/atlas v0.7.1/go.mod h1:CIaBeO8GLHhtYLw7xSSXsw7N90Z4MFY87Oy9qcPyuEs=
|
||||
go.mongodb.org/mongo-driver v1.4.2 h1:WlnEglfTg/PfPq4WXs2Vkl/5ICC6hoG8+r+LraPmGk4=
|
||||
go.mongodb.org/mongo-driver v1.4.2/go.mod h1:WcMNYLx/IlOxLe6JRJiv2uXuCz6zBLndR4SoGjYphSc=
|
||||
go.mongodb.org/mongo-driver v1.4.6 h1:rh7GdYmDrb8AQSkF8yteAus8qYOgOASWDOv1BWqBXkU=
|
||||
|
|
@ -1218,6 +1236,7 @@ go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
|
|||
go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ=
|
||||
go.uber.org/atomic v1.6.0 h1:Ezj3JGmsOnG1MoRWQkPBsKLe9DwWD9QeXzTRzzldNVk=
|
||||
go.uber.org/atomic v1.6.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ=
|
||||
go.uber.org/goleak v1.1.10 h1:z+mqJhf6ss6BSfSM671tgKyZBFPTTJM+HLxnhPC3wu0=
|
||||
go.uber.org/goleak v1.1.10/go.mod h1:8a7PlsEVH3e/a/GLqe5IIrQx6GzcnRmZEufDUTk4A7A=
|
||||
go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0=
|
||||
go.uber.org/multierr v1.3.0/go.mod h1:VgVr7evmIr6uPjLBxg28wmKNXyqE9akIJ5XnfpiKl+4=
|
||||
|
|
@ -1256,6 +1275,7 @@ golang.org/x/crypto v0.0.0-20200604202706-70a84ac30bf9/go.mod h1:LzIPMQfyMNhhGPh
|
|||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0 h1:hb9wdF1z5waM+dSIICn1l0DkLVDT3hqhhQsDNUmHPRE=
|
||||
golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
|
||||
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83 h1:/ZScEX8SfEmUGRHs0gxpqteO5nfNW6axyZbBdw9A12g=
|
||||
golang.org/x/crypto v0.0.0-20210220033148-5ea612d1eb83/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
|
||||
golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA=
|
||||
|
|
@ -1611,8 +1631,6 @@ gopkg.in/ini.v1 v1.42.0 h1:7N3gPTt50s8GuLortA00n8AqRTk75qOP98+mTPpgzRk=
|
|||
gopkg.in/ini.v1 v1.42.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k=
|
||||
gopkg.in/jcmturner/goidentity.v3 v3.0.0 h1:1duIyWiTaYvVx3YX2CYtpJbUFd7/UuPYCfgXtQ3VTbI=
|
||||
gopkg.in/jcmturner/goidentity.v3 v3.0.0/go.mod h1:oG2kH0IvSYNIu80dVAyu/yoefjq1mNfM5bm88whjWx4=
|
||||
gopkg.in/ldap.v3 v3.0.3 h1:YKRHW/2sIl05JsCtx/5ZuUueFuJyoj/6+DGXe3wp6ro=
|
||||
gopkg.in/ldap.v3 v3.0.3/go.mod h1:oxD7NyBuxchC+SgJDE1Q5Od05eGt29SDQVBmV+HYbzw=
|
||||
gopkg.in/mgo.v2 v2.0.0-20180705113604-9856a29383ce h1:xcEWjVhvbDy+nHP67nPDDpbYrY+ILlfndk4bRioVHaU=
|
||||
gopkg.in/mgo.v2 v2.0.0-20180705113604-9856a29383ce/go.mod h1:yeKp02qBN3iKW1OzL3MGk2IdtZzaj7SFntXj72NppTA=
|
||||
gopkg.in/ory-am/dockertest.v3 v3.3.4 h1:oen8RiwxVNxtQ1pRoV4e4jqh6UjNsOuIZ1NXns6jdcw=
|
||||
|
|
|
|||
370
vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/CHANGELOG.md
generated
vendored
Normal file
370
vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/CHANGELOG.md
generated
vendored
Normal file
|
|
@ -0,0 +1,370 @@
|
|||
Generated from https://github.com/Azure/azure-rest-api-specs/tree/3c764635e7d442b3e74caf593029fcd440b3ef82/specification/compute/resource-manager/readme.md tag: `package-2019-07`
|
||||
|
||||
Code generator @microsoft.azure/autorest.go@2.1.168
|
||||
|
||||
## Breaking Changes
|
||||
|
||||
### Removed Funcs
|
||||
|
||||
1. *ContainerServicesCreateOrUpdateFuture.Result(ContainerServicesClient) (ContainerService, error)
|
||||
1. *ContainerServicesDeleteFuture.Result(ContainerServicesClient) (autorest.Response, error)
|
||||
1. *DedicatedHostsCreateOrUpdateFuture.Result(DedicatedHostsClient) (DedicatedHost, error)
|
||||
1. *DedicatedHostsDeleteFuture.Result(DedicatedHostsClient) (autorest.Response, error)
|
||||
1. *DedicatedHostsUpdateFuture.Result(DedicatedHostsClient) (DedicatedHost, error)
|
||||
1. *DiskEncryptionSetsCreateOrUpdateFuture.Result(DiskEncryptionSetsClient) (DiskEncryptionSet, error)
|
||||
1. *DiskEncryptionSetsDeleteFuture.Result(DiskEncryptionSetsClient) (autorest.Response, error)
|
||||
1. *DiskEncryptionSetsUpdateFuture.Result(DiskEncryptionSetsClient) (DiskEncryptionSet, error)
|
||||
1. *DisksCreateOrUpdateFuture.Result(DisksClient) (Disk, error)
|
||||
1. *DisksDeleteFuture.Result(DisksClient) (autorest.Response, error)
|
||||
1. *DisksGrantAccessFuture.Result(DisksClient) (AccessURI, error)
|
||||
1. *DisksRevokeAccessFuture.Result(DisksClient) (autorest.Response, error)
|
||||
1. *DisksUpdateFuture.Result(DisksClient) (Disk, error)
|
||||
1. *GalleriesCreateOrUpdateFuture.Result(GalleriesClient) (Gallery, error)
|
||||
1. *GalleriesDeleteFuture.Result(GalleriesClient) (autorest.Response, error)
|
||||
1. *GalleriesUpdateFuture.Result(GalleriesClient) (Gallery, error)
|
||||
1. *GalleryApplicationVersionsCreateOrUpdateFuture.Result(GalleryApplicationVersionsClient) (GalleryApplicationVersion, error)
|
||||
1. *GalleryApplicationVersionsDeleteFuture.Result(GalleryApplicationVersionsClient) (autorest.Response, error)
|
||||
1. *GalleryApplicationVersionsUpdateFuture.Result(GalleryApplicationVersionsClient) (GalleryApplicationVersion, error)
|
||||
1. *GalleryApplicationsCreateOrUpdateFuture.Result(GalleryApplicationsClient) (GalleryApplication, error)
|
||||
1. *GalleryApplicationsDeleteFuture.Result(GalleryApplicationsClient) (autorest.Response, error)
|
||||
1. *GalleryApplicationsUpdateFuture.Result(GalleryApplicationsClient) (GalleryApplication, error)
|
||||
1. *GalleryImageVersionsCreateOrUpdateFuture.Result(GalleryImageVersionsClient) (GalleryImageVersion, error)
|
||||
1. *GalleryImageVersionsDeleteFuture.Result(GalleryImageVersionsClient) (autorest.Response, error)
|
||||
1. *GalleryImageVersionsUpdateFuture.Result(GalleryImageVersionsClient) (GalleryImageVersion, error)
|
||||
1. *GalleryImagesCreateOrUpdateFuture.Result(GalleryImagesClient) (GalleryImage, error)
|
||||
1. *GalleryImagesDeleteFuture.Result(GalleryImagesClient) (autorest.Response, error)
|
||||
1. *GalleryImagesUpdateFuture.Result(GalleryImagesClient) (GalleryImage, error)
|
||||
1. *ImagesCreateOrUpdateFuture.Result(ImagesClient) (Image, error)
|
||||
1. *ImagesDeleteFuture.Result(ImagesClient) (autorest.Response, error)
|
||||
1. *ImagesUpdateFuture.Result(ImagesClient) (Image, error)
|
||||
1. *LogAnalyticsExportRequestRateByIntervalFuture.Result(LogAnalyticsClient) (LogAnalyticsOperationResult, error)
|
||||
1. *LogAnalyticsExportThrottledRequestsFuture.Result(LogAnalyticsClient) (LogAnalyticsOperationResult, error)
|
||||
1. *SnapshotsCreateOrUpdateFuture.Result(SnapshotsClient) (Snapshot, error)
|
||||
1. *SnapshotsDeleteFuture.Result(SnapshotsClient) (autorest.Response, error)
|
||||
1. *SnapshotsGrantAccessFuture.Result(SnapshotsClient) (AccessURI, error)
|
||||
1. *SnapshotsRevokeAccessFuture.Result(SnapshotsClient) (autorest.Response, error)
|
||||
1. *SnapshotsUpdateFuture.Result(SnapshotsClient) (Snapshot, error)
|
||||
1. *VirtualMachineExtensionsCreateOrUpdateFuture.Result(VirtualMachineExtensionsClient) (VirtualMachineExtension, error)
|
||||
1. *VirtualMachineExtensionsDeleteFuture.Result(VirtualMachineExtensionsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineExtensionsUpdateFuture.Result(VirtualMachineExtensionsClient) (VirtualMachineExtension, error)
|
||||
1. *VirtualMachineScaleSetExtensionsCreateOrUpdateFuture.Result(VirtualMachineScaleSetExtensionsClient) (VirtualMachineScaleSetExtension, error)
|
||||
1. *VirtualMachineScaleSetExtensionsDeleteFuture.Result(VirtualMachineScaleSetExtensionsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetExtensionsUpdateFuture.Result(VirtualMachineScaleSetExtensionsClient) (VirtualMachineScaleSetExtension, error)
|
||||
1. *VirtualMachineScaleSetRollingUpgradesCancelFuture.Result(VirtualMachineScaleSetRollingUpgradesClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetRollingUpgradesStartExtensionUpgradeFuture.Result(VirtualMachineScaleSetRollingUpgradesClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetRollingUpgradesStartOSUpgradeFuture.Result(VirtualMachineScaleSetRollingUpgradesClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture.Result(VirtualMachineScaleSetVMExtensionsClient) (VirtualMachineExtension, error)
|
||||
1. *VirtualMachineScaleSetVMExtensionsDeleteFuture.Result(VirtualMachineScaleSetVMExtensionsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMExtensionsUpdateFuture.Result(VirtualMachineScaleSetVMExtensionsClient) (VirtualMachineExtension, error)
|
||||
1. *VirtualMachineScaleSetVMsDeallocateFuture.Result(VirtualMachineScaleSetVMsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMsDeleteFuture.Result(VirtualMachineScaleSetVMsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMsPerformMaintenanceFuture.Result(VirtualMachineScaleSetVMsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMsPowerOffFuture.Result(VirtualMachineScaleSetVMsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMsRedeployFuture.Result(VirtualMachineScaleSetVMsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMsReimageAllFuture.Result(VirtualMachineScaleSetVMsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMsReimageFuture.Result(VirtualMachineScaleSetVMsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMsRestartFuture.Result(VirtualMachineScaleSetVMsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMsRunCommandFuture.Result(VirtualMachineScaleSetVMsClient) (RunCommandResult, error)
|
||||
1. *VirtualMachineScaleSetVMsStartFuture.Result(VirtualMachineScaleSetVMsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetVMsUpdateFuture.Result(VirtualMachineScaleSetVMsClient) (VirtualMachineScaleSetVM, error)
|
||||
1. *VirtualMachineScaleSetsCreateOrUpdateFuture.Result(VirtualMachineScaleSetsClient) (VirtualMachineScaleSet, error)
|
||||
1. *VirtualMachineScaleSetsDeallocateFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetsDeleteFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetsDeleteInstancesFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetsPerformMaintenanceFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetsPowerOffFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetsRedeployFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetsReimageAllFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetsReimageFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetsRestartFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetsStartFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachineScaleSetsUpdateFuture.Result(VirtualMachineScaleSetsClient) (VirtualMachineScaleSet, error)
|
||||
1. *VirtualMachineScaleSetsUpdateInstancesFuture.Result(VirtualMachineScaleSetsClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesCaptureFuture.Result(VirtualMachinesClient) (VirtualMachineCaptureResult, error)
|
||||
1. *VirtualMachinesConvertToManagedDisksFuture.Result(VirtualMachinesClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesCreateOrUpdateFuture.Result(VirtualMachinesClient) (VirtualMachine, error)
|
||||
1. *VirtualMachinesDeallocateFuture.Result(VirtualMachinesClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesDeleteFuture.Result(VirtualMachinesClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesPerformMaintenanceFuture.Result(VirtualMachinesClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesPowerOffFuture.Result(VirtualMachinesClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesReapplyFuture.Result(VirtualMachinesClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesRedeployFuture.Result(VirtualMachinesClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesReimageFuture.Result(VirtualMachinesClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesRestartFuture.Result(VirtualMachinesClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesRunCommandFuture.Result(VirtualMachinesClient) (RunCommandResult, error)
|
||||
1. *VirtualMachinesStartFuture.Result(VirtualMachinesClient) (autorest.Response, error)
|
||||
1. *VirtualMachinesUpdateFuture.Result(VirtualMachinesClient) (VirtualMachine, error)
|
||||
|
||||
## Struct Changes
|
||||
|
||||
### Removed Struct Fields
|
||||
|
||||
1. ContainerServicesCreateOrUpdateFuture.azure.Future
|
||||
1. ContainerServicesDeleteFuture.azure.Future
|
||||
1. DedicatedHostsCreateOrUpdateFuture.azure.Future
|
||||
1. DedicatedHostsDeleteFuture.azure.Future
|
||||
1. DedicatedHostsUpdateFuture.azure.Future
|
||||
1. DiskEncryptionSetsCreateOrUpdateFuture.azure.Future
|
||||
1. DiskEncryptionSetsDeleteFuture.azure.Future
|
||||
1. DiskEncryptionSetsUpdateFuture.azure.Future
|
||||
1. DisksCreateOrUpdateFuture.azure.Future
|
||||
1. DisksDeleteFuture.azure.Future
|
||||
1. DisksGrantAccessFuture.azure.Future
|
||||
1. DisksRevokeAccessFuture.azure.Future
|
||||
1. DisksUpdateFuture.azure.Future
|
||||
1. GalleriesCreateOrUpdateFuture.azure.Future
|
||||
1. GalleriesDeleteFuture.azure.Future
|
||||
1. GalleriesUpdateFuture.azure.Future
|
||||
1. GalleryApplicationVersionsCreateOrUpdateFuture.azure.Future
|
||||
1. GalleryApplicationVersionsDeleteFuture.azure.Future
|
||||
1. GalleryApplicationVersionsUpdateFuture.azure.Future
|
||||
1. GalleryApplicationsCreateOrUpdateFuture.azure.Future
|
||||
1. GalleryApplicationsDeleteFuture.azure.Future
|
||||
1. GalleryApplicationsUpdateFuture.azure.Future
|
||||
1. GalleryImageVersionsCreateOrUpdateFuture.azure.Future
|
||||
1. GalleryImageVersionsDeleteFuture.azure.Future
|
||||
1. GalleryImageVersionsUpdateFuture.azure.Future
|
||||
1. GalleryImagesCreateOrUpdateFuture.azure.Future
|
||||
1. GalleryImagesDeleteFuture.azure.Future
|
||||
1. GalleryImagesUpdateFuture.azure.Future
|
||||
1. ImagesCreateOrUpdateFuture.azure.Future
|
||||
1. ImagesDeleteFuture.azure.Future
|
||||
1. ImagesUpdateFuture.azure.Future
|
||||
1. LogAnalyticsExportRequestRateByIntervalFuture.azure.Future
|
||||
1. LogAnalyticsExportThrottledRequestsFuture.azure.Future
|
||||
1. SnapshotsCreateOrUpdateFuture.azure.Future
|
||||
1. SnapshotsDeleteFuture.azure.Future
|
||||
1. SnapshotsGrantAccessFuture.azure.Future
|
||||
1. SnapshotsRevokeAccessFuture.azure.Future
|
||||
1. SnapshotsUpdateFuture.azure.Future
|
||||
1. VirtualMachineExtensionsCreateOrUpdateFuture.azure.Future
|
||||
1. VirtualMachineExtensionsDeleteFuture.azure.Future
|
||||
1. VirtualMachineExtensionsUpdateFuture.azure.Future
|
||||
1. VirtualMachineScaleSetExtensionsCreateOrUpdateFuture.azure.Future
|
||||
1. VirtualMachineScaleSetExtensionsDeleteFuture.azure.Future
|
||||
1. VirtualMachineScaleSetExtensionsUpdateFuture.azure.Future
|
||||
1. VirtualMachineScaleSetRollingUpgradesCancelFuture.azure.Future
|
||||
1. VirtualMachineScaleSetRollingUpgradesStartExtensionUpgradeFuture.azure.Future
|
||||
1. VirtualMachineScaleSetRollingUpgradesStartOSUpgradeFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMExtensionsDeleteFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMExtensionsUpdateFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsDeallocateFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsDeleteFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsPerformMaintenanceFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsPowerOffFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsRedeployFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsReimageAllFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsReimageFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsRestartFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsRunCommandFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsStartFuture.azure.Future
|
||||
1. VirtualMachineScaleSetVMsUpdateFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsCreateOrUpdateFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsDeallocateFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsDeleteFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsDeleteInstancesFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsPerformMaintenanceFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsPowerOffFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsRedeployFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsReimageAllFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsReimageFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsRestartFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsStartFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsUpdateFuture.azure.Future
|
||||
1. VirtualMachineScaleSetsUpdateInstancesFuture.azure.Future
|
||||
1. VirtualMachinesCaptureFuture.azure.Future
|
||||
1. VirtualMachinesConvertToManagedDisksFuture.azure.Future
|
||||
1. VirtualMachinesCreateOrUpdateFuture.azure.Future
|
||||
1. VirtualMachinesDeallocateFuture.azure.Future
|
||||
1. VirtualMachinesDeleteFuture.azure.Future
|
||||
1. VirtualMachinesPerformMaintenanceFuture.azure.Future
|
||||
1. VirtualMachinesPowerOffFuture.azure.Future
|
||||
1. VirtualMachinesReapplyFuture.azure.Future
|
||||
1. VirtualMachinesRedeployFuture.azure.Future
|
||||
1. VirtualMachinesReimageFuture.azure.Future
|
||||
1. VirtualMachinesRestartFuture.azure.Future
|
||||
1. VirtualMachinesRunCommandFuture.azure.Future
|
||||
1. VirtualMachinesStartFuture.azure.Future
|
||||
1. VirtualMachinesUpdateFuture.azure.Future
|
||||
|
||||
## Struct Changes
|
||||
|
||||
### New Struct Fields
|
||||
|
||||
1. ContainerServicesCreateOrUpdateFuture.Result
|
||||
1. ContainerServicesCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. ContainerServicesDeleteFuture.Result
|
||||
1. ContainerServicesDeleteFuture.azure.FutureAPI
|
||||
1. DedicatedHostsCreateOrUpdateFuture.Result
|
||||
1. DedicatedHostsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. DedicatedHostsDeleteFuture.Result
|
||||
1. DedicatedHostsDeleteFuture.azure.FutureAPI
|
||||
1. DedicatedHostsUpdateFuture.Result
|
||||
1. DedicatedHostsUpdateFuture.azure.FutureAPI
|
||||
1. DiskEncryptionSetsCreateOrUpdateFuture.Result
|
||||
1. DiskEncryptionSetsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. DiskEncryptionSetsDeleteFuture.Result
|
||||
1. DiskEncryptionSetsDeleteFuture.azure.FutureAPI
|
||||
1. DiskEncryptionSetsUpdateFuture.Result
|
||||
1. DiskEncryptionSetsUpdateFuture.azure.FutureAPI
|
||||
1. DisksCreateOrUpdateFuture.Result
|
||||
1. DisksCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. DisksDeleteFuture.Result
|
||||
1. DisksDeleteFuture.azure.FutureAPI
|
||||
1. DisksGrantAccessFuture.Result
|
||||
1. DisksGrantAccessFuture.azure.FutureAPI
|
||||
1. DisksRevokeAccessFuture.Result
|
||||
1. DisksRevokeAccessFuture.azure.FutureAPI
|
||||
1. DisksUpdateFuture.Result
|
||||
1. DisksUpdateFuture.azure.FutureAPI
|
||||
1. GalleriesCreateOrUpdateFuture.Result
|
||||
1. GalleriesCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. GalleriesDeleteFuture.Result
|
||||
1. GalleriesDeleteFuture.azure.FutureAPI
|
||||
1. GalleriesUpdateFuture.Result
|
||||
1. GalleriesUpdateFuture.azure.FutureAPI
|
||||
1. GalleryApplicationVersionsCreateOrUpdateFuture.Result
|
||||
1. GalleryApplicationVersionsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. GalleryApplicationVersionsDeleteFuture.Result
|
||||
1. GalleryApplicationVersionsDeleteFuture.azure.FutureAPI
|
||||
1. GalleryApplicationVersionsUpdateFuture.Result
|
||||
1. GalleryApplicationVersionsUpdateFuture.azure.FutureAPI
|
||||
1. GalleryApplicationsCreateOrUpdateFuture.Result
|
||||
1. GalleryApplicationsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. GalleryApplicationsDeleteFuture.Result
|
||||
1. GalleryApplicationsDeleteFuture.azure.FutureAPI
|
||||
1. GalleryApplicationsUpdateFuture.Result
|
||||
1. GalleryApplicationsUpdateFuture.azure.FutureAPI
|
||||
1. GalleryImageVersionsCreateOrUpdateFuture.Result
|
||||
1. GalleryImageVersionsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. GalleryImageVersionsDeleteFuture.Result
|
||||
1. GalleryImageVersionsDeleteFuture.azure.FutureAPI
|
||||
1. GalleryImageVersionsUpdateFuture.Result
|
||||
1. GalleryImageVersionsUpdateFuture.azure.FutureAPI
|
||||
1. GalleryImagesCreateOrUpdateFuture.Result
|
||||
1. GalleryImagesCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. GalleryImagesDeleteFuture.Result
|
||||
1. GalleryImagesDeleteFuture.azure.FutureAPI
|
||||
1. GalleryImagesUpdateFuture.Result
|
||||
1. GalleryImagesUpdateFuture.azure.FutureAPI
|
||||
1. ImagesCreateOrUpdateFuture.Result
|
||||
1. ImagesCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. ImagesDeleteFuture.Result
|
||||
1. ImagesDeleteFuture.azure.FutureAPI
|
||||
1. ImagesUpdateFuture.Result
|
||||
1. ImagesUpdateFuture.azure.FutureAPI
|
||||
1. LogAnalyticsExportRequestRateByIntervalFuture.Result
|
||||
1. LogAnalyticsExportRequestRateByIntervalFuture.azure.FutureAPI
|
||||
1. LogAnalyticsExportThrottledRequestsFuture.Result
|
||||
1. LogAnalyticsExportThrottledRequestsFuture.azure.FutureAPI
|
||||
1. SnapshotsCreateOrUpdateFuture.Result
|
||||
1. SnapshotsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. SnapshotsDeleteFuture.Result
|
||||
1. SnapshotsDeleteFuture.azure.FutureAPI
|
||||
1. SnapshotsGrantAccessFuture.Result
|
||||
1. SnapshotsGrantAccessFuture.azure.FutureAPI
|
||||
1. SnapshotsRevokeAccessFuture.Result
|
||||
1. SnapshotsRevokeAccessFuture.azure.FutureAPI
|
||||
1. SnapshotsUpdateFuture.Result
|
||||
1. SnapshotsUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachineExtensionsCreateOrUpdateFuture.Result
|
||||
1. VirtualMachineExtensionsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachineExtensionsDeleteFuture.Result
|
||||
1. VirtualMachineExtensionsDeleteFuture.azure.FutureAPI
|
||||
1. VirtualMachineExtensionsUpdateFuture.Result
|
||||
1. VirtualMachineExtensionsUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetExtensionsCreateOrUpdateFuture.Result
|
||||
1. VirtualMachineScaleSetExtensionsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetExtensionsDeleteFuture.Result
|
||||
1. VirtualMachineScaleSetExtensionsDeleteFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetExtensionsUpdateFuture.Result
|
||||
1. VirtualMachineScaleSetExtensionsUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetRollingUpgradesCancelFuture.Result
|
||||
1. VirtualMachineScaleSetRollingUpgradesCancelFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetRollingUpgradesStartExtensionUpgradeFuture.Result
|
||||
1. VirtualMachineScaleSetRollingUpgradesStartExtensionUpgradeFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetRollingUpgradesStartOSUpgradeFuture.Result
|
||||
1. VirtualMachineScaleSetRollingUpgradesStartOSUpgradeFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture.Result
|
||||
1. VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMExtensionsDeleteFuture.Result
|
||||
1. VirtualMachineScaleSetVMExtensionsDeleteFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMExtensionsUpdateFuture.Result
|
||||
1. VirtualMachineScaleSetVMExtensionsUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsDeallocateFuture.Result
|
||||
1. VirtualMachineScaleSetVMsDeallocateFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsDeleteFuture.Result
|
||||
1. VirtualMachineScaleSetVMsDeleteFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsPerformMaintenanceFuture.Result
|
||||
1. VirtualMachineScaleSetVMsPerformMaintenanceFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsPowerOffFuture.Result
|
||||
1. VirtualMachineScaleSetVMsPowerOffFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsRedeployFuture.Result
|
||||
1. VirtualMachineScaleSetVMsRedeployFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsReimageAllFuture.Result
|
||||
1. VirtualMachineScaleSetVMsReimageAllFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsReimageFuture.Result
|
||||
1. VirtualMachineScaleSetVMsReimageFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsRestartFuture.Result
|
||||
1. VirtualMachineScaleSetVMsRestartFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsRunCommandFuture.Result
|
||||
1. VirtualMachineScaleSetVMsRunCommandFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsStartFuture.Result
|
||||
1. VirtualMachineScaleSetVMsStartFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetVMsUpdateFuture.Result
|
||||
1. VirtualMachineScaleSetVMsUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsCreateOrUpdateFuture.Result
|
||||
1. VirtualMachineScaleSetsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsDeallocateFuture.Result
|
||||
1. VirtualMachineScaleSetsDeallocateFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsDeleteFuture.Result
|
||||
1. VirtualMachineScaleSetsDeleteFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsDeleteInstancesFuture.Result
|
||||
1. VirtualMachineScaleSetsDeleteInstancesFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsPerformMaintenanceFuture.Result
|
||||
1. VirtualMachineScaleSetsPerformMaintenanceFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsPowerOffFuture.Result
|
||||
1. VirtualMachineScaleSetsPowerOffFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsRedeployFuture.Result
|
||||
1. VirtualMachineScaleSetsRedeployFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsReimageAllFuture.Result
|
||||
1. VirtualMachineScaleSetsReimageAllFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsReimageFuture.Result
|
||||
1. VirtualMachineScaleSetsReimageFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsRestartFuture.Result
|
||||
1. VirtualMachineScaleSetsRestartFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsStartFuture.Result
|
||||
1. VirtualMachineScaleSetsStartFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsUpdateFuture.Result
|
||||
1. VirtualMachineScaleSetsUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachineScaleSetsUpdateInstancesFuture.Result
|
||||
1. VirtualMachineScaleSetsUpdateInstancesFuture.azure.FutureAPI
|
||||
1. VirtualMachinesCaptureFuture.Result
|
||||
1. VirtualMachinesCaptureFuture.azure.FutureAPI
|
||||
1. VirtualMachinesConvertToManagedDisksFuture.Result
|
||||
1. VirtualMachinesConvertToManagedDisksFuture.azure.FutureAPI
|
||||
1. VirtualMachinesCreateOrUpdateFuture.Result
|
||||
1. VirtualMachinesCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. VirtualMachinesDeallocateFuture.Result
|
||||
1. VirtualMachinesDeallocateFuture.azure.FutureAPI
|
||||
1. VirtualMachinesDeleteFuture.Result
|
||||
1. VirtualMachinesDeleteFuture.azure.FutureAPI
|
||||
1. VirtualMachinesPerformMaintenanceFuture.Result
|
||||
1. VirtualMachinesPerformMaintenanceFuture.azure.FutureAPI
|
||||
1. VirtualMachinesPowerOffFuture.Result
|
||||
1. VirtualMachinesPowerOffFuture.azure.FutureAPI
|
||||
1. VirtualMachinesReapplyFuture.Result
|
||||
1. VirtualMachinesReapplyFuture.azure.FutureAPI
|
||||
1. VirtualMachinesRedeployFuture.Result
|
||||
1. VirtualMachinesRedeployFuture.azure.FutureAPI
|
||||
1. VirtualMachinesReimageFuture.Result
|
||||
1. VirtualMachinesReimageFuture.azure.FutureAPI
|
||||
1. VirtualMachinesRestartFuture.Result
|
||||
1. VirtualMachinesRestartFuture.azure.FutureAPI
|
||||
1. VirtualMachinesRunCommandFuture.Result
|
||||
1. VirtualMachinesRunCommandFuture.azure.FutureAPI
|
||||
1. VirtualMachinesStartFuture.Result
|
||||
1. VirtualMachinesStartFuture.azure.FutureAPI
|
||||
1. VirtualMachinesUpdateFuture.Result
|
||||
1. VirtualMachinesUpdateFuture.azure.FutureAPI
|
||||
|
|
@ -74,6 +74,7 @@ func (client AvailabilitySetsClient) CreateOrUpdate(ctx context.Context, resourc
|
|||
result, err = client.CreateOrUpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "CreateOrUpdate", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -151,6 +152,7 @@ func (client AvailabilitySetsClient) Delete(ctx context.Context, resourceGroupNa
|
|||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "Delete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -225,6 +227,7 @@ func (client AvailabilitySetsClient) Get(ctx context.Context, resourceGroupName
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -300,6 +303,11 @@ func (client AvailabilitySetsClient) List(ctx context.Context, resourceGroupName
|
|||
result.aslr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.aslr.hasNextLink() && result.aslr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -412,6 +420,7 @@ func (client AvailabilitySetsClient) ListAvailableSizes(ctx context.Context, res
|
|||
result, err = client.ListAvailableSizesResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "ListAvailableSizes", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -487,6 +496,11 @@ func (client AvailabilitySetsClient) ListBySubscription(ctx context.Context, exp
|
|||
result.aslr, err = client.ListBySubscriptionResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "ListBySubscription", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.aslr.hasNextLink() && result.aslr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -601,6 +615,7 @@ func (client AvailabilitySetsClient) Update(ctx context.Context, resourceGroupNa
|
|||
result, err = client.UpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.AvailabilitySetsClient", "Update", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -99,7 +99,7 @@ func (client ContainerServicesClient) CreateOrUpdate(ctx context.Context, resour
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ContainerServicesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.ContainerServicesClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -137,7 +137,29 @@ func (client ContainerServicesClient) CreateOrUpdateSender(req *http.Request) (f
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ContainerServicesClient) (cs ContainerService, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ContainerServicesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.ContainerServicesCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if cs.Response.Response, err = future.GetResult(sender); err == nil && cs.Response.Response.StatusCode != http.StatusNoContent {
|
||||
cs, err = client.CreateOrUpdateResponder(cs.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ContainerServicesCreateOrUpdateFuture", "Result", cs.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -179,7 +201,7 @@ func (client ContainerServicesClient) Delete(ctx context.Context, resourceGroupN
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ContainerServicesClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.ContainerServicesClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -215,7 +237,23 @@ func (client ContainerServicesClient) DeleteSender(req *http.Request) (future Co
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ContainerServicesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ContainerServicesDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.ContainerServicesDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -263,6 +301,7 @@ func (client ContainerServicesClient) Get(ctx context.Context, resourceGroupName
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ContainerServicesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -337,6 +376,11 @@ func (client ContainerServicesClient) List(ctx context.Context) (result Containe
|
|||
result.cslr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ContainerServicesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.cslr.hasNextLink() && result.cslr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -449,6 +493,11 @@ func (client ContainerServicesClient) ListByResourceGroup(ctx context.Context, r
|
|||
result.cslr, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ContainerServicesClient", "ListByResourceGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.cslr.hasNextLink() && result.cslr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -87,6 +87,7 @@ func (client DedicatedHostGroupsClient) CreateOrUpdate(ctx context.Context, reso
|
|||
result, err = client.CreateOrUpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostGroupsClient", "CreateOrUpdate", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -164,6 +165,7 @@ func (client DedicatedHostGroupsClient) Delete(ctx context.Context, resourceGrou
|
|||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostGroupsClient", "Delete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -238,6 +240,7 @@ func (client DedicatedHostGroupsClient) Get(ctx context.Context, resourceGroupNa
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostGroupsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -314,6 +317,11 @@ func (client DedicatedHostGroupsClient) ListByResourceGroup(ctx context.Context,
|
|||
result.dhglr, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostGroupsClient", "ListByResourceGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dhglr.hasNextLink() && result.dhglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -424,6 +432,11 @@ func (client DedicatedHostGroupsClient) ListBySubscription(ctx context.Context)
|
|||
result.dhglr, err = client.ListBySubscriptionResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostGroupsClient", "ListBySubscription", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dhglr.hasNextLink() && result.dhglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -535,6 +548,7 @@ func (client DedicatedHostGroupsClient) Update(ctx context.Context, resourceGrou
|
|||
result, err = client.UpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostGroupsClient", "Update", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ func (client DedicatedHostsClient) CreateOrUpdate(ctx context.Context, resourceG
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -118,7 +118,29 @@ func (client DedicatedHostsClient) CreateOrUpdateSender(req *http.Request) (futu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DedicatedHostsClient) (dh DedicatedHost, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DedicatedHostsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if dh.Response.Response, err = future.GetResult(sender); err == nil && dh.Response.Response.StatusCode != http.StatusNoContent {
|
||||
dh, err = client.CreateOrUpdateResponder(dh.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsCreateOrUpdateFuture", "Result", dh.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -158,7 +180,7 @@ func (client DedicatedHostsClient) Delete(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -195,7 +217,23 @@ func (client DedicatedHostsClient) DeleteSender(req *http.Request) (future Dedic
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DedicatedHostsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DedicatedHostsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -243,6 +281,7 @@ func (client DedicatedHostsClient) Get(ctx context.Context, resourceGroupName st
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -324,6 +363,11 @@ func (client DedicatedHostsClient) ListByHostGroup(ctx context.Context, resource
|
|||
result.dhlr, err = client.ListByHostGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsClient", "ListByHostGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dhlr.hasNextLink() && result.dhlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -430,7 +474,7 @@ func (client DedicatedHostsClient) Update(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -469,7 +513,29 @@ func (client DedicatedHostsClient) UpdateSender(req *http.Request) (future Dedic
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DedicatedHostsClient) (dh DedicatedHost, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DedicatedHostsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if dh.Response.Response, err = future.GetResult(sender); err == nil && dh.Response.Response.StatusCode != http.StatusNoContent {
|
||||
dh, err = client.UpdateResponder(dh.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DedicatedHostsUpdateFuture", "Result", dh.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ func (client DiskEncryptionSetsClient) CreateOrUpdate(ctx context.Context, resou
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -119,7 +119,29 @@ func (client DiskEncryptionSetsClient) CreateOrUpdateSender(req *http.Request) (
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DiskEncryptionSetsClient) (desVar DiskEncryptionSet, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DiskEncryptionSetsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if desVar.Response.Response, err = future.GetResult(sender); err == nil && desVar.Response.Response.StatusCode != http.StatusNoContent {
|
||||
desVar, err = client.CreateOrUpdateResponder(desVar.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsCreateOrUpdateFuture", "Result", desVar.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -160,7 +182,7 @@ func (client DiskEncryptionSetsClient) Delete(ctx context.Context, resourceGroup
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -196,7 +218,23 @@ func (client DiskEncryptionSetsClient) DeleteSender(req *http.Request) (future D
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DiskEncryptionSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DiskEncryptionSetsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -244,6 +282,7 @@ func (client DiskEncryptionSetsClient) Get(ctx context.Context, resourceGroupNam
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -317,6 +356,11 @@ func (client DiskEncryptionSetsClient) List(ctx context.Context) (result DiskEnc
|
|||
result.desl, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.desl.hasNextLink() && result.desl.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -427,6 +471,11 @@ func (client DiskEncryptionSetsClient) ListByResourceGroup(ctx context.Context,
|
|||
result.desl, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "ListByResourceGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.desl.hasNextLink() && result.desl.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -534,7 +583,7 @@ func (client DiskEncryptionSetsClient) Update(ctx context.Context, resourceGroup
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -572,7 +621,29 @@ func (client DiskEncryptionSetsClient) UpdateSender(req *http.Request) (future D
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DiskEncryptionSetsClient) (desVar DiskEncryptionSet, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DiskEncryptionSetsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if desVar.Response.Response, err = future.GetResult(sender); err == nil && desVar.Response.Response.StatusCode != http.StatusNoContent {
|
||||
desVar, err = client.UpdateResponder(desVar.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DiskEncryptionSetsUpdateFuture", "Result", desVar.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
129
vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/disks.go
generated
vendored
129
vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/disks.go
generated
vendored
|
|
@ -81,7 +81,7 @@ func (client DisksClient) CreateOrUpdate(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -120,7 +120,29 @@ func (client DisksClient) CreateOrUpdateSender(req *http.Request) (future DisksC
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DisksClient) (d Disk, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DisksCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if d.Response.Response, err = future.GetResult(sender); err == nil && d.Response.Response.StatusCode != http.StatusNoContent {
|
||||
d, err = client.CreateOrUpdateResponder(d.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksCreateOrUpdateFuture", "Result", d.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -161,7 +183,7 @@ func (client DisksClient) Delete(ctx context.Context, resourceGroupName string,
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -197,7 +219,23 @@ func (client DisksClient) DeleteSender(req *http.Request) (future DisksDeleteFut
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DisksClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DisksDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -245,6 +283,7 @@ func (client DisksClient) Get(ctx context.Context, resourceGroupName string, dis
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -321,7 +360,7 @@ func (client DisksClient) GrantAccess(ctx context.Context, resourceGroupName str
|
|||
|
||||
result, err = client.GrantAccessSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "GrantAccess", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "GrantAccess", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -359,7 +398,29 @@ func (client DisksClient) GrantAccessSender(req *http.Request) (future DisksGran
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DisksClient) (au AccessURI, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksGrantAccessFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DisksGrantAccessFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if au.Response.Response, err = future.GetResult(sender); err == nil && au.Response.Response.StatusCode != http.StatusNoContent {
|
||||
au, err = client.GrantAccessResponder(au.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksGrantAccessFuture", "Result", au.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -404,6 +465,11 @@ func (client DisksClient) List(ctx context.Context) (result DiskListPage, err er
|
|||
result.dl, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dl.hasNextLink() && result.dl.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -514,6 +580,11 @@ func (client DisksClient) ListByResourceGroup(ctx context.Context, resourceGroup
|
|||
result.dl, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "ListByResourceGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dl.hasNextLink() && result.dl.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -619,7 +690,7 @@ func (client DisksClient) RevokeAccess(ctx context.Context, resourceGroupName st
|
|||
|
||||
result, err = client.RevokeAccessSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "RevokeAccess", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "RevokeAccess", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -655,7 +726,23 @@ func (client DisksClient) RevokeAccessSender(req *http.Request) (future DisksRev
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DisksClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksRevokeAccessFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DisksRevokeAccessFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -696,7 +783,7 @@ func (client DisksClient) Update(ctx context.Context, resourceGroupName string,
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -734,7 +821,29 @@ func (client DisksClient) UpdateSender(req *http.Request) (future DisksUpdateFut
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client DisksClient) (d Disk, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.DisksUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if d.Response.Response, err = future.GetResult(sender); err == nil && d.Response.Response.StatusCode != http.StatusNoContent {
|
||||
d, err = client.UpdateResponder(d.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.DisksUpdateFuture", "Result", d.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
1341
vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/enums.go
generated
vendored
Normal file
1341
vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/enums.go
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
|
|
@ -66,7 +66,7 @@ func (client GalleriesClient) CreateOrUpdate(ctx context.Context, resourceGroupN
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -104,7 +104,29 @@ func (client GalleriesClient) CreateOrUpdateSender(req *http.Request) (future Ga
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleriesClient) (g Gallery, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleriesCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if g.Response.Response, err = future.GetResult(sender); err == nil && g.Response.Response.StatusCode != http.StatusNoContent {
|
||||
g, err = client.CreateOrUpdateResponder(g.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesCreateOrUpdateFuture", "Result", g.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -143,7 +165,7 @@ func (client GalleriesClient) Delete(ctx context.Context, resourceGroupName stri
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -179,7 +201,23 @@ func (client GalleriesClient) DeleteSender(req *http.Request) (future GalleriesD
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleriesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleriesDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client GalleriesClient) Get(ctx context.Context, resourceGroupName string,
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -298,6 +337,11 @@ func (client GalleriesClient) List(ctx context.Context) (result GalleryListPage,
|
|||
result.gl, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.gl.hasNextLink() && result.gl.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -408,6 +452,11 @@ func (client GalleriesClient) ListByResourceGroup(ctx context.Context, resourceG
|
|||
result.gl, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesClient", "ListByResourceGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.gl.hasNextLink() && result.gl.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -513,7 +562,7 @@ func (client GalleriesClient) Update(ctx context.Context, resourceGroupName stri
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -551,7 +600,29 @@ func (client GalleriesClient) UpdateSender(req *http.Request) (future GalleriesU
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleriesClient) (g Gallery, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleriesUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if g.Response.Response, err = future.GetResult(sender); err == nil && g.Response.Response.StatusCode != http.StatusNoContent {
|
||||
g, err = client.UpdateResponder(g.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleriesUpdateFuture", "Result", g.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ func (client GalleryApplicationsClient) CreateOrUpdate(ctx context.Context, reso
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -109,7 +109,29 @@ func (client GalleryApplicationsClient) CreateOrUpdateSender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryApplicationsClient) (ga GalleryApplication, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryApplicationsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if ga.Response.Response, err = future.GetResult(sender); err == nil && ga.Response.Response.StatusCode != http.StatusNoContent {
|
||||
ga, err = client.CreateOrUpdateResponder(ga.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsCreateOrUpdateFuture", "Result", ga.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -150,7 +172,7 @@ func (client GalleryApplicationsClient) Delete(ctx context.Context, resourceGrou
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -187,7 +209,23 @@ func (client GalleryApplicationsClient) DeleteSender(req *http.Request) (future
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryApplicationsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryApplicationsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -235,6 +273,7 @@ func (client GalleryApplicationsClient) Get(ctx context.Context, resourceGroupNa
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -313,6 +352,11 @@ func (client GalleryApplicationsClient) ListByGallery(ctx context.Context, resou
|
|||
result.gal, err = client.ListByGalleryResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "ListByGallery", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.gal.hasNextLink() && result.gal.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -422,7 +466,7 @@ func (client GalleryApplicationsClient) Update(ctx context.Context, resourceGrou
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -461,7 +505,29 @@ func (client GalleryApplicationsClient) UpdateSender(req *http.Request) (future
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryApplicationsClient) (ga GalleryApplication, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryApplicationsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if ga.Response.Response, err = future.GetResult(sender); err == nil && ga.Response.Response.StatusCode != http.StatusNoContent {
|
||||
ga, err = client.UpdateResponder(ga.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationsUpdateFuture", "Result", ga.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -86,7 +86,7 @@ func (client GalleryApplicationVersionsClient) CreateOrUpdate(ctx context.Contex
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -126,7 +126,29 @@ func (client GalleryApplicationVersionsClient) CreateOrUpdateSender(req *http.Re
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryApplicationVersionsClient) (gav GalleryApplicationVersion, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryApplicationVersionsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if gav.Response.Response, err = future.GetResult(sender); err == nil && gav.Response.Response.StatusCode != http.StatusNoContent {
|
||||
gav, err = client.CreateOrUpdateResponder(gav.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsCreateOrUpdateFuture", "Result", gav.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -168,7 +190,7 @@ func (client GalleryApplicationVersionsClient) Delete(ctx context.Context, resou
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -206,7 +228,23 @@ func (client GalleryApplicationVersionsClient) DeleteSender(req *http.Request) (
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryApplicationVersionsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryApplicationVersionsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -256,6 +294,7 @@ func (client GalleryApplicationVersionsClient) Get(ctx context.Context, resource
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -339,6 +378,11 @@ func (client GalleryApplicationVersionsClient) ListByGalleryApplication(ctx cont
|
|||
result.gavl, err = client.ListByGalleryApplicationResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "ListByGalleryApplication", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.gavl.hasNextLink() && result.gavl.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -450,7 +494,7 @@ func (client GalleryApplicationVersionsClient) Update(ctx context.Context, resou
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -490,7 +534,29 @@ func (client GalleryApplicationVersionsClient) UpdateSender(req *http.Request) (
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryApplicationVersionsClient) (gav GalleryApplicationVersion, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryApplicationVersionsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if gav.Response.Response, err = future.GetResult(sender); err == nil && gav.Response.Response.StatusCode != http.StatusNoContent {
|
||||
gav, err = client.UpdateResponder(gav.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryApplicationVersionsUpdateFuture", "Result", gav.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ func (client GalleryImagesClient) CreateOrUpdate(ctx context.Context, resourceGr
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -120,7 +120,29 @@ func (client GalleryImagesClient) CreateOrUpdateSender(req *http.Request) (futur
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryImagesClient) (gi GalleryImage, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryImagesCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if gi.Response.Response, err = future.GetResult(sender); err == nil && gi.Response.Response.StatusCode != http.StatusNoContent {
|
||||
gi, err = client.CreateOrUpdateResponder(gi.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesCreateOrUpdateFuture", "Result", gi.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -160,7 +182,7 @@ func (client GalleryImagesClient) Delete(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -197,7 +219,23 @@ func (client GalleryImagesClient) DeleteSender(req *http.Request) (future Galler
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryImagesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryImagesDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -244,6 +282,7 @@ func (client GalleryImagesClient) Get(ctx context.Context, resourceGroupName str
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -321,6 +360,11 @@ func (client GalleryImagesClient) ListByGallery(ctx context.Context, resourceGro
|
|||
result.gil, err = client.ListByGalleryResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesClient", "ListByGallery", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.gil.hasNextLink() && result.gil.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -429,7 +473,7 @@ func (client GalleryImagesClient) Update(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -468,7 +512,29 @@ func (client GalleryImagesClient) UpdateSender(req *http.Request) (future Galler
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryImagesClient) (gi GalleryImage, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryImagesUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if gi.Response.Response, err = future.GetResult(sender); err == nil && gi.Response.Response.StatusCode != http.StatusNoContent {
|
||||
gi, err = client.UpdateResponder(gi.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImagesUpdateFuture", "Result", gi.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ func (client GalleryImageVersionsClient) CreateOrUpdate(ctx context.Context, res
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -118,7 +118,29 @@ func (client GalleryImageVersionsClient) CreateOrUpdateSender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryImageVersionsClient) (giv GalleryImageVersion, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryImageVersionsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if giv.Response.Response, err = future.GetResult(sender); err == nil && giv.Response.Response.StatusCode != http.StatusNoContent {
|
||||
giv, err = client.CreateOrUpdateResponder(giv.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsCreateOrUpdateFuture", "Result", giv.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -159,7 +181,7 @@ func (client GalleryImageVersionsClient) Delete(ctx context.Context, resourceGro
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -197,7 +219,23 @@ func (client GalleryImageVersionsClient) DeleteSender(req *http.Request) (future
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryImageVersionsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryImageVersionsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -246,6 +284,7 @@ func (client GalleryImageVersionsClient) Get(ctx context.Context, resourceGroupN
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -329,6 +368,11 @@ func (client GalleryImageVersionsClient) ListByGalleryImage(ctx context.Context,
|
|||
result.givl, err = client.ListByGalleryImageResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsClient", "ListByGalleryImage", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.givl.hasNextLink() && result.givl.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -439,7 +483,7 @@ func (client GalleryImageVersionsClient) Update(ctx context.Context, resourceGro
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -479,7 +523,29 @@ func (client GalleryImageVersionsClient) UpdateSender(req *http.Request) (future
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client GalleryImageVersionsClient) (giv GalleryImageVersion, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.GalleryImageVersionsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if giv.Response.Response, err = future.GetResult(sender); err == nil && giv.Response.Response.StatusCode != http.StatusNoContent {
|
||||
giv, err = client.UpdateResponder(giv.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.GalleryImageVersionsUpdateFuture", "Result", giv.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ func (client ImagesClient) CreateOrUpdate(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -103,7 +103,29 @@ func (client ImagesClient) CreateOrUpdateSender(req *http.Request) (future Image
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ImagesClient) (i Image, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.ImagesCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if i.Response.Response, err = future.GetResult(sender); err == nil && i.Response.Response.StatusCode != http.StatusNoContent {
|
||||
i, err = client.CreateOrUpdateResponder(i.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesCreateOrUpdateFuture", "Result", i.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -142,7 +164,7 @@ func (client ImagesClient) Delete(ctx context.Context, resourceGroupName string,
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -178,7 +200,23 @@ func (client ImagesClient) DeleteSender(req *http.Request) (future ImagesDeleteF
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ImagesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.ImagesDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client ImagesClient) Get(ctx context.Context, resourceGroupName string, im
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -302,6 +341,11 @@ func (client ImagesClient) List(ctx context.Context) (result ImageListResultPage
|
|||
result.ilr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ilr.hasNextLink() && result.ilr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -412,6 +456,11 @@ func (client ImagesClient) ListByResourceGroup(ctx context.Context, resourceGrou
|
|||
result.ilr, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesClient", "ListByResourceGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ilr.hasNextLink() && result.ilr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -516,7 +565,7 @@ func (client ImagesClient) Update(ctx context.Context, resourceGroupName string,
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -554,7 +603,29 @@ func (client ImagesClient) UpdateSender(req *http.Request) (future ImagesUpdateF
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ImagesClient) (i Image, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.ImagesUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if i.Response.Response, err = future.GetResult(sender); err == nil && i.Response.Response.StatusCode != http.StatusNoContent {
|
||||
i, err = client.UpdateResponder(i.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ImagesUpdateFuture", "Result", i.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -72,7 +72,7 @@ func (client LogAnalyticsClient) ExportRequestRateByInterval(ctx context.Context
|
|||
|
||||
result, err = client.ExportRequestRateByIntervalSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.LogAnalyticsClient", "ExportRequestRateByInterval", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.LogAnalyticsClient", "ExportRequestRateByInterval", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -109,7 +109,29 @@ func (client LogAnalyticsClient) ExportRequestRateByIntervalSender(req *http.Req
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client LogAnalyticsClient) (laor LogAnalyticsOperationResult, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.LogAnalyticsExportRequestRateByIntervalFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.LogAnalyticsExportRequestRateByIntervalFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if laor.Response.Response, err = future.GetResult(sender); err == nil && laor.Response.Response.StatusCode != http.StatusNoContent {
|
||||
laor, err = client.ExportRequestRateByIntervalResponder(laor.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.LogAnalyticsExportRequestRateByIntervalFuture", "Result", laor.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -155,7 +177,7 @@ func (client LogAnalyticsClient) ExportThrottledRequests(ctx context.Context, pa
|
|||
|
||||
result, err = client.ExportThrottledRequestsSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.LogAnalyticsClient", "ExportThrottledRequests", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.LogAnalyticsClient", "ExportThrottledRequests", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -192,7 +214,29 @@ func (client LogAnalyticsClient) ExportThrottledRequestsSender(req *http.Request
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client LogAnalyticsClient) (laor LogAnalyticsOperationResult, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.LogAnalyticsExportThrottledRequestsFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.LogAnalyticsExportThrottledRequestsFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if laor.Response.Response, err = future.GetResult(sender); err == nil && laor.Response.Response.StatusCode != http.StatusNoContent {
|
||||
laor, err = client.ExportThrottledRequestsResponder(laor.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.LogAnalyticsExportThrottledRequestsFuture", "Result", laor.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
4888
vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/models.go
generated
vendored
4888
vendor/github.com/Azure/azure-sdk-for-go/services/compute/mgmt/2019-07-01/compute/models.go
generated
vendored
File diff suppressed because one or more lines are too long
|
|
@ -69,6 +69,7 @@ func (client OperationsClient) List(ctx context.Context) (result OperationListRe
|
|||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.OperationsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -74,6 +74,7 @@ func (client ProximityPlacementGroupsClient) CreateOrUpdate(ctx context.Context,
|
|||
result, err = client.CreateOrUpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ProximityPlacementGroupsClient", "CreateOrUpdate", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -151,6 +152,7 @@ func (client ProximityPlacementGroupsClient) Delete(ctx context.Context, resourc
|
|||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ProximityPlacementGroupsClient", "Delete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -227,6 +229,7 @@ func (client ProximityPlacementGroupsClient) Get(ctx context.Context, resourceGr
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ProximityPlacementGroupsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -305,6 +308,11 @@ func (client ProximityPlacementGroupsClient) ListByResourceGroup(ctx context.Con
|
|||
result.ppglr, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ProximityPlacementGroupsClient", "ListByResourceGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ppglr.hasNextLink() && result.ppglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -414,6 +422,11 @@ func (client ProximityPlacementGroupsClient) ListBySubscription(ctx context.Cont
|
|||
result.ppglr, err = client.ListBySubscriptionResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ProximityPlacementGroupsClient", "ListBySubscription", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ppglr.hasNextLink() && result.ppglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -525,6 +538,7 @@ func (client ProximityPlacementGroupsClient) Update(ctx context.Context, resourc
|
|||
result, err = client.UpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ProximityPlacementGroupsClient", "Update", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -72,6 +72,11 @@ func (client ResourceSkusClient) List(ctx context.Context, filter string) (resul
|
|||
result.rsr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.ResourceSkusClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.rsr.hasNextLink() && result.rsr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -80,7 +80,7 @@ func (client SnapshotsClient) CreateOrUpdate(ctx context.Context, resourceGroupN
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -119,7 +119,29 @@ func (client SnapshotsClient) CreateOrUpdateSender(req *http.Request) (future Sn
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SnapshotsClient) (s Snapshot, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.SnapshotsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if s.Response.Response, err = future.GetResult(sender); err == nil && s.Response.Response.StatusCode != http.StatusNoContent {
|
||||
s, err = client.CreateOrUpdateResponder(s.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsCreateOrUpdateFuture", "Result", s.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -159,7 +181,7 @@ func (client SnapshotsClient) Delete(ctx context.Context, resourceGroupName stri
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -195,7 +217,23 @@ func (client SnapshotsClient) DeleteSender(req *http.Request) (future SnapshotsD
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SnapshotsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.SnapshotsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -242,6 +280,7 @@ func (client SnapshotsClient) Get(ctx context.Context, resourceGroupName string,
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -317,7 +356,7 @@ func (client SnapshotsClient) GrantAccess(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.GrantAccessSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "GrantAccess", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "GrantAccess", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -355,7 +394,29 @@ func (client SnapshotsClient) GrantAccessSender(req *http.Request) (future Snaps
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SnapshotsClient) (au AccessURI, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsGrantAccessFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.SnapshotsGrantAccessFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if au.Response.Response, err = future.GetResult(sender); err == nil && au.Response.Response.StatusCode != http.StatusNoContent {
|
||||
au, err = client.GrantAccessResponder(au.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsGrantAccessFuture", "Result", au.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -400,6 +461,11 @@ func (client SnapshotsClient) List(ctx context.Context) (result SnapshotListPage
|
|||
result.sl, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.sl.hasNextLink() && result.sl.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -510,6 +576,11 @@ func (client SnapshotsClient) ListByResourceGroup(ctx context.Context, resourceG
|
|||
result.sl, err = client.ListByResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "ListByResourceGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.sl.hasNextLink() && result.sl.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -614,7 +685,7 @@ func (client SnapshotsClient) RevokeAccess(ctx context.Context, resourceGroupNam
|
|||
|
||||
result, err = client.RevokeAccessSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "RevokeAccess", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "RevokeAccess", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -650,7 +721,23 @@ func (client SnapshotsClient) RevokeAccessSender(req *http.Request) (future Snap
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SnapshotsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsRevokeAccessFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.SnapshotsRevokeAccessFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -690,7 +777,7 @@ func (client SnapshotsClient) Update(ctx context.Context, resourceGroupName stri
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -728,7 +815,29 @@ func (client SnapshotsClient) UpdateSender(req *http.Request) (future SnapshotsU
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SnapshotsClient) (s Snapshot, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.SnapshotsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if s.Response.Response, err = future.GetResult(sender); err == nil && s.Response.Response.StatusCode != http.StatusNoContent {
|
||||
s, err = client.UpdateResponder(s.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.SnapshotsUpdateFuture", "Result", s.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -80,6 +80,11 @@ func (client UsageClient) List(ctx context.Context, location string) (result Lis
|
|||
result.lur, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.UsageClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.lur.hasNextLink() && result.lur.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -72,6 +72,7 @@ func (client VirtualMachineExtensionImagesClient) Get(ctx context.Context, locat
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionImagesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -148,6 +149,7 @@ func (client VirtualMachineExtensionImagesClient) ListTypes(ctx context.Context,
|
|||
result, err = client.ListTypesResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionImagesClient", "ListTypes", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -223,6 +225,7 @@ func (client VirtualMachineExtensionImagesClient) ListVersions(ctx context.Conte
|
|||
result, err = client.ListVersionsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionImagesClient", "ListVersions", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ func (client VirtualMachineExtensionsClient) CreateOrUpdate(ctx context.Context,
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -106,7 +106,29 @@ func (client VirtualMachineExtensionsClient) CreateOrUpdateSender(req *http.Requ
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineExtensionsClient) (vme VirtualMachineExtension, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineExtensionsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vme.Response.Response, err = future.GetResult(sender); err == nil && vme.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vme, err = client.CreateOrUpdateResponder(vme.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsCreateOrUpdateFuture", "Result", vme.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -146,7 +168,7 @@ func (client VirtualMachineExtensionsClient) Delete(ctx context.Context, resourc
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -183,7 +205,23 @@ func (client VirtualMachineExtensionsClient) DeleteSender(req *http.Request) (fu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineExtensionsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineExtensionsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -231,6 +269,7 @@ func (client VirtualMachineExtensionsClient) Get(ctx context.Context, resourceGr
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -311,6 +350,7 @@ func (client VirtualMachineExtensionsClient) List(ctx context.Context, resourceG
|
|||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -383,7 +423,7 @@ func (client VirtualMachineExtensionsClient) Update(ctx context.Context, resourc
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -422,7 +462,29 @@ func (client VirtualMachineExtensionsClient) UpdateSender(req *http.Request) (fu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineExtensionsClient) (vme VirtualMachineExtension, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineExtensionsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vme.Response.Response, err = future.GetResult(sender); err == nil && vme.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vme, err = client.UpdateResponder(vme.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineExtensionsUpdateFuture", "Result", vme.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -76,6 +76,7 @@ func (client VirtualMachineImagesClient) Get(ctx context.Context, location strin
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineImagesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -157,6 +158,7 @@ func (client VirtualMachineImagesClient) List(ctx context.Context, location stri
|
|||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineImagesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -243,6 +245,7 @@ func (client VirtualMachineImagesClient) ListOffers(ctx context.Context, locatio
|
|||
result, err = client.ListOffersResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineImagesClient", "ListOffers", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -317,6 +320,7 @@ func (client VirtualMachineImagesClient) ListPublishers(ctx context.Context, loc
|
|||
result, err = client.ListPublishersResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineImagesClient", "ListPublishers", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -392,6 +396,7 @@ func (client VirtualMachineImagesClient) ListSkus(ctx context.Context, location
|
|||
result, err = client.ListSkusResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineImagesClient", "ListSkus", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -80,6 +80,7 @@ func (client VirtualMachineRunCommandsClient) Get(ctx context.Context, location
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineRunCommandsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -161,6 +162,11 @@ func (client VirtualMachineRunCommandsClient) List(ctx context.Context, location
|
|||
result.rclr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineRunCommandsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.rclr.hasNextLink() && result.rclr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ func (client VirtualMachinesClient) Capture(ctx context.Context, resourceGroupNa
|
|||
|
||||
result, err = client.CaptureSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Capture", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Capture", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -113,7 +113,29 @@ func (client VirtualMachinesClient) CaptureSender(req *http.Request) (future Vir
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (vmcr VirtualMachineCaptureResult, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesCaptureFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesCaptureFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vmcr.Response.Response, err = future.GetResult(sender); err == nil && vmcr.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vmcr, err = client.CaptureResponder(vmcr.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesCaptureFuture", "Result", vmcr.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -130,7 +152,11 @@ func (client VirtualMachinesClient) CaptureResponder(resp *http.Response) (resul
|
|||
}
|
||||
|
||||
// ConvertToManagedDisks converts virtual machine disks from blob-based to managed disks. Virtual machine must be
|
||||
// stop-deallocated before invoking this operation.
|
||||
// stop-deallocated before invoking this operation. <br>For Windows, please refer to [Convert a virtual machine from
|
||||
// unmanaged disks to managed
|
||||
// disks.](https://docs.microsoft.com/en-us/azure/virtual-machines/windows/convert-unmanaged-to-managed-disks).<br>For
|
||||
// Linux, please refer to [Convert a virtual machine from unmanaged disks to managed
|
||||
// disks.](https://docs.microsoft.com/en-us/azure/virtual-machines/linux/convert-unmanaged-to-managed-disks).
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// VMName - the name of the virtual machine.
|
||||
|
|
@ -153,7 +179,7 @@ func (client VirtualMachinesClient) ConvertToManagedDisks(ctx context.Context, r
|
|||
|
||||
result, err = client.ConvertToManagedDisksSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "ConvertToManagedDisks", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "ConvertToManagedDisks", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -189,7 +215,23 @@ func (client VirtualMachinesClient) ConvertToManagedDisksSender(req *http.Reques
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesConvertToManagedDisksFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesConvertToManagedDisksFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -250,7 +292,7 @@ func (client VirtualMachinesClient) CreateOrUpdate(ctx context.Context, resource
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -289,7 +331,29 @@ func (client VirtualMachinesClient) CreateOrUpdateSender(req *http.Request) (fut
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (VM VirtualMachine, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if VM.Response.Response, err = future.GetResult(sender); err == nil && VM.Response.Response.StatusCode != http.StatusNoContent {
|
||||
VM, err = client.CreateOrUpdateResponder(VM.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesCreateOrUpdateFuture", "Result", VM.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -329,7 +393,7 @@ func (client VirtualMachinesClient) Deallocate(ctx context.Context, resourceGrou
|
|||
|
||||
result, err = client.DeallocateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Deallocate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Deallocate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -365,7 +429,23 @@ func (client VirtualMachinesClient) DeallocateSender(req *http.Request) (future
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesDeallocateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesDeallocateFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -403,7 +483,7 @@ func (client VirtualMachinesClient) Delete(ctx context.Context, resourceGroupNam
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -439,7 +519,23 @@ func (client VirtualMachinesClient) DeleteSender(req *http.Request) (future Virt
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -489,6 +585,7 @@ func (client VirtualMachinesClient) Generalize(ctx context.Context, resourceGrou
|
|||
result, err = client.GeneralizeResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Generalize", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -564,6 +661,7 @@ func (client VirtualMachinesClient) Get(ctx context.Context, resourceGroupName s
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -642,6 +740,7 @@ func (client VirtualMachinesClient) InstanceView(ctx context.Context, resourceGr
|
|||
result, err = client.InstanceViewResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "InstanceView", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -718,6 +817,11 @@ func (client VirtualMachinesClient) List(ctx context.Context, resourceGroupName
|
|||
result.vmlr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vmlr.hasNextLink() && result.vmlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -830,6 +934,11 @@ func (client VirtualMachinesClient) ListAll(ctx context.Context, statusOnly stri
|
|||
result.vmlr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "ListAll", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vmlr.hasNextLink() && result.vmlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -943,6 +1052,7 @@ func (client VirtualMachinesClient) ListAvailableSizes(ctx context.Context, reso
|
|||
result, err = client.ListAvailableSizesResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "ListAvailableSizes", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -1024,6 +1134,11 @@ func (client VirtualMachinesClient) ListByLocation(ctx context.Context, location
|
|||
result.vmlr, err = client.ListByLocationResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "ListByLocation", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vmlr.hasNextLink() && result.vmlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -1104,7 +1219,8 @@ func (client VirtualMachinesClient) ListByLocationComplete(ctx context.Context,
|
|||
return
|
||||
}
|
||||
|
||||
// PerformMaintenance the operation to perform maintenance on a virtual machine.
|
||||
// PerformMaintenance shuts down the virtual machine, moves it to an already updated node, and powers it back on during
|
||||
// the self-service phase of planned maintenance.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// VMName - the name of the virtual machine.
|
||||
|
|
@ -1127,7 +1243,7 @@ func (client VirtualMachinesClient) PerformMaintenance(ctx context.Context, reso
|
|||
|
||||
result, err = client.PerformMaintenanceSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "PerformMaintenance", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "PerformMaintenance", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1163,7 +1279,23 @@ func (client VirtualMachinesClient) PerformMaintenanceSender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesPerformMaintenanceFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesPerformMaintenanceFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1205,7 +1337,7 @@ func (client VirtualMachinesClient) PowerOff(ctx context.Context, resourceGroupN
|
|||
|
||||
result, err = client.PowerOffSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "PowerOff", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "PowerOff", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1246,7 +1378,23 @@ func (client VirtualMachinesClient) PowerOffSender(req *http.Request) (future Vi
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesPowerOffFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesPowerOffFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1284,7 +1432,7 @@ func (client VirtualMachinesClient) Reapply(ctx context.Context, resourceGroupNa
|
|||
|
||||
result, err = client.ReapplySender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Reapply", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Reapply", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1320,7 +1468,23 @@ func (client VirtualMachinesClient) ReapplySender(req *http.Request) (future Vir
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesReapplyFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesReapplyFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1358,7 +1522,7 @@ func (client VirtualMachinesClient) Redeploy(ctx context.Context, resourceGroupN
|
|||
|
||||
result, err = client.RedeploySender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Redeploy", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Redeploy", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1394,7 +1558,23 @@ func (client VirtualMachinesClient) RedeploySender(req *http.Request) (future Vi
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesRedeployFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesRedeployFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1433,7 +1613,7 @@ func (client VirtualMachinesClient) Reimage(ctx context.Context, resourceGroupNa
|
|||
|
||||
result, err = client.ReimageSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Reimage", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Reimage", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1474,7 +1654,23 @@ func (client VirtualMachinesClient) ReimageSender(req *http.Request) (future Vir
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesReimageFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesReimageFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1512,7 +1708,7 @@ func (client VirtualMachinesClient) Restart(ctx context.Context, resourceGroupNa
|
|||
|
||||
result, err = client.RestartSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Restart", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Restart", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1548,7 +1744,23 @@ func (client VirtualMachinesClient) RestartSender(req *http.Request) (future Vir
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesRestartFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesRestartFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1593,7 +1805,7 @@ func (client VirtualMachinesClient) RunCommand(ctx context.Context, resourceGrou
|
|||
|
||||
result, err = client.RunCommandSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "RunCommand", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "RunCommand", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1631,7 +1843,29 @@ func (client VirtualMachinesClient) RunCommandSender(req *http.Request) (future
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (rcr RunCommandResult, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesRunCommandFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesRunCommandFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if rcr.Response.Response, err = future.GetResult(sender); err == nil && rcr.Response.Response.StatusCode != http.StatusNoContent {
|
||||
rcr, err = client.RunCommandResponder(rcr.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesRunCommandFuture", "Result", rcr.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1670,7 +1904,7 @@ func (client VirtualMachinesClient) Start(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.StartSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Start", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Start", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1706,7 +1940,23 @@ func (client VirtualMachinesClient) StartSender(req *http.Request) (future Virtu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesStartFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesStartFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1745,7 +1995,7 @@ func (client VirtualMachinesClient) Update(ctx context.Context, resourceGroupNam
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1783,7 +2033,29 @@ func (client VirtualMachinesClient) UpdateSender(req *http.Request) (future Virt
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachinesClient) (VM VirtualMachine, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachinesUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if VM.Response.Response, err = future.GetResult(sender); err == nil && VM.Response.Response.StatusCode != http.StatusNoContent {
|
||||
VM, err = client.UpdateResponder(VM.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachinesUpdateFuture", "Result", VM.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ func (client VirtualMachineScaleSetExtensionsClient) CreateOrUpdate(ctx context.
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -107,7 +107,29 @@ func (client VirtualMachineScaleSetExtensionsClient) CreateOrUpdateSender(req *h
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetExtensionsClient) (vmsse VirtualMachineScaleSetExtension, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetExtensionsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vmsse.Response.Response, err = future.GetResult(sender); err == nil && vmsse.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vmsse, err = client.CreateOrUpdateResponder(vmsse.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsCreateOrUpdateFuture", "Result", vmsse.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -147,7 +169,7 @@ func (client VirtualMachineScaleSetExtensionsClient) Delete(ctx context.Context,
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -184,7 +206,23 @@ func (client VirtualMachineScaleSetExtensionsClient) DeleteSender(req *http.Requ
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetExtensionsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetExtensionsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -232,6 +270,7 @@ func (client VirtualMachineScaleSetExtensionsClient) Get(ctx context.Context, re
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -312,6 +351,11 @@ func (client VirtualMachineScaleSetExtensionsClient) List(ctx context.Context, r
|
|||
result.vmsselr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vmsselr.hasNextLink() && result.vmsselr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -418,7 +462,7 @@ func (client VirtualMachineScaleSetExtensionsClient) Update(ctx context.Context,
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -459,7 +503,29 @@ func (client VirtualMachineScaleSetExtensionsClient) UpdateSender(req *http.Requ
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetExtensionsClient) (vmsse VirtualMachineScaleSetExtension, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetExtensionsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vmsse.Response.Response, err = future.GetResult(sender); err == nil && vmsse.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vmsse, err = client.UpdateResponder(vmsse.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetExtensionsUpdateFuture", "Result", vmsse.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) Cancel(ctx context.Con
|
|||
|
||||
result, err = client.CancelSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetRollingUpgradesClient", "Cancel", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetRollingUpgradesClient", "Cancel", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -102,7 +102,23 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) CancelSender(req *http
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetRollingUpgradesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetRollingUpgradesCancelFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetRollingUpgradesCancelFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -148,6 +164,7 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) GetLatest(ctx context.
|
|||
result, err = client.GetLatestResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetRollingUpgradesClient", "GetLatest", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -217,7 +234,7 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) StartExtensionUpgrade(
|
|||
|
||||
result, err = client.StartExtensionUpgradeSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetRollingUpgradesClient", "StartExtensionUpgrade", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetRollingUpgradesClient", "StartExtensionUpgrade", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -253,7 +270,23 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) StartExtensionUpgradeS
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetRollingUpgradesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetRollingUpgradesStartExtensionUpgradeFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetRollingUpgradesStartExtensionUpgradeFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -292,7 +325,7 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) StartOSUpgrade(ctx con
|
|||
|
||||
result, err = client.StartOSUpgradeSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetRollingUpgradesClient", "StartOSUpgrade", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetRollingUpgradesClient", "StartOSUpgrade", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -328,7 +361,23 @@ func (client VirtualMachineScaleSetRollingUpgradesClient) StartOSUpgradeSender(r
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetRollingUpgradesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetRollingUpgradesStartOSUpgradeFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetRollingUpgradesStartOSUpgradeFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ func NewVirtualMachineScaleSetsClientWithBaseURI(baseURI string, subscriptionID
|
|||
return VirtualMachineScaleSetsClient{NewWithBaseURI(baseURI, subscriptionID)}
|
||||
}
|
||||
|
||||
// ConvertToSinglePlacementGroup converts SinglePlacementGroup property to false for a existing virtual machine scale
|
||||
// ConvertToSinglePlacementGroup converts SinglePlacementGroup property to true for a existing virtual machine scale
|
||||
// set.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
|
|
@ -76,6 +76,7 @@ func (client VirtualMachineScaleSetsClient) ConvertToSinglePlacementGroup(ctx co
|
|||
result, err = client.ConvertToSinglePlacementGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "ConvertToSinglePlacementGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -168,7 +169,7 @@ func (client VirtualMachineScaleSetsClient) CreateOrUpdate(ctx context.Context,
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -206,7 +207,29 @@ func (client VirtualMachineScaleSetsClient) CreateOrUpdateSender(req *http.Reque
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (vmss VirtualMachineScaleSet, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vmss.Response.Response, err = future.GetResult(sender); err == nil && vmss.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vmss, err = client.CreateOrUpdateResponder(vmss.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsCreateOrUpdateFuture", "Result", vmss.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -247,7 +270,7 @@ func (client VirtualMachineScaleSetsClient) Deallocate(ctx context.Context, reso
|
|||
|
||||
result, err = client.DeallocateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Deallocate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Deallocate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -288,7 +311,23 @@ func (client VirtualMachineScaleSetsClient) DeallocateSender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsDeallocateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsDeallocateFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -326,7 +365,7 @@ func (client VirtualMachineScaleSetsClient) Delete(ctx context.Context, resource
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -362,7 +401,23 @@ func (client VirtualMachineScaleSetsClient) DeleteSender(req *http.Request) (fut
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -407,7 +462,7 @@ func (client VirtualMachineScaleSetsClient) DeleteInstances(ctx context.Context,
|
|||
|
||||
result, err = client.DeleteInstancesSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "DeleteInstances", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "DeleteInstances", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -445,7 +500,23 @@ func (client VirtualMachineScaleSetsClient) DeleteInstancesSender(req *http.Requ
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsDeleteInstancesFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsDeleteInstancesFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -493,6 +564,7 @@ func (client VirtualMachineScaleSetsClient) ForceRecoveryServiceFabricPlatformUp
|
|||
result, err = client.ForceRecoveryServiceFabricPlatformUpdateDomainWalkResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "ForceRecoveryServiceFabricPlatformUpdateDomainWalk", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -569,6 +641,7 @@ func (client VirtualMachineScaleSetsClient) Get(ctx context.Context, resourceGro
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -644,6 +717,7 @@ func (client VirtualMachineScaleSetsClient) GetInstanceView(ctx context.Context,
|
|||
result, err = client.GetInstanceViewResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "GetInstanceView", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -720,6 +794,11 @@ func (client VirtualMachineScaleSetsClient) GetOSUpgradeHistory(ctx context.Cont
|
|||
result.vmsslouh, err = client.GetOSUpgradeHistoryResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "GetOSUpgradeHistory", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vmsslouh.hasNextLink() && result.vmsslouh.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -832,6 +911,11 @@ func (client VirtualMachineScaleSetsClient) List(ctx context.Context, resourceGr
|
|||
result.vmsslr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vmsslr.hasNextLink() && result.vmsslr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -943,6 +1027,11 @@ func (client VirtualMachineScaleSetsClient) ListAll(ctx context.Context) (result
|
|||
result.vmsslwlr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "ListAll", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vmsslwlr.hasNextLink() && result.vmsslwlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -1055,6 +1144,11 @@ func (client VirtualMachineScaleSetsClient) ListSkus(ctx context.Context, resour
|
|||
result.vmsslsr, err = client.ListSkusResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "ListSkus", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vmsslsr.hasNextLink() && result.vmsslsr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -1162,7 +1256,7 @@ func (client VirtualMachineScaleSetsClient) PerformMaintenance(ctx context.Conte
|
|||
|
||||
result, err = client.PerformMaintenanceSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "PerformMaintenance", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "PerformMaintenance", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1203,7 +1297,23 @@ func (client VirtualMachineScaleSetsClient) PerformMaintenanceSender(req *http.R
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsPerformMaintenanceFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsPerformMaintenanceFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1246,7 +1356,7 @@ func (client VirtualMachineScaleSetsClient) PowerOff(ctx context.Context, resour
|
|||
|
||||
result, err = client.PowerOffSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "PowerOff", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "PowerOff", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1292,7 +1402,23 @@ func (client VirtualMachineScaleSetsClient) PowerOffSender(req *http.Request) (f
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsPowerOffFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsPowerOffFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1332,7 +1458,7 @@ func (client VirtualMachineScaleSetsClient) Redeploy(ctx context.Context, resour
|
|||
|
||||
result, err = client.RedeploySender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Redeploy", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Redeploy", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1373,7 +1499,23 @@ func (client VirtualMachineScaleSetsClient) RedeploySender(req *http.Request) (f
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsRedeployFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsRedeployFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1413,7 +1555,7 @@ func (client VirtualMachineScaleSetsClient) Reimage(ctx context.Context, resourc
|
|||
|
||||
result, err = client.ReimageSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Reimage", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Reimage", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1454,7 +1596,23 @@ func (client VirtualMachineScaleSetsClient) ReimageSender(req *http.Request) (fu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsReimageFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsReimageFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1494,7 +1652,7 @@ func (client VirtualMachineScaleSetsClient) ReimageAll(ctx context.Context, reso
|
|||
|
||||
result, err = client.ReimageAllSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "ReimageAll", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "ReimageAll", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1535,7 +1693,23 @@ func (client VirtualMachineScaleSetsClient) ReimageAllSender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsReimageAllFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsReimageAllFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1574,7 +1748,7 @@ func (client VirtualMachineScaleSetsClient) Restart(ctx context.Context, resourc
|
|||
|
||||
result, err = client.RestartSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Restart", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Restart", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1615,7 +1789,23 @@ func (client VirtualMachineScaleSetsClient) RestartSender(req *http.Request) (fu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsRestartFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsRestartFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1654,7 +1844,7 @@ func (client VirtualMachineScaleSetsClient) Start(ctx context.Context, resourceG
|
|||
|
||||
result, err = client.StartSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Start", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Start", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1695,7 +1885,23 @@ func (client VirtualMachineScaleSetsClient) StartSender(req *http.Request) (futu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsStartFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsStartFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1734,7 +1940,7 @@ func (client VirtualMachineScaleSetsClient) Update(ctx context.Context, resource
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1772,7 +1978,29 @@ func (client VirtualMachineScaleSetsClient) UpdateSender(req *http.Request) (fut
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (vmss VirtualMachineScaleSet, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vmss.Response.Response, err = future.GetResult(sender); err == nil && vmss.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vmss, err = client.UpdateResponder(vmss.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsUpdateFuture", "Result", vmss.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1818,7 +2046,7 @@ func (client VirtualMachineScaleSetsClient) UpdateInstances(ctx context.Context,
|
|||
|
||||
result, err = client.UpdateInstancesSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "UpdateInstances", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsClient", "UpdateInstances", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1856,7 +2084,23 @@ func (client VirtualMachineScaleSetsClient) UpdateInstancesSender(req *http.Requ
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetsUpdateInstancesFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetsUpdateInstancesFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ func (client VirtualMachineScaleSetVMExtensionsClient) CreateOrUpdate(ctx contex
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -109,7 +109,29 @@ func (client VirtualMachineScaleSetVMExtensionsClient) CreateOrUpdateSender(req
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMExtensionsClient) (vme VirtualMachineExtension, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vme.Response.Response, err = future.GetResult(sender); err == nil && vme.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vme, err = client.CreateOrUpdateResponder(vme.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsCreateOrUpdateFuture", "Result", vme.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -150,7 +172,7 @@ func (client VirtualMachineScaleSetVMExtensionsClient) Delete(ctx context.Contex
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -188,7 +210,23 @@ func (client VirtualMachineScaleSetVMExtensionsClient) DeleteSender(req *http.Re
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMExtensionsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMExtensionsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -237,6 +275,7 @@ func (client VirtualMachineScaleSetVMExtensionsClient) Get(ctx context.Context,
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -319,6 +358,7 @@ func (client VirtualMachineScaleSetVMExtensionsClient) List(ctx context.Context,
|
|||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -393,7 +433,7 @@ func (client VirtualMachineScaleSetVMExtensionsClient) Update(ctx context.Contex
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -433,7 +473,29 @@ func (client VirtualMachineScaleSetVMExtensionsClient) UpdateSender(req *http.Re
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMExtensionsClient) (vme VirtualMachineExtension, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMExtensionsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vme.Response.Response, err = future.GetResult(sender); err == nil && vme.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vme, err = client.UpdateResponder(vme.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMExtensionsUpdateFuture", "Result", vme.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ func (client VirtualMachineScaleSetVMsClient) Deallocate(ctx context.Context, re
|
|||
|
||||
result, err = client.DeallocateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Deallocate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Deallocate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -106,7 +106,23 @@ func (client VirtualMachineScaleSetVMsClient) DeallocateSender(req *http.Request
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsDeallocateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsDeallocateFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -145,7 +161,7 @@ func (client VirtualMachineScaleSetVMsClient) Delete(ctx context.Context, resour
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -182,7 +198,23 @@ func (client VirtualMachineScaleSetVMsClient) DeleteSender(req *http.Request) (f
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -230,6 +262,7 @@ func (client VirtualMachineScaleSetVMsClient) Get(ctx context.Context, resourceG
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -310,6 +343,7 @@ func (client VirtualMachineScaleSetVMsClient) GetInstanceView(ctx context.Contex
|
|||
result, err = client.GetInstanceViewResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "GetInstanceView", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -391,6 +425,11 @@ func (client VirtualMachineScaleSetVMsClient) List(ctx context.Context, resource
|
|||
result.vmssvlr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vmssvlr.hasNextLink() && result.vmssvlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -481,7 +520,8 @@ func (client VirtualMachineScaleSetVMsClient) ListComplete(ctx context.Context,
|
|||
return
|
||||
}
|
||||
|
||||
// PerformMaintenance performs maintenance on a virtual machine in a VM scale set.
|
||||
// PerformMaintenance shuts down the virtual machine in a VMScaleSet, moves it to an already updated node, and powers
|
||||
// it back on during the self-service phase of planned maintenance.
|
||||
// Parameters:
|
||||
// resourceGroupName - the name of the resource group.
|
||||
// VMScaleSetName - the name of the VM scale set.
|
||||
|
|
@ -505,7 +545,7 @@ func (client VirtualMachineScaleSetVMsClient) PerformMaintenance(ctx context.Con
|
|||
|
||||
result, err = client.PerformMaintenanceSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "PerformMaintenance", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "PerformMaintenance", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -542,7 +582,23 @@ func (client VirtualMachineScaleSetVMsClient) PerformMaintenanceSender(req *http
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsPerformMaintenanceFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsPerformMaintenanceFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -585,7 +641,7 @@ func (client VirtualMachineScaleSetVMsClient) PowerOff(ctx context.Context, reso
|
|||
|
||||
result, err = client.PowerOffSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "PowerOff", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "PowerOff", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -627,7 +683,23 @@ func (client VirtualMachineScaleSetVMsClient) PowerOffSender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsPowerOffFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsPowerOffFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -667,7 +739,7 @@ func (client VirtualMachineScaleSetVMsClient) Redeploy(ctx context.Context, reso
|
|||
|
||||
result, err = client.RedeploySender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Redeploy", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Redeploy", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -704,7 +776,23 @@ func (client VirtualMachineScaleSetVMsClient) RedeploySender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsRedeployFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsRedeployFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -744,7 +832,7 @@ func (client VirtualMachineScaleSetVMsClient) Reimage(ctx context.Context, resou
|
|||
|
||||
result, err = client.ReimageSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Reimage", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Reimage", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -786,7 +874,23 @@ func (client VirtualMachineScaleSetVMsClient) ReimageSender(req *http.Request) (
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsReimageFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsReimageFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -826,7 +930,7 @@ func (client VirtualMachineScaleSetVMsClient) ReimageAll(ctx context.Context, re
|
|||
|
||||
result, err = client.ReimageAllSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "ReimageAll", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "ReimageAll", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -863,7 +967,23 @@ func (client VirtualMachineScaleSetVMsClient) ReimageAllSender(req *http.Request
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsReimageAllFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsReimageAllFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -902,7 +1022,7 @@ func (client VirtualMachineScaleSetVMsClient) Restart(ctx context.Context, resou
|
|||
|
||||
result, err = client.RestartSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Restart", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Restart", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -939,7 +1059,23 @@ func (client VirtualMachineScaleSetVMsClient) RestartSender(req *http.Request) (
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsRestartFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsRestartFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -985,7 +1121,7 @@ func (client VirtualMachineScaleSetVMsClient) RunCommand(ctx context.Context, re
|
|||
|
||||
result, err = client.RunCommandSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "RunCommand", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "RunCommand", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1024,7 +1160,29 @@ func (client VirtualMachineScaleSetVMsClient) RunCommandSender(req *http.Request
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (rcr RunCommandResult, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsRunCommandFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsRunCommandFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if rcr.Response.Response, err = future.GetResult(sender); err == nil && rcr.Response.Response.StatusCode != http.StatusNoContent {
|
||||
rcr, err = client.RunCommandResponder(rcr.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsRunCommandFuture", "Result", rcr.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1064,7 +1222,7 @@ func (client VirtualMachineScaleSetVMsClient) Start(ctx context.Context, resourc
|
|||
|
||||
result, err = client.StartSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Start", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Start", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1101,7 +1259,23 @@ func (client VirtualMachineScaleSetVMsClient) StartSender(req *http.Request) (fu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsStartFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsStartFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1162,7 +1336,7 @@ func (client VirtualMachineScaleSetVMsClient) Update(ctx context.Context, resour
|
|||
|
||||
result, err = client.UpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Update", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsClient", "Update", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -1205,7 +1379,29 @@ func (client VirtualMachineScaleSetVMsClient) UpdateSender(req *http.Request) (f
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualMachineScaleSetVMsClient) (vmssv VirtualMachineScaleSetVM, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("compute.VirtualMachineScaleSetVMsUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vmssv.Response.Response, err = future.GetResult(sender); err == nil && vmssv.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vmssv, err = client.UpdateResponder(vmssv.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineScaleSetVMsUpdateFuture", "Result", vmssv.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -80,6 +80,7 @@ func (client VirtualMachineSizesClient) List(ctx context.Context, location strin
|
|||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "compute.VirtualMachineSizesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
5
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/CHANGELOG.md
generated
vendored
Normal file
5
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/CHANGELOG.md
generated
vendored
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
Generated from https://github.com/Azure/azure-rest-api-specs/tree/3c764635e7d442b3e74caf593029fcd440b3ef82/specification/graphrbac/data-plane/readme.md tag: `1.6`
|
||||
|
||||
Code generator @microsoft.azure/autorest.go@2.1.168
|
||||
|
||||
No exported changes
|
||||
|
|
@ -81,6 +81,7 @@ func (client ApplicationsClient) AddOwner(ctx context.Context, applicationObject
|
|||
result, err = client.AddOwnerResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "AddOwner", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -161,6 +162,7 @@ func (client ApplicationsClient) Create(ctx context.Context, parameters Applicat
|
|||
result, err = client.CreateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "Create", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -235,6 +237,7 @@ func (client ApplicationsClient) Delete(ctx context.Context, applicationObjectID
|
|||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "Delete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -307,6 +310,7 @@ func (client ApplicationsClient) Get(ctx context.Context, applicationObjectID st
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -380,6 +384,7 @@ func (client ApplicationsClient) GetServicePrincipalsIDByAppID(ctx context.Conte
|
|||
result, err = client.GetServicePrincipalsIDByAppIDResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "GetServicePrincipalsIDByAppID", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -459,6 +464,11 @@ func (client ApplicationsClient) List(ctx context.Context, filter string) (resul
|
|||
result.alr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.alr.hasNextLink() && result.alr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -550,6 +560,7 @@ func (client ApplicationsClient) ListKeyCredentials(ctx context.Context, applica
|
|||
result, err = client.ListKeyCredentialsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "ListKeyCredentials", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -623,6 +634,7 @@ func (client ApplicationsClient) ListNext(ctx context.Context, nextLink string)
|
|||
result, err = client.ListNextResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "ListNext", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -697,6 +709,11 @@ func (client ApplicationsClient) ListOwners(ctx context.Context, applicationObje
|
|||
result.dolr, err = client.ListOwnersResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "ListOwners", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dolr.hasNextLink() && result.dolr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -807,6 +824,7 @@ func (client ApplicationsClient) ListPasswordCredentials(ctx context.Context, ap
|
|||
result, err = client.ListPasswordCredentialsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "ListPasswordCredentials", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -881,6 +899,7 @@ func (client ApplicationsClient) Patch(ctx context.Context, applicationObjectID
|
|||
result, err = client.PatchResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "Patch", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -956,6 +975,7 @@ func (client ApplicationsClient) RemoveOwner(ctx context.Context, applicationObj
|
|||
result, err = client.RemoveOwnerResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "RemoveOwner", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -1030,6 +1050,7 @@ func (client ApplicationsClient) UpdateKeyCredentials(ctx context.Context, appli
|
|||
result, err = client.UpdateKeyCredentialsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "UpdateKeyCredentials", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -1105,6 +1126,7 @@ func (client ApplicationsClient) UpdatePasswordCredentials(ctx context.Context,
|
|||
result, err = client.UpdatePasswordCredentialsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ApplicationsClient", "UpdatePasswordCredentials", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -73,6 +73,7 @@ func (client DeletedApplicationsClient) HardDelete(ctx context.Context, applicat
|
|||
result, err = client.HardDeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.DeletedApplicationsClient", "HardDelete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -151,6 +152,11 @@ func (client DeletedApplicationsClient) List(ctx context.Context, filter string)
|
|||
result.alr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.DeletedApplicationsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.alr.hasNextLink() && result.alr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -242,6 +248,7 @@ func (client DeletedApplicationsClient) ListNext(ctx context.Context, nextLink s
|
|||
result, err = client.ListNextResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.DeletedApplicationsClient", "ListNext", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -315,6 +322,7 @@ func (client DeletedApplicationsClient) Restore(ctx context.Context, objectID st
|
|||
result, err = client.RestoreResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.DeletedApplicationsClient", "Restore", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
2
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/domains.go
generated
vendored
2
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/domains.go
generated
vendored
|
|
@ -71,6 +71,7 @@ func (client DomainsClient) Get(ctx context.Context, domainName string) (result
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.DomainsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -144,6 +145,7 @@ func (client DomainsClient) List(ctx context.Context, filter string) (result Dom
|
|||
result, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.DomainsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
86
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/enums.go
generated
vendored
Normal file
86
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/enums.go
generated
vendored
Normal file
|
|
@ -0,0 +1,86 @@
|
|||
package graphrbac
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
// ConsentType enumerates the values for consent type.
|
||||
type ConsentType string
|
||||
|
||||
const (
|
||||
// AllPrincipals ...
|
||||
AllPrincipals ConsentType = "AllPrincipals"
|
||||
// Principal ...
|
||||
Principal ConsentType = "Principal"
|
||||
)
|
||||
|
||||
// PossibleConsentTypeValues returns an array of possible values for the ConsentType const type.
|
||||
func PossibleConsentTypeValues() []ConsentType {
|
||||
return []ConsentType{AllPrincipals, Principal}
|
||||
}
|
||||
|
||||
// GroupMembershipClaimTypes enumerates the values for group membership claim types.
|
||||
type GroupMembershipClaimTypes string
|
||||
|
||||
const (
|
||||
// All ...
|
||||
All GroupMembershipClaimTypes = "All"
|
||||
// None ...
|
||||
None GroupMembershipClaimTypes = "None"
|
||||
// SecurityGroup ...
|
||||
SecurityGroup GroupMembershipClaimTypes = "SecurityGroup"
|
||||
)
|
||||
|
||||
// PossibleGroupMembershipClaimTypesValues returns an array of possible values for the GroupMembershipClaimTypes const type.
|
||||
func PossibleGroupMembershipClaimTypesValues() []GroupMembershipClaimTypes {
|
||||
return []GroupMembershipClaimTypes{All, None, SecurityGroup}
|
||||
}
|
||||
|
||||
// ObjectType enumerates the values for object type.
|
||||
type ObjectType string
|
||||
|
||||
const (
|
||||
// ObjectTypeApplication ...
|
||||
ObjectTypeApplication ObjectType = "Application"
|
||||
// ObjectTypeDirectoryObject ...
|
||||
ObjectTypeDirectoryObject ObjectType = "DirectoryObject"
|
||||
// ObjectTypeGroup ...
|
||||
ObjectTypeGroup ObjectType = "Group"
|
||||
// ObjectTypeServicePrincipal ...
|
||||
ObjectTypeServicePrincipal ObjectType = "ServicePrincipal"
|
||||
// ObjectTypeUser ...
|
||||
ObjectTypeUser ObjectType = "User"
|
||||
)
|
||||
|
||||
// PossibleObjectTypeValues returns an array of possible values for the ObjectType const type.
|
||||
func PossibleObjectTypeValues() []ObjectType {
|
||||
return []ObjectType{ObjectTypeApplication, ObjectTypeDirectoryObject, ObjectTypeGroup, ObjectTypeServicePrincipal, ObjectTypeUser}
|
||||
}
|
||||
|
||||
// UserType enumerates the values for user type.
|
||||
type UserType string
|
||||
|
||||
const (
|
||||
// Guest ...
|
||||
Guest UserType = "Guest"
|
||||
// Member ...
|
||||
Member UserType = "Member"
|
||||
)
|
||||
|
||||
// PossibleUserTypeValues returns an array of possible values for the UserType const type.
|
||||
func PossibleUserTypeValues() []UserType {
|
||||
return []UserType{Guest, Member}
|
||||
}
|
||||
26
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/groups.go
generated
vendored
26
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/groups.go
generated
vendored
|
|
@ -81,6 +81,7 @@ func (client GroupsClient) AddMember(ctx context.Context, groupObjectID string,
|
|||
result, err = client.AddMemberResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "AddMember", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -163,6 +164,7 @@ func (client GroupsClient) AddOwner(ctx context.Context, objectID string, parame
|
|||
result, err = client.AddOwnerResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "AddOwner", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -246,6 +248,7 @@ func (client GroupsClient) Create(ctx context.Context, parameters GroupCreatePar
|
|||
result, err = client.CreateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "Create", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -320,6 +323,7 @@ func (client GroupsClient) Delete(ctx context.Context, objectID string) (result
|
|||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "Delete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -392,6 +396,7 @@ func (client GroupsClient) Get(ctx context.Context, objectID string) (result ADG
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -471,6 +476,11 @@ func (client GroupsClient) GetGroupMembers(ctx context.Context, objectID string)
|
|||
result.dolr, err = client.GetGroupMembersResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "GetGroupMembers", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dolr.hasNextLink() && result.dolr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -560,6 +570,7 @@ func (client GroupsClient) GetGroupMembersNext(ctx context.Context, nextLink str
|
|||
result, err = client.GetGroupMembersNextResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "GetGroupMembersNext", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -640,6 +651,7 @@ func (client GroupsClient) GetMemberGroups(ctx context.Context, objectID string,
|
|||
result, err = client.GetMemberGroupsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "GetMemberGroups", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -723,6 +735,7 @@ func (client GroupsClient) IsMemberOf(ctx context.Context, parameters CheckGroup
|
|||
result, err = client.IsMemberOfResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "IsMemberOf", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -803,6 +816,11 @@ func (client GroupsClient) List(ctx context.Context, filter string) (result Grou
|
|||
result.glr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.glr.hasNextLink() && result.glr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -894,6 +912,7 @@ func (client GroupsClient) ListNext(ctx context.Context, nextLink string) (resul
|
|||
result, err = client.ListNextResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "ListNext", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -968,6 +987,11 @@ func (client GroupsClient) ListOwners(ctx context.Context, objectID string) (res
|
|||
result.dolr, err = client.ListOwnersResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "ListOwners", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dolr.hasNextLink() && result.dolr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -1079,6 +1103,7 @@ func (client GroupsClient) RemoveMember(ctx context.Context, groupObjectID strin
|
|||
result, err = client.RemoveMemberResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "RemoveMember", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -1153,6 +1178,7 @@ func (client GroupsClient) RemoveOwner(ctx context.Context, objectID string, own
|
|||
result, err = client.RemoveOwnerResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.GroupsClient", "RemoveOwner", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
220
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/models.go
generated
vendored
220
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/models.go
generated
vendored
|
|
@ -30,74 +30,6 @@ import (
|
|||
// The package's fully qualified name.
|
||||
const fqdn = "github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac"
|
||||
|
||||
// ConsentType enumerates the values for consent type.
|
||||
type ConsentType string
|
||||
|
||||
const (
|
||||
// AllPrincipals ...
|
||||
AllPrincipals ConsentType = "AllPrincipals"
|
||||
// Principal ...
|
||||
Principal ConsentType = "Principal"
|
||||
)
|
||||
|
||||
// PossibleConsentTypeValues returns an array of possible values for the ConsentType const type.
|
||||
func PossibleConsentTypeValues() []ConsentType {
|
||||
return []ConsentType{AllPrincipals, Principal}
|
||||
}
|
||||
|
||||
// GroupMembershipClaimTypes enumerates the values for group membership claim types.
|
||||
type GroupMembershipClaimTypes string
|
||||
|
||||
const (
|
||||
// All ...
|
||||
All GroupMembershipClaimTypes = "All"
|
||||
// None ...
|
||||
None GroupMembershipClaimTypes = "None"
|
||||
// SecurityGroup ...
|
||||
SecurityGroup GroupMembershipClaimTypes = "SecurityGroup"
|
||||
)
|
||||
|
||||
// PossibleGroupMembershipClaimTypesValues returns an array of possible values for the GroupMembershipClaimTypes const type.
|
||||
func PossibleGroupMembershipClaimTypesValues() []GroupMembershipClaimTypes {
|
||||
return []GroupMembershipClaimTypes{All, None, SecurityGroup}
|
||||
}
|
||||
|
||||
// ObjectType enumerates the values for object type.
|
||||
type ObjectType string
|
||||
|
||||
const (
|
||||
// ObjectTypeApplication ...
|
||||
ObjectTypeApplication ObjectType = "Application"
|
||||
// ObjectTypeDirectoryObject ...
|
||||
ObjectTypeDirectoryObject ObjectType = "DirectoryObject"
|
||||
// ObjectTypeGroup ...
|
||||
ObjectTypeGroup ObjectType = "Group"
|
||||
// ObjectTypeServicePrincipal ...
|
||||
ObjectTypeServicePrincipal ObjectType = "ServicePrincipal"
|
||||
// ObjectTypeUser ...
|
||||
ObjectTypeUser ObjectType = "User"
|
||||
)
|
||||
|
||||
// PossibleObjectTypeValues returns an array of possible values for the ObjectType const type.
|
||||
func PossibleObjectTypeValues() []ObjectType {
|
||||
return []ObjectType{ObjectTypeApplication, ObjectTypeDirectoryObject, ObjectTypeGroup, ObjectTypeServicePrincipal, ObjectTypeUser}
|
||||
}
|
||||
|
||||
// UserType enumerates the values for user type.
|
||||
type UserType string
|
||||
|
||||
const (
|
||||
// Guest ...
|
||||
Guest UserType = "Guest"
|
||||
// Member ...
|
||||
Member UserType = "Member"
|
||||
)
|
||||
|
||||
// PossibleUserTypeValues returns an array of possible values for the UserType const type.
|
||||
func PossibleUserTypeValues() []UserType {
|
||||
return []UserType{Guest, Member}
|
||||
}
|
||||
|
||||
// AddOwnerParameters request parameters for adding a owner to an application.
|
||||
type AddOwnerParameters struct {
|
||||
// AdditionalProperties - Unmatched properties from the message are deserialized this collection
|
||||
|
|
@ -1094,6 +1026,11 @@ func (alr ApplicationListResult) IsEmpty() bool {
|
|||
return alr.Value == nil || len(*alr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (alr ApplicationListResult) hasNextLink() bool {
|
||||
return alr.OdataNextLink != nil && len(*alr.OdataNextLink) != 0
|
||||
}
|
||||
|
||||
// ApplicationListResultPage contains a page of Application values.
|
||||
type ApplicationListResultPage struct {
|
||||
fn func(context.Context, ApplicationListResult) (ApplicationListResult, error)
|
||||
|
|
@ -1113,11 +1050,16 @@ func (page *ApplicationListResultPage) NextWithContext(ctx context.Context) (err
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.alr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.alr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.alr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.alr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -1147,8 +1089,11 @@ func (page ApplicationListResultPage) Values() []Application {
|
|||
}
|
||||
|
||||
// Creates a new instance of the ApplicationListResultPage type.
|
||||
func NewApplicationListResultPage(getNextPage func(context.Context, ApplicationListResult) (ApplicationListResult, error)) ApplicationListResultPage {
|
||||
return ApplicationListResultPage{fn: getNextPage}
|
||||
func NewApplicationListResultPage(cur ApplicationListResult, getNextPage func(context.Context, ApplicationListResult) (ApplicationListResult, error)) ApplicationListResultPage {
|
||||
return ApplicationListResultPage{
|
||||
fn: getNextPage,
|
||||
alr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// ApplicationUpdateParameters request parameters for updating a new application.
|
||||
|
|
@ -1635,10 +1580,15 @@ func (dolr DirectoryObjectListResult) IsEmpty() bool {
|
|||
return dolr.Value == nil || len(*dolr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (dolr DirectoryObjectListResult) hasNextLink() bool {
|
||||
return dolr.OdataNextLink != nil && len(*dolr.OdataNextLink) != 0
|
||||
}
|
||||
|
||||
// directoryObjectListResultPreparer prepares a request to retrieve the next set of results.
|
||||
// It returns nil if no more results exist.
|
||||
func (dolr DirectoryObjectListResult) directoryObjectListResultPreparer(ctx context.Context) (*http.Request, error) {
|
||||
if dolr.OdataNextLink == nil || len(to.String(dolr.OdataNextLink)) < 1 {
|
||||
if !dolr.hasNextLink() {
|
||||
return nil, nil
|
||||
}
|
||||
return autorest.Prepare((&http.Request{}).WithContext(ctx),
|
||||
|
|
@ -1666,11 +1616,16 @@ func (page *DirectoryObjectListResultPage) NextWithContext(ctx context.Context)
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.dolr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.dolr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.dolr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.dolr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -1700,8 +1655,11 @@ func (page DirectoryObjectListResultPage) Values() []BasicDirectoryObject {
|
|||
}
|
||||
|
||||
// Creates a new instance of the DirectoryObjectListResultPage type.
|
||||
func NewDirectoryObjectListResultPage(getNextPage func(context.Context, DirectoryObjectListResult) (DirectoryObjectListResult, error)) DirectoryObjectListResultPage {
|
||||
return DirectoryObjectListResultPage{fn: getNextPage}
|
||||
func NewDirectoryObjectListResultPage(cur DirectoryObjectListResult, getNextPage func(context.Context, DirectoryObjectListResult) (DirectoryObjectListResult, error)) DirectoryObjectListResultPage {
|
||||
return DirectoryObjectListResultPage{
|
||||
fn: getNextPage,
|
||||
dolr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// Domain active Directory Domain information.
|
||||
|
|
@ -2224,6 +2182,11 @@ func (glr GroupListResult) IsEmpty() bool {
|
|||
return glr.Value == nil || len(*glr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (glr GroupListResult) hasNextLink() bool {
|
||||
return glr.OdataNextLink != nil && len(*glr.OdataNextLink) != 0
|
||||
}
|
||||
|
||||
// GroupListResultPage contains a page of ADGroup values.
|
||||
type GroupListResultPage struct {
|
||||
fn func(context.Context, GroupListResult) (GroupListResult, error)
|
||||
|
|
@ -2243,11 +2206,16 @@ func (page *GroupListResultPage) NextWithContext(ctx context.Context) (err error
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.glr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.glr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.glr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.glr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -2277,8 +2245,11 @@ func (page GroupListResultPage) Values() []ADGroup {
|
|||
}
|
||||
|
||||
// Creates a new instance of the GroupListResultPage type.
|
||||
func NewGroupListResultPage(getNextPage func(context.Context, GroupListResult) (GroupListResult, error)) GroupListResultPage {
|
||||
return GroupListResultPage{fn: getNextPage}
|
||||
func NewGroupListResultPage(cur GroupListResult, getNextPage func(context.Context, GroupListResult) (GroupListResult, error)) GroupListResultPage {
|
||||
return GroupListResultPage{
|
||||
fn: getNextPage,
|
||||
glr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// InformationalURL represents a group of URIs that provide terms of service, marketing, support and
|
||||
|
|
@ -2571,6 +2542,11 @@ func (oa2pglr OAuth2PermissionGrantListResult) IsEmpty() bool {
|
|||
return oa2pglr.Value == nil || len(*oa2pglr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (oa2pglr OAuth2PermissionGrantListResult) hasNextLink() bool {
|
||||
return oa2pglr.OdataNextLink != nil && len(*oa2pglr.OdataNextLink) != 0
|
||||
}
|
||||
|
||||
// OAuth2PermissionGrantListResultPage contains a page of OAuth2PermissionGrant values.
|
||||
type OAuth2PermissionGrantListResultPage struct {
|
||||
fn func(context.Context, OAuth2PermissionGrantListResult) (OAuth2PermissionGrantListResult, error)
|
||||
|
|
@ -2590,11 +2566,16 @@ func (page *OAuth2PermissionGrantListResultPage) NextWithContext(ctx context.Con
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.oa2pglr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.oa2pglr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.oa2pglr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.oa2pglr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -2624,8 +2605,11 @@ func (page OAuth2PermissionGrantListResultPage) Values() []OAuth2PermissionGrant
|
|||
}
|
||||
|
||||
// Creates a new instance of the OAuth2PermissionGrantListResultPage type.
|
||||
func NewOAuth2PermissionGrantListResultPage(getNextPage func(context.Context, OAuth2PermissionGrantListResult) (OAuth2PermissionGrantListResult, error)) OAuth2PermissionGrantListResultPage {
|
||||
return OAuth2PermissionGrantListResultPage{fn: getNextPage}
|
||||
func NewOAuth2PermissionGrantListResultPage(cur OAuth2PermissionGrantListResult, getNextPage func(context.Context, OAuth2PermissionGrantListResult) (OAuth2PermissionGrantListResult, error)) OAuth2PermissionGrantListResultPage {
|
||||
return OAuth2PermissionGrantListResultPage{
|
||||
fn: getNextPage,
|
||||
oa2pglr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// OdataError active Directory OData error information.
|
||||
|
|
@ -3574,6 +3558,11 @@ func (splr ServicePrincipalListResult) IsEmpty() bool {
|
|||
return splr.Value == nil || len(*splr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (splr ServicePrincipalListResult) hasNextLink() bool {
|
||||
return splr.OdataNextLink != nil && len(*splr.OdataNextLink) != 0
|
||||
}
|
||||
|
||||
// ServicePrincipalListResultPage contains a page of ServicePrincipal values.
|
||||
type ServicePrincipalListResultPage struct {
|
||||
fn func(context.Context, ServicePrincipalListResult) (ServicePrincipalListResult, error)
|
||||
|
|
@ -3593,11 +3582,16 @@ func (page *ServicePrincipalListResultPage) NextWithContext(ctx context.Context)
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.splr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.splr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.splr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.splr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -3627,8 +3621,11 @@ func (page ServicePrincipalListResultPage) Values() []ServicePrincipal {
|
|||
}
|
||||
|
||||
// Creates a new instance of the ServicePrincipalListResultPage type.
|
||||
func NewServicePrincipalListResultPage(getNextPage func(context.Context, ServicePrincipalListResult) (ServicePrincipalListResult, error)) ServicePrincipalListResultPage {
|
||||
return ServicePrincipalListResultPage{fn: getNextPage}
|
||||
func NewServicePrincipalListResultPage(cur ServicePrincipalListResult, getNextPage func(context.Context, ServicePrincipalListResult) (ServicePrincipalListResult, error)) ServicePrincipalListResultPage {
|
||||
return ServicePrincipalListResultPage{
|
||||
fn: getNextPage,
|
||||
splr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// ServicePrincipalObjectResult service Principal Object Result.
|
||||
|
|
@ -4439,6 +4436,11 @@ func (ulr UserListResult) IsEmpty() bool {
|
|||
return ulr.Value == nil || len(*ulr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (ulr UserListResult) hasNextLink() bool {
|
||||
return ulr.OdataNextLink != nil && len(*ulr.OdataNextLink) != 0
|
||||
}
|
||||
|
||||
// UserListResultPage contains a page of User values.
|
||||
type UserListResultPage struct {
|
||||
fn func(context.Context, UserListResult) (UserListResult, error)
|
||||
|
|
@ -4458,11 +4460,16 @@ func (page *UserListResultPage) NextWithContext(ctx context.Context) (err error)
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.ulr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.ulr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.ulr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.ulr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -4492,8 +4499,11 @@ func (page UserListResultPage) Values() []User {
|
|||
}
|
||||
|
||||
// Creates a new instance of the UserListResultPage type.
|
||||
func NewUserListResultPage(getNextPage func(context.Context, UserListResult) (UserListResult, error)) UserListResultPage {
|
||||
return UserListResultPage{fn: getNextPage}
|
||||
func NewUserListResultPage(cur UserListResult, getNextPage func(context.Context, UserListResult) (UserListResult, error)) UserListResultPage {
|
||||
return UserListResultPage{
|
||||
fn: getNextPage,
|
||||
ulr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// UserUpdateParameters request parameters for updating an existing work or school account user.
|
||||
|
|
|
|||
|
|
@ -73,6 +73,7 @@ func (client OAuth2PermissionGrantClient) Create(ctx context.Context, body *OAut
|
|||
result, err = client.CreateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.OAuth2PermissionGrantClient", "Create", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -150,6 +151,7 @@ func (client OAuth2PermissionGrantClient) Delete(ctx context.Context, objectID s
|
|||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.OAuth2PermissionGrantClient", "Delete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -228,6 +230,11 @@ func (client OAuth2PermissionGrantClient) List(ctx context.Context, filter strin
|
|||
result.oa2pglr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.OAuth2PermissionGrantClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.oa2pglr.hasNextLink() && result.oa2pglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -319,6 +326,7 @@ func (client OAuth2PermissionGrantClient) ListNext(ctx context.Context, nextLink
|
|||
result, err = client.ListNextResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.OAuth2PermissionGrantClient", "ListNext", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
6
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/objects.go
generated
vendored
6
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/objects.go
generated
vendored
|
|
@ -79,6 +79,11 @@ func (client ObjectsClient) GetObjectsByObjectIds(ctx context.Context, parameter
|
|||
result.dolr, err = client.GetObjectsByObjectIdsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ObjectsClient", "GetObjectsByObjectIds", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dolr.hasNextLink() && result.dolr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -169,6 +174,7 @@ func (client ObjectsClient) GetObjectsByObjectIdsNext(ctx context.Context, nextL
|
|||
result, err = client.GetObjectsByObjectIdsNextResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ObjectsClient", "GetObjectsByObjectIdsNext", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -80,6 +80,7 @@ func (client ServicePrincipalsClient) Create(ctx context.Context, parameters Ser
|
|||
result, err = client.CreateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "Create", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -154,6 +155,7 @@ func (client ServicePrincipalsClient) Delete(ctx context.Context, objectID strin
|
|||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "Delete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -226,6 +228,7 @@ func (client ServicePrincipalsClient) Get(ctx context.Context, objectID string)
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -305,6 +308,11 @@ func (client ServicePrincipalsClient) List(ctx context.Context, filter string) (
|
|||
result.splr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.splr.hasNextLink() && result.splr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -396,6 +404,7 @@ func (client ServicePrincipalsClient) ListKeyCredentials(ctx context.Context, ob
|
|||
result, err = client.ListKeyCredentialsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "ListKeyCredentials", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -469,6 +478,7 @@ func (client ServicePrincipalsClient) ListNext(ctx context.Context, nextLink str
|
|||
result, err = client.ListNextResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "ListNext", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -543,6 +553,11 @@ func (client ServicePrincipalsClient) ListOwners(ctx context.Context, objectID s
|
|||
result.dolr, err = client.ListOwnersResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "ListOwners", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dolr.hasNextLink() && result.dolr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -653,6 +668,7 @@ func (client ServicePrincipalsClient) ListPasswordCredentials(ctx context.Contex
|
|||
result, err = client.ListPasswordCredentialsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "ListPasswordCredentials", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -727,6 +743,7 @@ func (client ServicePrincipalsClient) Update(ctx context.Context, objectID strin
|
|||
result, err = client.UpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "Update", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -802,6 +819,7 @@ func (client ServicePrincipalsClient) UpdateKeyCredentials(ctx context.Context,
|
|||
result, err = client.UpdateKeyCredentialsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "UpdateKeyCredentials", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -877,6 +895,7 @@ func (client ServicePrincipalsClient) UpdatePasswordCredentials(ctx context.Cont
|
|||
result, err = client.UpdatePasswordCredentialsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.ServicePrincipalsClient", "UpdatePasswordCredentials", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -70,6 +70,7 @@ func (client SignedInUserClient) Get(ctx context.Context) (result User, err erro
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.SignedInUserClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -146,6 +147,11 @@ func (client SignedInUserClient) ListOwnedObjects(ctx context.Context) (result D
|
|||
result.dolr, err = client.ListOwnedObjectsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.SignedInUserClient", "ListOwnedObjects", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.dolr.hasNextLink() && result.dolr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -234,6 +240,7 @@ func (client SignedInUserClient) ListOwnedObjectsNext(ctx context.Context, nextL
|
|||
result, err = client.ListOwnedObjectsNextResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.SignedInUserClient", "ListOwnedObjectsNext", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
11
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/users.go
generated
vendored
11
vendor/github.com/Azure/azure-sdk-for-go/services/graphrbac/1.6/graphrbac/users.go
generated
vendored
|
|
@ -84,6 +84,7 @@ func (client UsersClient) Create(ctx context.Context, parameters UserCreateParam
|
|||
result, err = client.CreateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.UsersClient", "Create", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -158,6 +159,7 @@ func (client UsersClient) Delete(ctx context.Context, upnOrObjectID string) (res
|
|||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.UsersClient", "Delete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -230,6 +232,7 @@ func (client UsersClient) Get(ctx context.Context, upnOrObjectID string) (result
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.UsersClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -310,6 +313,7 @@ func (client UsersClient) GetMemberGroups(ctx context.Context, objectID string,
|
|||
result, err = client.GetMemberGroupsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.UsersClient", "GetMemberGroups", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -392,6 +396,11 @@ func (client UsersClient) List(ctx context.Context, filter string, expand string
|
|||
result.ulr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.UsersClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ulr.hasNextLink() && result.ulr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -486,6 +495,7 @@ func (client UsersClient) ListNext(ctx context.Context, nextLink string) (result
|
|||
result, err = client.ListNextResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.UsersClient", "ListNext", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -560,6 +570,7 @@ func (client UsersClient) Update(ctx context.Context, upnOrObjectID string, para
|
|||
result, err = client.UpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "graphrbac.UsersClient", "Update", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
5
vendor/github.com/Azure/azure-sdk-for-go/services/keyvault/v7.0/keyvault/CHANGELOG.md
generated
vendored
Normal file
5
vendor/github.com/Azure/azure-sdk-for-go/services/keyvault/v7.0/keyvault/CHANGELOG.md
generated
vendored
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
Generated from https://github.com/Azure/azure-rest-api-specs/tree/3c764635e7d442b3e74caf593029fcd440b3ef82/specification/keyvault/data-plane/readme.md tag: `package-7.0`
|
||||
|
||||
Code generator @microsoft.azure/autorest.go@2.1.168
|
||||
|
||||
No exported changes
|
||||
221
vendor/github.com/Azure/azure-sdk-for-go/services/keyvault/v7.0/keyvault/client.go
generated
vendored
221
vendor/github.com/Azure/azure-sdk-for-go/services/keyvault/v7.0/keyvault/client.go
generated
vendored
File diff suppressed because it is too large
Load diff
240
vendor/github.com/Azure/azure-sdk-for-go/services/keyvault/v7.0/keyvault/enums.go
generated
vendored
Normal file
240
vendor/github.com/Azure/azure-sdk-for-go/services/keyvault/v7.0/keyvault/enums.go
generated
vendored
Normal file
|
|
@ -0,0 +1,240 @@
|
|||
package keyvault
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
// ActionType enumerates the values for action type.
|
||||
type ActionType string
|
||||
|
||||
const (
|
||||
// AutoRenew ...
|
||||
AutoRenew ActionType = "AutoRenew"
|
||||
// EmailContacts ...
|
||||
EmailContacts ActionType = "EmailContacts"
|
||||
)
|
||||
|
||||
// PossibleActionTypeValues returns an array of possible values for the ActionType const type.
|
||||
func PossibleActionTypeValues() []ActionType {
|
||||
return []ActionType{AutoRenew, EmailContacts}
|
||||
}
|
||||
|
||||
// DeletionRecoveryLevel enumerates the values for deletion recovery level.
|
||||
type DeletionRecoveryLevel string
|
||||
|
||||
const (
|
||||
// CustomizedRecoverable Denotes a vault state in which deletion is recoverable without the possibility for
|
||||
// immediate and permanent deletion (i.e. purge when 7<= SoftDeleteRetentionInDays < 90).This level
|
||||
// guarantees the recoverability of the deleted entity during the retention interval and while the
|
||||
// subscription is still available.
|
||||
CustomizedRecoverable DeletionRecoveryLevel = "CustomizedRecoverable"
|
||||
// CustomizedRecoverableProtectedSubscription Denotes a vault and subscription state in which deletion is
|
||||
// recoverable, immediate and permanent deletion (i.e. purge) is not permitted, and in which the
|
||||
// subscription itself cannot be permanently canceled when 7<= SoftDeleteRetentionInDays < 90. This level
|
||||
// guarantees the recoverability of the deleted entity during the retention interval, and also reflects the
|
||||
// fact that the subscription itself cannot be cancelled.
|
||||
CustomizedRecoverableProtectedSubscription DeletionRecoveryLevel = "CustomizedRecoverable+ProtectedSubscription"
|
||||
// CustomizedRecoverablePurgeable Denotes a vault state in which deletion is recoverable, and which also
|
||||
// permits immediate and permanent deletion (i.e. purge when 7<= SoftDeleteRetentionInDays < 90). This
|
||||
// level guarantees the recoverability of the deleted entity during the retention interval, unless a Purge
|
||||
// operation is requested, or the subscription is cancelled.
|
||||
CustomizedRecoverablePurgeable DeletionRecoveryLevel = "CustomizedRecoverable+Purgeable"
|
||||
// Purgeable Denotes a vault state in which deletion is an irreversible operation, without the possibility
|
||||
// for recovery. This level corresponds to no protection being available against a Delete operation; the
|
||||
// data is irretrievably lost upon accepting a Delete operation at the entity level or higher (vault,
|
||||
// resource group, subscription etc.)
|
||||
Purgeable DeletionRecoveryLevel = "Purgeable"
|
||||
// Recoverable Denotes a vault state in which deletion is recoverable without the possibility for immediate
|
||||
// and permanent deletion (i.e. purge). This level guarantees the recoverability of the deleted entity
|
||||
// during the retention interval(90 days) and while the subscription is still available. System wil
|
||||
// permanently delete it after 90 days, if not recovered
|
||||
Recoverable DeletionRecoveryLevel = "Recoverable"
|
||||
// RecoverableProtectedSubscription Denotes a vault and subscription state in which deletion is recoverable
|
||||
// within retention interval (90 days), immediate and permanent deletion (i.e. purge) is not permitted, and
|
||||
// in which the subscription itself cannot be permanently canceled. System wil permanently delete it after
|
||||
// 90 days, if not recovered
|
||||
RecoverableProtectedSubscription DeletionRecoveryLevel = "Recoverable+ProtectedSubscription"
|
||||
// RecoverablePurgeable Denotes a vault state in which deletion is recoverable, and which also permits
|
||||
// immediate and permanent deletion (i.e. purge). This level guarantees the recoverability of the deleted
|
||||
// entity during the retention interval (90 days), unless a Purge operation is requested, or the
|
||||
// subscription is cancelled. System wil permanently delete it after 90 days, if not recovered
|
||||
RecoverablePurgeable DeletionRecoveryLevel = "Recoverable+Purgeable"
|
||||
)
|
||||
|
||||
// PossibleDeletionRecoveryLevelValues returns an array of possible values for the DeletionRecoveryLevel const type.
|
||||
func PossibleDeletionRecoveryLevelValues() []DeletionRecoveryLevel {
|
||||
return []DeletionRecoveryLevel{CustomizedRecoverable, CustomizedRecoverableProtectedSubscription, CustomizedRecoverablePurgeable, Purgeable, Recoverable, RecoverableProtectedSubscription, RecoverablePurgeable}
|
||||
}
|
||||
|
||||
// JSONWebKeyCurveName enumerates the values for json web key curve name.
|
||||
type JSONWebKeyCurveName string
|
||||
|
||||
const (
|
||||
// P256 The NIST P-256 elliptic curve, AKA SECG curve SECP256R1.
|
||||
P256 JSONWebKeyCurveName = "P-256"
|
||||
// P256K The SECG SECP256K1 elliptic curve.
|
||||
P256K JSONWebKeyCurveName = "P-256K"
|
||||
// P384 The NIST P-384 elliptic curve, AKA SECG curve SECP384R1.
|
||||
P384 JSONWebKeyCurveName = "P-384"
|
||||
// P521 The NIST P-521 elliptic curve, AKA SECG curve SECP521R1.
|
||||
P521 JSONWebKeyCurveName = "P-521"
|
||||
)
|
||||
|
||||
// PossibleJSONWebKeyCurveNameValues returns an array of possible values for the JSONWebKeyCurveName const type.
|
||||
func PossibleJSONWebKeyCurveNameValues() []JSONWebKeyCurveName {
|
||||
return []JSONWebKeyCurveName{P256, P256K, P384, P521}
|
||||
}
|
||||
|
||||
// JSONWebKeyEncryptionAlgorithm enumerates the values for json web key encryption algorithm.
|
||||
type JSONWebKeyEncryptionAlgorithm string
|
||||
|
||||
const (
|
||||
// RSA15 ...
|
||||
RSA15 JSONWebKeyEncryptionAlgorithm = "RSA1_5"
|
||||
// RSAOAEP ...
|
||||
RSAOAEP JSONWebKeyEncryptionAlgorithm = "RSA-OAEP"
|
||||
// RSAOAEP256 ...
|
||||
RSAOAEP256 JSONWebKeyEncryptionAlgorithm = "RSA-OAEP-256"
|
||||
)
|
||||
|
||||
// PossibleJSONWebKeyEncryptionAlgorithmValues returns an array of possible values for the JSONWebKeyEncryptionAlgorithm const type.
|
||||
func PossibleJSONWebKeyEncryptionAlgorithmValues() []JSONWebKeyEncryptionAlgorithm {
|
||||
return []JSONWebKeyEncryptionAlgorithm{RSA15, RSAOAEP, RSAOAEP256}
|
||||
}
|
||||
|
||||
// JSONWebKeyOperation enumerates the values for json web key operation.
|
||||
type JSONWebKeyOperation string
|
||||
|
||||
const (
|
||||
// Decrypt ...
|
||||
Decrypt JSONWebKeyOperation = "decrypt"
|
||||
// Encrypt ...
|
||||
Encrypt JSONWebKeyOperation = "encrypt"
|
||||
// Sign ...
|
||||
Sign JSONWebKeyOperation = "sign"
|
||||
// UnwrapKey ...
|
||||
UnwrapKey JSONWebKeyOperation = "unwrapKey"
|
||||
// Verify ...
|
||||
Verify JSONWebKeyOperation = "verify"
|
||||
// WrapKey ...
|
||||
WrapKey JSONWebKeyOperation = "wrapKey"
|
||||
)
|
||||
|
||||
// PossibleJSONWebKeyOperationValues returns an array of possible values for the JSONWebKeyOperation const type.
|
||||
func PossibleJSONWebKeyOperationValues() []JSONWebKeyOperation {
|
||||
return []JSONWebKeyOperation{Decrypt, Encrypt, Sign, UnwrapKey, Verify, WrapKey}
|
||||
}
|
||||
|
||||
// JSONWebKeySignatureAlgorithm enumerates the values for json web key signature algorithm.
|
||||
type JSONWebKeySignatureAlgorithm string
|
||||
|
||||
const (
|
||||
// ES256 ECDSA using P-256 and SHA-256, as described in https://tools.ietf.org/html/rfc7518.
|
||||
ES256 JSONWebKeySignatureAlgorithm = "ES256"
|
||||
// ES256K ECDSA using P-256K and SHA-256, as described in https://tools.ietf.org/html/rfc7518
|
||||
ES256K JSONWebKeySignatureAlgorithm = "ES256K"
|
||||
// ES384 ECDSA using P-384 and SHA-384, as described in https://tools.ietf.org/html/rfc7518
|
||||
ES384 JSONWebKeySignatureAlgorithm = "ES384"
|
||||
// ES512 ECDSA using P-521 and SHA-512, as described in https://tools.ietf.org/html/rfc7518
|
||||
ES512 JSONWebKeySignatureAlgorithm = "ES512"
|
||||
// PS256 RSASSA-PSS using SHA-256 and MGF1 with SHA-256, as described in
|
||||
// https://tools.ietf.org/html/rfc7518
|
||||
PS256 JSONWebKeySignatureAlgorithm = "PS256"
|
||||
// PS384 RSASSA-PSS using SHA-384 and MGF1 with SHA-384, as described in
|
||||
// https://tools.ietf.org/html/rfc7518
|
||||
PS384 JSONWebKeySignatureAlgorithm = "PS384"
|
||||
// PS512 RSASSA-PSS using SHA-512 and MGF1 with SHA-512, as described in
|
||||
// https://tools.ietf.org/html/rfc7518
|
||||
PS512 JSONWebKeySignatureAlgorithm = "PS512"
|
||||
// RS256 RSASSA-PKCS1-v1_5 using SHA-256, as described in https://tools.ietf.org/html/rfc7518
|
||||
RS256 JSONWebKeySignatureAlgorithm = "RS256"
|
||||
// RS384 RSASSA-PKCS1-v1_5 using SHA-384, as described in https://tools.ietf.org/html/rfc7518
|
||||
RS384 JSONWebKeySignatureAlgorithm = "RS384"
|
||||
// RS512 RSASSA-PKCS1-v1_5 using SHA-512, as described in https://tools.ietf.org/html/rfc7518
|
||||
RS512 JSONWebKeySignatureAlgorithm = "RS512"
|
||||
// RSNULL Reserved
|
||||
RSNULL JSONWebKeySignatureAlgorithm = "RSNULL"
|
||||
)
|
||||
|
||||
// PossibleJSONWebKeySignatureAlgorithmValues returns an array of possible values for the JSONWebKeySignatureAlgorithm const type.
|
||||
func PossibleJSONWebKeySignatureAlgorithmValues() []JSONWebKeySignatureAlgorithm {
|
||||
return []JSONWebKeySignatureAlgorithm{ES256, ES256K, ES384, ES512, PS256, PS384, PS512, RS256, RS384, RS512, RSNULL}
|
||||
}
|
||||
|
||||
// JSONWebKeyType enumerates the values for json web key type.
|
||||
type JSONWebKeyType string
|
||||
|
||||
const (
|
||||
// EC Elliptic Curve.
|
||||
EC JSONWebKeyType = "EC"
|
||||
// ECHSM Elliptic Curve with a private key which is not exportable from the HSM.
|
||||
ECHSM JSONWebKeyType = "EC-HSM"
|
||||
// Oct Not supported in this version. Octet sequence (used to represent symmetric keys)
|
||||
Oct JSONWebKeyType = "oct"
|
||||
// RSA RSA (https://tools.ietf.org/html/rfc3447)
|
||||
RSA JSONWebKeyType = "RSA"
|
||||
// RSAHSM RSA with a private key which is not exportable from the HSM.
|
||||
RSAHSM JSONWebKeyType = "RSA-HSM"
|
||||
)
|
||||
|
||||
// PossibleJSONWebKeyTypeValues returns an array of possible values for the JSONWebKeyType const type.
|
||||
func PossibleJSONWebKeyTypeValues() []JSONWebKeyType {
|
||||
return []JSONWebKeyType{EC, ECHSM, Oct, RSA, RSAHSM}
|
||||
}
|
||||
|
||||
// KeyUsageType enumerates the values for key usage type.
|
||||
type KeyUsageType string
|
||||
|
||||
const (
|
||||
// CRLSign ...
|
||||
CRLSign KeyUsageType = "cRLSign"
|
||||
// DataEncipherment ...
|
||||
DataEncipherment KeyUsageType = "dataEncipherment"
|
||||
// DecipherOnly ...
|
||||
DecipherOnly KeyUsageType = "decipherOnly"
|
||||
// DigitalSignature ...
|
||||
DigitalSignature KeyUsageType = "digitalSignature"
|
||||
// EncipherOnly ...
|
||||
EncipherOnly KeyUsageType = "encipherOnly"
|
||||
// KeyAgreement ...
|
||||
KeyAgreement KeyUsageType = "keyAgreement"
|
||||
// KeyCertSign ...
|
||||
KeyCertSign KeyUsageType = "keyCertSign"
|
||||
// KeyEncipherment ...
|
||||
KeyEncipherment KeyUsageType = "keyEncipherment"
|
||||
// NonRepudiation ...
|
||||
NonRepudiation KeyUsageType = "nonRepudiation"
|
||||
)
|
||||
|
||||
// PossibleKeyUsageTypeValues returns an array of possible values for the KeyUsageType const type.
|
||||
func PossibleKeyUsageTypeValues() []KeyUsageType {
|
||||
return []KeyUsageType{CRLSign, DataEncipherment, DecipherOnly, DigitalSignature, EncipherOnly, KeyAgreement, KeyCertSign, KeyEncipherment, NonRepudiation}
|
||||
}
|
||||
|
||||
// SasTokenType enumerates the values for sas token type.
|
||||
type SasTokenType string
|
||||
|
||||
const (
|
||||
// Account ...
|
||||
Account SasTokenType = "account"
|
||||
// Service ...
|
||||
Service SasTokenType = "service"
|
||||
)
|
||||
|
||||
// PossibleSasTokenTypeValues returns an array of possible values for the SasTokenType const type.
|
||||
func PossibleSasTokenTypeValues() []SasTokenType {
|
||||
return []SasTokenType{Account, Service}
|
||||
}
|
||||
671
vendor/github.com/Azure/azure-sdk-for-go/services/keyvault/v7.0/keyvault/models.go
generated
vendored
671
vendor/github.com/Azure/azure-sdk-for-go/services/keyvault/v7.0/keyvault/models.go
generated
vendored
File diff suppressed because it is too large
Load diff
2
vendor/github.com/Azure/azure-sdk-for-go/services/keyvault/v7.0/keyvault/version.go
generated
vendored
2
vendor/github.com/Azure/azure-sdk-for-go/services/keyvault/v7.0/keyvault/version.go
generated
vendored
|
|
@ -21,7 +21,7 @@ import "github.com/Azure/azure-sdk-for-go/version"
|
|||
|
||||
// UserAgent returns the UserAgent string to use when sending http.Requests.
|
||||
func UserAgent() string {
|
||||
return "Azure-SDK-For-Go/" + version.Number + " keyvault/7.0"
|
||||
return "Azure-SDK-For-Go/" + Version() + " keyvault/7.0"
|
||||
}
|
||||
|
||||
// Version returns the semantic version (see http://semver.org) of the client.
|
||||
|
|
|
|||
170
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2015-06-15/network/CHANGELOG.md
generated
vendored
Normal file
170
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2015-06-15/network/CHANGELOG.md
generated
vendored
Normal file
|
|
@ -0,0 +1,170 @@
|
|||
Generated from https://github.com/Azure/azure-rest-api-specs/tree/3c764635e7d442b3e74caf593029fcd440b3ef82/specification/network/resource-manager/readme.md tag: `package-2015-06split`
|
||||
|
||||
Code generator @microsoft.azure/autorest.go@2.1.168
|
||||
|
||||
## Breaking Changes
|
||||
|
||||
### Removed Funcs
|
||||
|
||||
1. *ApplicationGatewaysCreateOrUpdateFuture.Result(ApplicationGatewaysClient) (ApplicationGateway, error)
|
||||
1. *ApplicationGatewaysDeleteFuture.Result(ApplicationGatewaysClient) (autorest.Response, error)
|
||||
1. *ApplicationGatewaysStartFuture.Result(ApplicationGatewaysClient) (autorest.Response, error)
|
||||
1. *ApplicationGatewaysStopFuture.Result(ApplicationGatewaysClient) (autorest.Response, error)
|
||||
1. *ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture.Result(ExpressRouteCircuitAuthorizationsClient) (ExpressRouteCircuitAuthorization, error)
|
||||
1. *ExpressRouteCircuitAuthorizationsDeleteFuture.Result(ExpressRouteCircuitAuthorizationsClient) (autorest.Response, error)
|
||||
1. *ExpressRouteCircuitPeeringsCreateOrUpdateFuture.Result(ExpressRouteCircuitPeeringsClient) (ExpressRouteCircuitPeering, error)
|
||||
1. *ExpressRouteCircuitPeeringsDeleteFuture.Result(ExpressRouteCircuitPeeringsClient) (autorest.Response, error)
|
||||
1. *ExpressRouteCircuitsCreateOrUpdateFuture.Result(ExpressRouteCircuitsClient) (ExpressRouteCircuit, error)
|
||||
1. *ExpressRouteCircuitsDeleteFuture.Result(ExpressRouteCircuitsClient) (autorest.Response, error)
|
||||
1. *InterfacesCreateOrUpdateFuture.Result(InterfacesClient) (Interface, error)
|
||||
1. *InterfacesDeleteFuture.Result(InterfacesClient) (autorest.Response, error)
|
||||
1. *LoadBalancersCreateOrUpdateFuture.Result(LoadBalancersClient) (LoadBalancer, error)
|
||||
1. *LoadBalancersDeleteFuture.Result(LoadBalancersClient) (autorest.Response, error)
|
||||
1. *LocalNetworkGatewaysCreateOrUpdateFuture.Result(LocalNetworkGatewaysClient) (LocalNetworkGateway, error)
|
||||
1. *LocalNetworkGatewaysDeleteFuture.Result(LocalNetworkGatewaysClient) (autorest.Response, error)
|
||||
1. *PublicIPAddressesCreateOrUpdateFuture.Result(PublicIPAddressesClient) (PublicIPAddress, error)
|
||||
1. *PublicIPAddressesDeleteFuture.Result(PublicIPAddressesClient) (autorest.Response, error)
|
||||
1. *RouteTablesCreateOrUpdateFuture.Result(RouteTablesClient) (RouteTable, error)
|
||||
1. *RouteTablesDeleteFuture.Result(RouteTablesClient) (autorest.Response, error)
|
||||
1. *RoutesCreateOrUpdateFuture.Result(RoutesClient) (Route, error)
|
||||
1. *RoutesDeleteFuture.Result(RoutesClient) (autorest.Response, error)
|
||||
1. *SecurityGroupsCreateOrUpdateFuture.Result(SecurityGroupsClient) (SecurityGroup, error)
|
||||
1. *SecurityGroupsDeleteFuture.Result(SecurityGroupsClient) (autorest.Response, error)
|
||||
1. *SecurityRulesCreateOrUpdateFuture.Result(SecurityRulesClient) (SecurityRule, error)
|
||||
1. *SecurityRulesDeleteFuture.Result(SecurityRulesClient) (autorest.Response, error)
|
||||
1. *SubnetsCreateOrUpdateFuture.Result(SubnetsClient) (Subnet, error)
|
||||
1. *SubnetsDeleteFuture.Result(SubnetsClient) (autorest.Response, error)
|
||||
1. *VirtualNetworkGatewayConnectionsCreateOrUpdateFuture.Result(VirtualNetworkGatewayConnectionsClient) (VirtualNetworkGatewayConnection, error)
|
||||
1. *VirtualNetworkGatewayConnectionsDeleteFuture.Result(VirtualNetworkGatewayConnectionsClient) (autorest.Response, error)
|
||||
1. *VirtualNetworkGatewayConnectionsResetSharedKeyFuture.Result(VirtualNetworkGatewayConnectionsClient) (ConnectionResetSharedKey, error)
|
||||
1. *VirtualNetworkGatewayConnectionsSetSharedKeyFuture.Result(VirtualNetworkGatewayConnectionsClient) (ConnectionSharedKey, error)
|
||||
1. *VirtualNetworkGatewaysCreateOrUpdateFuture.Result(VirtualNetworkGatewaysClient) (VirtualNetworkGateway, error)
|
||||
1. *VirtualNetworkGatewaysDeleteFuture.Result(VirtualNetworkGatewaysClient) (autorest.Response, error)
|
||||
1. *VirtualNetworkGatewaysGeneratevpnclientpackageFuture.Result(VirtualNetworkGatewaysClient) (String, error)
|
||||
1. *VirtualNetworkGatewaysResetFuture.Result(VirtualNetworkGatewaysClient) (VirtualNetworkGateway, error)
|
||||
1. *VirtualNetworksCreateOrUpdateFuture.Result(VirtualNetworksClient) (VirtualNetwork, error)
|
||||
1. *VirtualNetworksDeleteFuture.Result(VirtualNetworksClient) (autorest.Response, error)
|
||||
|
||||
## Struct Changes
|
||||
|
||||
### Removed Struct Fields
|
||||
|
||||
1. ApplicationGatewaysCreateOrUpdateFuture.azure.Future
|
||||
1. ApplicationGatewaysDeleteFuture.azure.Future
|
||||
1. ApplicationGatewaysStartFuture.azure.Future
|
||||
1. ApplicationGatewaysStopFuture.azure.Future
|
||||
1. ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture.azure.Future
|
||||
1. ExpressRouteCircuitAuthorizationsDeleteFuture.azure.Future
|
||||
1. ExpressRouteCircuitPeeringsCreateOrUpdateFuture.azure.Future
|
||||
1. ExpressRouteCircuitPeeringsDeleteFuture.azure.Future
|
||||
1. ExpressRouteCircuitsCreateOrUpdateFuture.azure.Future
|
||||
1. ExpressRouteCircuitsDeleteFuture.azure.Future
|
||||
1. InterfacesCreateOrUpdateFuture.azure.Future
|
||||
1. InterfacesDeleteFuture.azure.Future
|
||||
1. LoadBalancersCreateOrUpdateFuture.azure.Future
|
||||
1. LoadBalancersDeleteFuture.azure.Future
|
||||
1. LocalNetworkGatewaysCreateOrUpdateFuture.azure.Future
|
||||
1. LocalNetworkGatewaysDeleteFuture.azure.Future
|
||||
1. PublicIPAddressesCreateOrUpdateFuture.azure.Future
|
||||
1. PublicIPAddressesDeleteFuture.azure.Future
|
||||
1. RouteTablesCreateOrUpdateFuture.azure.Future
|
||||
1. RouteTablesDeleteFuture.azure.Future
|
||||
1. RoutesCreateOrUpdateFuture.azure.Future
|
||||
1. RoutesDeleteFuture.azure.Future
|
||||
1. SecurityGroupsCreateOrUpdateFuture.azure.Future
|
||||
1. SecurityGroupsDeleteFuture.azure.Future
|
||||
1. SecurityRulesCreateOrUpdateFuture.azure.Future
|
||||
1. SecurityRulesDeleteFuture.azure.Future
|
||||
1. SubnetsCreateOrUpdateFuture.azure.Future
|
||||
1. SubnetsDeleteFuture.azure.Future
|
||||
1. VirtualNetworkGatewayConnectionsCreateOrUpdateFuture.azure.Future
|
||||
1. VirtualNetworkGatewayConnectionsDeleteFuture.azure.Future
|
||||
1. VirtualNetworkGatewayConnectionsResetSharedKeyFuture.azure.Future
|
||||
1. VirtualNetworkGatewayConnectionsSetSharedKeyFuture.azure.Future
|
||||
1. VirtualNetworkGatewaysCreateOrUpdateFuture.azure.Future
|
||||
1. VirtualNetworkGatewaysDeleteFuture.azure.Future
|
||||
1. VirtualNetworkGatewaysGeneratevpnclientpackageFuture.azure.Future
|
||||
1. VirtualNetworkGatewaysResetFuture.azure.Future
|
||||
1. VirtualNetworksCreateOrUpdateFuture.azure.Future
|
||||
1. VirtualNetworksDeleteFuture.azure.Future
|
||||
|
||||
## Struct Changes
|
||||
|
||||
### New Struct Fields
|
||||
|
||||
1. ApplicationGatewaysCreateOrUpdateFuture.Result
|
||||
1. ApplicationGatewaysCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. ApplicationGatewaysDeleteFuture.Result
|
||||
1. ApplicationGatewaysDeleteFuture.azure.FutureAPI
|
||||
1. ApplicationGatewaysStartFuture.Result
|
||||
1. ApplicationGatewaysStartFuture.azure.FutureAPI
|
||||
1. ApplicationGatewaysStopFuture.Result
|
||||
1. ApplicationGatewaysStopFuture.azure.FutureAPI
|
||||
1. ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture.Result
|
||||
1. ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. ExpressRouteCircuitAuthorizationsDeleteFuture.Result
|
||||
1. ExpressRouteCircuitAuthorizationsDeleteFuture.azure.FutureAPI
|
||||
1. ExpressRouteCircuitPeeringsCreateOrUpdateFuture.Result
|
||||
1. ExpressRouteCircuitPeeringsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. ExpressRouteCircuitPeeringsDeleteFuture.Result
|
||||
1. ExpressRouteCircuitPeeringsDeleteFuture.azure.FutureAPI
|
||||
1. ExpressRouteCircuitsCreateOrUpdateFuture.Result
|
||||
1. ExpressRouteCircuitsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. ExpressRouteCircuitsDeleteFuture.Result
|
||||
1. ExpressRouteCircuitsDeleteFuture.azure.FutureAPI
|
||||
1. InterfacesCreateOrUpdateFuture.Result
|
||||
1. InterfacesCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. InterfacesDeleteFuture.Result
|
||||
1. InterfacesDeleteFuture.azure.FutureAPI
|
||||
1. LoadBalancersCreateOrUpdateFuture.Result
|
||||
1. LoadBalancersCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. LoadBalancersDeleteFuture.Result
|
||||
1. LoadBalancersDeleteFuture.azure.FutureAPI
|
||||
1. LocalNetworkGatewaysCreateOrUpdateFuture.Result
|
||||
1. LocalNetworkGatewaysCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. LocalNetworkGatewaysDeleteFuture.Result
|
||||
1. LocalNetworkGatewaysDeleteFuture.azure.FutureAPI
|
||||
1. PublicIPAddressesCreateOrUpdateFuture.Result
|
||||
1. PublicIPAddressesCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. PublicIPAddressesDeleteFuture.Result
|
||||
1. PublicIPAddressesDeleteFuture.azure.FutureAPI
|
||||
1. RouteTablesCreateOrUpdateFuture.Result
|
||||
1. RouteTablesCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. RouteTablesDeleteFuture.Result
|
||||
1. RouteTablesDeleteFuture.azure.FutureAPI
|
||||
1. RoutesCreateOrUpdateFuture.Result
|
||||
1. RoutesCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. RoutesDeleteFuture.Result
|
||||
1. RoutesDeleteFuture.azure.FutureAPI
|
||||
1. SecurityGroupsCreateOrUpdateFuture.Result
|
||||
1. SecurityGroupsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. SecurityGroupsDeleteFuture.Result
|
||||
1. SecurityGroupsDeleteFuture.azure.FutureAPI
|
||||
1. SecurityRulesCreateOrUpdateFuture.Result
|
||||
1. SecurityRulesCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. SecurityRulesDeleteFuture.Result
|
||||
1. SecurityRulesDeleteFuture.azure.FutureAPI
|
||||
1. SubnetsCreateOrUpdateFuture.Result
|
||||
1. SubnetsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. SubnetsDeleteFuture.Result
|
||||
1. SubnetsDeleteFuture.azure.FutureAPI
|
||||
1. VirtualNetworkGatewayConnectionsCreateOrUpdateFuture.Result
|
||||
1. VirtualNetworkGatewayConnectionsCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. VirtualNetworkGatewayConnectionsDeleteFuture.Result
|
||||
1. VirtualNetworkGatewayConnectionsDeleteFuture.azure.FutureAPI
|
||||
1. VirtualNetworkGatewayConnectionsResetSharedKeyFuture.Result
|
||||
1. VirtualNetworkGatewayConnectionsResetSharedKeyFuture.azure.FutureAPI
|
||||
1. VirtualNetworkGatewayConnectionsSetSharedKeyFuture.Result
|
||||
1. VirtualNetworkGatewayConnectionsSetSharedKeyFuture.azure.FutureAPI
|
||||
1. VirtualNetworkGatewaysCreateOrUpdateFuture.Result
|
||||
1. VirtualNetworkGatewaysCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. VirtualNetworkGatewaysDeleteFuture.Result
|
||||
1. VirtualNetworkGatewaysDeleteFuture.azure.FutureAPI
|
||||
1. VirtualNetworkGatewaysGeneratevpnclientpackageFuture.Result
|
||||
1. VirtualNetworkGatewaysGeneratevpnclientpackageFuture.azure.FutureAPI
|
||||
1. VirtualNetworkGatewaysResetFuture.Result
|
||||
1. VirtualNetworkGatewaysResetFuture.azure.FutureAPI
|
||||
1. VirtualNetworksCreateOrUpdateFuture.Result
|
||||
1. VirtualNetworksCreateOrUpdateFuture.azure.FutureAPI
|
||||
1. VirtualNetworksDeleteFuture.Result
|
||||
1. VirtualNetworksDeleteFuture.azure.FutureAPI
|
||||
|
|
@ -66,7 +66,7 @@ func (client ApplicationGatewaysClient) CreateOrUpdate(ctx context.Context, reso
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -104,7 +104,29 @@ func (client ApplicationGatewaysClient) CreateOrUpdateSender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ApplicationGatewaysClient) (ag ApplicationGateway, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.ApplicationGatewaysCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if ag.Response.Response, err = future.GetResult(sender); err == nil && ag.Response.Response.StatusCode != http.StatusNoContent {
|
||||
ag, err = client.CreateOrUpdateResponder(ag.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysCreateOrUpdateFuture", "Result", ag.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -143,7 +165,7 @@ func (client ApplicationGatewaysClient) Delete(ctx context.Context, resourceGrou
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -179,7 +201,23 @@ func (client ApplicationGatewaysClient) DeleteSender(req *http.Request) (future
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ApplicationGatewaysClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.ApplicationGatewaysDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client ApplicationGatewaysClient) Get(ctx context.Context, resourceGroupNa
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -300,6 +339,11 @@ func (client ApplicationGatewaysClient) List(ctx context.Context, resourceGroupN
|
|||
result.aglr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.aglr.hasNextLink() && result.aglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -409,6 +453,11 @@ func (client ApplicationGatewaysClient) ListAll(ctx context.Context) (result App
|
|||
result.aglr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "ListAll", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.aglr.hasNextLink() && result.aglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -511,7 +560,7 @@ func (client ApplicationGatewaysClient) Start(ctx context.Context, resourceGroup
|
|||
|
||||
result, err = client.StartSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "Start", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "Start", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -547,7 +596,23 @@ func (client ApplicationGatewaysClient) StartSender(req *http.Request) (future A
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ApplicationGatewaysClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysStartFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.ApplicationGatewaysStartFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -585,7 +650,7 @@ func (client ApplicationGatewaysClient) Stop(ctx context.Context, resourceGroupN
|
|||
|
||||
result, err = client.StopSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "Stop", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysClient", "Stop", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -621,7 +686,23 @@ func (client ApplicationGatewaysClient) StopSender(req *http.Request) (future Ap
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ApplicationGatewaysClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ApplicationGatewaysStopFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.ApplicationGatewaysStopFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -87,6 +87,7 @@ func (client BaseClient) CheckDNSNameAvailability(ctx context.Context, location
|
|||
result, err = client.CheckDNSNameAvailabilityResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.BaseClient", "CheckDNSNameAvailability", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
493
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2015-06-15/network/enums.go
generated
vendored
Normal file
493
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2015-06-15/network/enums.go
generated
vendored
Normal file
|
|
@ -0,0 +1,493 @@
|
|||
package network
|
||||
|
||||
// Copyright (c) Microsoft and contributors. All rights reserved.
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
//
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
//
|
||||
// Code generated by Microsoft (R) AutoRest Code Generator.
|
||||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
// ApplicationGatewayCookieBasedAffinity enumerates the values for application gateway cookie based affinity.
|
||||
type ApplicationGatewayCookieBasedAffinity string
|
||||
|
||||
const (
|
||||
// Disabled ...
|
||||
Disabled ApplicationGatewayCookieBasedAffinity = "Disabled"
|
||||
// Enabled ...
|
||||
Enabled ApplicationGatewayCookieBasedAffinity = "Enabled"
|
||||
)
|
||||
|
||||
// PossibleApplicationGatewayCookieBasedAffinityValues returns an array of possible values for the ApplicationGatewayCookieBasedAffinity const type.
|
||||
func PossibleApplicationGatewayCookieBasedAffinityValues() []ApplicationGatewayCookieBasedAffinity {
|
||||
return []ApplicationGatewayCookieBasedAffinity{Disabled, Enabled}
|
||||
}
|
||||
|
||||
// ApplicationGatewayOperationalState enumerates the values for application gateway operational state.
|
||||
type ApplicationGatewayOperationalState string
|
||||
|
||||
const (
|
||||
// Running ...
|
||||
Running ApplicationGatewayOperationalState = "Running"
|
||||
// Starting ...
|
||||
Starting ApplicationGatewayOperationalState = "Starting"
|
||||
// Stopped ...
|
||||
Stopped ApplicationGatewayOperationalState = "Stopped"
|
||||
// Stopping ...
|
||||
Stopping ApplicationGatewayOperationalState = "Stopping"
|
||||
)
|
||||
|
||||
// PossibleApplicationGatewayOperationalStateValues returns an array of possible values for the ApplicationGatewayOperationalState const type.
|
||||
func PossibleApplicationGatewayOperationalStateValues() []ApplicationGatewayOperationalState {
|
||||
return []ApplicationGatewayOperationalState{Running, Starting, Stopped, Stopping}
|
||||
}
|
||||
|
||||
// ApplicationGatewayProtocol enumerates the values for application gateway protocol.
|
||||
type ApplicationGatewayProtocol string
|
||||
|
||||
const (
|
||||
// HTTP ...
|
||||
HTTP ApplicationGatewayProtocol = "Http"
|
||||
// HTTPS ...
|
||||
HTTPS ApplicationGatewayProtocol = "Https"
|
||||
)
|
||||
|
||||
// PossibleApplicationGatewayProtocolValues returns an array of possible values for the ApplicationGatewayProtocol const type.
|
||||
func PossibleApplicationGatewayProtocolValues() []ApplicationGatewayProtocol {
|
||||
return []ApplicationGatewayProtocol{HTTP, HTTPS}
|
||||
}
|
||||
|
||||
// ApplicationGatewayRequestRoutingRuleType enumerates the values for application gateway request routing rule
|
||||
// type.
|
||||
type ApplicationGatewayRequestRoutingRuleType string
|
||||
|
||||
const (
|
||||
// Basic ...
|
||||
Basic ApplicationGatewayRequestRoutingRuleType = "Basic"
|
||||
// PathBasedRouting ...
|
||||
PathBasedRouting ApplicationGatewayRequestRoutingRuleType = "PathBasedRouting"
|
||||
)
|
||||
|
||||
// PossibleApplicationGatewayRequestRoutingRuleTypeValues returns an array of possible values for the ApplicationGatewayRequestRoutingRuleType const type.
|
||||
func PossibleApplicationGatewayRequestRoutingRuleTypeValues() []ApplicationGatewayRequestRoutingRuleType {
|
||||
return []ApplicationGatewayRequestRoutingRuleType{Basic, PathBasedRouting}
|
||||
}
|
||||
|
||||
// ApplicationGatewaySkuName enumerates the values for application gateway sku name.
|
||||
type ApplicationGatewaySkuName string
|
||||
|
||||
const (
|
||||
// StandardLarge ...
|
||||
StandardLarge ApplicationGatewaySkuName = "Standard_Large"
|
||||
// StandardMedium ...
|
||||
StandardMedium ApplicationGatewaySkuName = "Standard_Medium"
|
||||
// StandardSmall ...
|
||||
StandardSmall ApplicationGatewaySkuName = "Standard_Small"
|
||||
)
|
||||
|
||||
// PossibleApplicationGatewaySkuNameValues returns an array of possible values for the ApplicationGatewaySkuName const type.
|
||||
func PossibleApplicationGatewaySkuNameValues() []ApplicationGatewaySkuName {
|
||||
return []ApplicationGatewaySkuName{StandardLarge, StandardMedium, StandardSmall}
|
||||
}
|
||||
|
||||
// ApplicationGatewayTier enumerates the values for application gateway tier.
|
||||
type ApplicationGatewayTier string
|
||||
|
||||
const (
|
||||
// Standard ...
|
||||
Standard ApplicationGatewayTier = "Standard"
|
||||
)
|
||||
|
||||
// PossibleApplicationGatewayTierValues returns an array of possible values for the ApplicationGatewayTier const type.
|
||||
func PossibleApplicationGatewayTierValues() []ApplicationGatewayTier {
|
||||
return []ApplicationGatewayTier{Standard}
|
||||
}
|
||||
|
||||
// AuthorizationUseStatus enumerates the values for authorization use status.
|
||||
type AuthorizationUseStatus string
|
||||
|
||||
const (
|
||||
// Available ...
|
||||
Available AuthorizationUseStatus = "Available"
|
||||
// InUse ...
|
||||
InUse AuthorizationUseStatus = "InUse"
|
||||
)
|
||||
|
||||
// PossibleAuthorizationUseStatusValues returns an array of possible values for the AuthorizationUseStatus const type.
|
||||
func PossibleAuthorizationUseStatusValues() []AuthorizationUseStatus {
|
||||
return []AuthorizationUseStatus{Available, InUse}
|
||||
}
|
||||
|
||||
// ExpressRouteCircuitPeeringAdvertisedPublicPrefixState enumerates the values for express route circuit
|
||||
// peering advertised public prefix state.
|
||||
type ExpressRouteCircuitPeeringAdvertisedPublicPrefixState string
|
||||
|
||||
const (
|
||||
// Configured ...
|
||||
Configured ExpressRouteCircuitPeeringAdvertisedPublicPrefixState = "Configured"
|
||||
// Configuring ...
|
||||
Configuring ExpressRouteCircuitPeeringAdvertisedPublicPrefixState = "Configuring"
|
||||
// NotConfigured ...
|
||||
NotConfigured ExpressRouteCircuitPeeringAdvertisedPublicPrefixState = "NotConfigured"
|
||||
// ValidationNeeded ...
|
||||
ValidationNeeded ExpressRouteCircuitPeeringAdvertisedPublicPrefixState = "ValidationNeeded"
|
||||
)
|
||||
|
||||
// PossibleExpressRouteCircuitPeeringAdvertisedPublicPrefixStateValues returns an array of possible values for the ExpressRouteCircuitPeeringAdvertisedPublicPrefixState const type.
|
||||
func PossibleExpressRouteCircuitPeeringAdvertisedPublicPrefixStateValues() []ExpressRouteCircuitPeeringAdvertisedPublicPrefixState {
|
||||
return []ExpressRouteCircuitPeeringAdvertisedPublicPrefixState{Configured, Configuring, NotConfigured, ValidationNeeded}
|
||||
}
|
||||
|
||||
// ExpressRouteCircuitPeeringState enumerates the values for express route circuit peering state.
|
||||
type ExpressRouteCircuitPeeringState string
|
||||
|
||||
const (
|
||||
// ExpressRouteCircuitPeeringStateDisabled ...
|
||||
ExpressRouteCircuitPeeringStateDisabled ExpressRouteCircuitPeeringState = "Disabled"
|
||||
// ExpressRouteCircuitPeeringStateEnabled ...
|
||||
ExpressRouteCircuitPeeringStateEnabled ExpressRouteCircuitPeeringState = "Enabled"
|
||||
)
|
||||
|
||||
// PossibleExpressRouteCircuitPeeringStateValues returns an array of possible values for the ExpressRouteCircuitPeeringState const type.
|
||||
func PossibleExpressRouteCircuitPeeringStateValues() []ExpressRouteCircuitPeeringState {
|
||||
return []ExpressRouteCircuitPeeringState{ExpressRouteCircuitPeeringStateDisabled, ExpressRouteCircuitPeeringStateEnabled}
|
||||
}
|
||||
|
||||
// ExpressRouteCircuitPeeringType enumerates the values for express route circuit peering type.
|
||||
type ExpressRouteCircuitPeeringType string
|
||||
|
||||
const (
|
||||
// AzurePrivatePeering ...
|
||||
AzurePrivatePeering ExpressRouteCircuitPeeringType = "AzurePrivatePeering"
|
||||
// AzurePublicPeering ...
|
||||
AzurePublicPeering ExpressRouteCircuitPeeringType = "AzurePublicPeering"
|
||||
// MicrosoftPeering ...
|
||||
MicrosoftPeering ExpressRouteCircuitPeeringType = "MicrosoftPeering"
|
||||
)
|
||||
|
||||
// PossibleExpressRouteCircuitPeeringTypeValues returns an array of possible values for the ExpressRouteCircuitPeeringType const type.
|
||||
func PossibleExpressRouteCircuitPeeringTypeValues() []ExpressRouteCircuitPeeringType {
|
||||
return []ExpressRouteCircuitPeeringType{AzurePrivatePeering, AzurePublicPeering, MicrosoftPeering}
|
||||
}
|
||||
|
||||
// ExpressRouteCircuitSkuFamily enumerates the values for express route circuit sku family.
|
||||
type ExpressRouteCircuitSkuFamily string
|
||||
|
||||
const (
|
||||
// MeteredData ...
|
||||
MeteredData ExpressRouteCircuitSkuFamily = "MeteredData"
|
||||
// UnlimitedData ...
|
||||
UnlimitedData ExpressRouteCircuitSkuFamily = "UnlimitedData"
|
||||
)
|
||||
|
||||
// PossibleExpressRouteCircuitSkuFamilyValues returns an array of possible values for the ExpressRouteCircuitSkuFamily const type.
|
||||
func PossibleExpressRouteCircuitSkuFamilyValues() []ExpressRouteCircuitSkuFamily {
|
||||
return []ExpressRouteCircuitSkuFamily{MeteredData, UnlimitedData}
|
||||
}
|
||||
|
||||
// ExpressRouteCircuitSkuTier enumerates the values for express route circuit sku tier.
|
||||
type ExpressRouteCircuitSkuTier string
|
||||
|
||||
const (
|
||||
// ExpressRouteCircuitSkuTierPremium ...
|
||||
ExpressRouteCircuitSkuTierPremium ExpressRouteCircuitSkuTier = "Premium"
|
||||
// ExpressRouteCircuitSkuTierStandard ...
|
||||
ExpressRouteCircuitSkuTierStandard ExpressRouteCircuitSkuTier = "Standard"
|
||||
)
|
||||
|
||||
// PossibleExpressRouteCircuitSkuTierValues returns an array of possible values for the ExpressRouteCircuitSkuTier const type.
|
||||
func PossibleExpressRouteCircuitSkuTierValues() []ExpressRouteCircuitSkuTier {
|
||||
return []ExpressRouteCircuitSkuTier{ExpressRouteCircuitSkuTierPremium, ExpressRouteCircuitSkuTierStandard}
|
||||
}
|
||||
|
||||
// IPAllocationMethod enumerates the values for ip allocation method.
|
||||
type IPAllocationMethod string
|
||||
|
||||
const (
|
||||
// Dynamic ...
|
||||
Dynamic IPAllocationMethod = "Dynamic"
|
||||
// Static ...
|
||||
Static IPAllocationMethod = "Static"
|
||||
)
|
||||
|
||||
// PossibleIPAllocationMethodValues returns an array of possible values for the IPAllocationMethod const type.
|
||||
func PossibleIPAllocationMethodValues() []IPAllocationMethod {
|
||||
return []IPAllocationMethod{Dynamic, Static}
|
||||
}
|
||||
|
||||
// LoadDistribution enumerates the values for load distribution.
|
||||
type LoadDistribution string
|
||||
|
||||
const (
|
||||
// Default ...
|
||||
Default LoadDistribution = "Default"
|
||||
// SourceIP ...
|
||||
SourceIP LoadDistribution = "SourceIP"
|
||||
// SourceIPProtocol ...
|
||||
SourceIPProtocol LoadDistribution = "SourceIPProtocol"
|
||||
)
|
||||
|
||||
// PossibleLoadDistributionValues returns an array of possible values for the LoadDistribution const type.
|
||||
func PossibleLoadDistributionValues() []LoadDistribution {
|
||||
return []LoadDistribution{Default, SourceIP, SourceIPProtocol}
|
||||
}
|
||||
|
||||
// OperationStatus enumerates the values for operation status.
|
||||
type OperationStatus string
|
||||
|
||||
const (
|
||||
// Failed ...
|
||||
Failed OperationStatus = "Failed"
|
||||
// InProgress ...
|
||||
InProgress OperationStatus = "InProgress"
|
||||
// Succeeded ...
|
||||
Succeeded OperationStatus = "Succeeded"
|
||||
)
|
||||
|
||||
// PossibleOperationStatusValues returns an array of possible values for the OperationStatus const type.
|
||||
func PossibleOperationStatusValues() []OperationStatus {
|
||||
return []OperationStatus{Failed, InProgress, Succeeded}
|
||||
}
|
||||
|
||||
// ProbeProtocol enumerates the values for probe protocol.
|
||||
type ProbeProtocol string
|
||||
|
||||
const (
|
||||
// ProbeProtocolHTTP ...
|
||||
ProbeProtocolHTTP ProbeProtocol = "Http"
|
||||
// ProbeProtocolTCP ...
|
||||
ProbeProtocolTCP ProbeProtocol = "Tcp"
|
||||
)
|
||||
|
||||
// PossibleProbeProtocolValues returns an array of possible values for the ProbeProtocol const type.
|
||||
func PossibleProbeProtocolValues() []ProbeProtocol {
|
||||
return []ProbeProtocol{ProbeProtocolHTTP, ProbeProtocolTCP}
|
||||
}
|
||||
|
||||
// ProcessorArchitecture enumerates the values for processor architecture.
|
||||
type ProcessorArchitecture string
|
||||
|
||||
const (
|
||||
// Amd64 ...
|
||||
Amd64 ProcessorArchitecture = "Amd64"
|
||||
// X86 ...
|
||||
X86 ProcessorArchitecture = "X86"
|
||||
)
|
||||
|
||||
// PossibleProcessorArchitectureValues returns an array of possible values for the ProcessorArchitecture const type.
|
||||
func PossibleProcessorArchitectureValues() []ProcessorArchitecture {
|
||||
return []ProcessorArchitecture{Amd64, X86}
|
||||
}
|
||||
|
||||
// RouteNextHopType enumerates the values for route next hop type.
|
||||
type RouteNextHopType string
|
||||
|
||||
const (
|
||||
// RouteNextHopTypeInternet ...
|
||||
RouteNextHopTypeInternet RouteNextHopType = "Internet"
|
||||
// RouteNextHopTypeNone ...
|
||||
RouteNextHopTypeNone RouteNextHopType = "None"
|
||||
// RouteNextHopTypeVirtualAppliance ...
|
||||
RouteNextHopTypeVirtualAppliance RouteNextHopType = "VirtualAppliance"
|
||||
// RouteNextHopTypeVirtualNetworkGateway ...
|
||||
RouteNextHopTypeVirtualNetworkGateway RouteNextHopType = "VirtualNetworkGateway"
|
||||
// RouteNextHopTypeVnetLocal ...
|
||||
RouteNextHopTypeVnetLocal RouteNextHopType = "VnetLocal"
|
||||
)
|
||||
|
||||
// PossibleRouteNextHopTypeValues returns an array of possible values for the RouteNextHopType const type.
|
||||
func PossibleRouteNextHopTypeValues() []RouteNextHopType {
|
||||
return []RouteNextHopType{RouteNextHopTypeInternet, RouteNextHopTypeNone, RouteNextHopTypeVirtualAppliance, RouteNextHopTypeVirtualNetworkGateway, RouteNextHopTypeVnetLocal}
|
||||
}
|
||||
|
||||
// SecurityRuleAccess enumerates the values for security rule access.
|
||||
type SecurityRuleAccess string
|
||||
|
||||
const (
|
||||
// Allow ...
|
||||
Allow SecurityRuleAccess = "Allow"
|
||||
// Deny ...
|
||||
Deny SecurityRuleAccess = "Deny"
|
||||
)
|
||||
|
||||
// PossibleSecurityRuleAccessValues returns an array of possible values for the SecurityRuleAccess const type.
|
||||
func PossibleSecurityRuleAccessValues() []SecurityRuleAccess {
|
||||
return []SecurityRuleAccess{Allow, Deny}
|
||||
}
|
||||
|
||||
// SecurityRuleDirection enumerates the values for security rule direction.
|
||||
type SecurityRuleDirection string
|
||||
|
||||
const (
|
||||
// Inbound ...
|
||||
Inbound SecurityRuleDirection = "Inbound"
|
||||
// Outbound ...
|
||||
Outbound SecurityRuleDirection = "Outbound"
|
||||
)
|
||||
|
||||
// PossibleSecurityRuleDirectionValues returns an array of possible values for the SecurityRuleDirection const type.
|
||||
func PossibleSecurityRuleDirectionValues() []SecurityRuleDirection {
|
||||
return []SecurityRuleDirection{Inbound, Outbound}
|
||||
}
|
||||
|
||||
// SecurityRuleProtocol enumerates the values for security rule protocol.
|
||||
type SecurityRuleProtocol string
|
||||
|
||||
const (
|
||||
// Asterisk ...
|
||||
Asterisk SecurityRuleProtocol = "*"
|
||||
// TCP ...
|
||||
TCP SecurityRuleProtocol = "Tcp"
|
||||
// UDP ...
|
||||
UDP SecurityRuleProtocol = "Udp"
|
||||
)
|
||||
|
||||
// PossibleSecurityRuleProtocolValues returns an array of possible values for the SecurityRuleProtocol const type.
|
||||
func PossibleSecurityRuleProtocolValues() []SecurityRuleProtocol {
|
||||
return []SecurityRuleProtocol{Asterisk, TCP, UDP}
|
||||
}
|
||||
|
||||
// ServiceProviderProvisioningState enumerates the values for service provider provisioning state.
|
||||
type ServiceProviderProvisioningState string
|
||||
|
||||
const (
|
||||
// Deprovisioning ...
|
||||
Deprovisioning ServiceProviderProvisioningState = "Deprovisioning"
|
||||
// NotProvisioned ...
|
||||
NotProvisioned ServiceProviderProvisioningState = "NotProvisioned"
|
||||
// Provisioned ...
|
||||
Provisioned ServiceProviderProvisioningState = "Provisioned"
|
||||
// Provisioning ...
|
||||
Provisioning ServiceProviderProvisioningState = "Provisioning"
|
||||
)
|
||||
|
||||
// PossibleServiceProviderProvisioningStateValues returns an array of possible values for the ServiceProviderProvisioningState const type.
|
||||
func PossibleServiceProviderProvisioningStateValues() []ServiceProviderProvisioningState {
|
||||
return []ServiceProviderProvisioningState{Deprovisioning, NotProvisioned, Provisioned, Provisioning}
|
||||
}
|
||||
|
||||
// TransportProtocol enumerates the values for transport protocol.
|
||||
type TransportProtocol string
|
||||
|
||||
const (
|
||||
// TransportProtocolTCP ...
|
||||
TransportProtocolTCP TransportProtocol = "Tcp"
|
||||
// TransportProtocolUDP ...
|
||||
TransportProtocolUDP TransportProtocol = "Udp"
|
||||
)
|
||||
|
||||
// PossibleTransportProtocolValues returns an array of possible values for the TransportProtocol const type.
|
||||
func PossibleTransportProtocolValues() []TransportProtocol {
|
||||
return []TransportProtocol{TransportProtocolTCP, TransportProtocolUDP}
|
||||
}
|
||||
|
||||
// VirtualNetworkGatewayConnectionStatus enumerates the values for virtual network gateway connection status.
|
||||
type VirtualNetworkGatewayConnectionStatus string
|
||||
|
||||
const (
|
||||
// Connected ...
|
||||
Connected VirtualNetworkGatewayConnectionStatus = "Connected"
|
||||
// Connecting ...
|
||||
Connecting VirtualNetworkGatewayConnectionStatus = "Connecting"
|
||||
// NotConnected ...
|
||||
NotConnected VirtualNetworkGatewayConnectionStatus = "NotConnected"
|
||||
// Unknown ...
|
||||
Unknown VirtualNetworkGatewayConnectionStatus = "Unknown"
|
||||
)
|
||||
|
||||
// PossibleVirtualNetworkGatewayConnectionStatusValues returns an array of possible values for the VirtualNetworkGatewayConnectionStatus const type.
|
||||
func PossibleVirtualNetworkGatewayConnectionStatusValues() []VirtualNetworkGatewayConnectionStatus {
|
||||
return []VirtualNetworkGatewayConnectionStatus{Connected, Connecting, NotConnected, Unknown}
|
||||
}
|
||||
|
||||
// VirtualNetworkGatewayConnectionType enumerates the values for virtual network gateway connection type.
|
||||
type VirtualNetworkGatewayConnectionType string
|
||||
|
||||
const (
|
||||
// ExpressRoute ...
|
||||
ExpressRoute VirtualNetworkGatewayConnectionType = "ExpressRoute"
|
||||
// IPsec ...
|
||||
IPsec VirtualNetworkGatewayConnectionType = "IPsec"
|
||||
// Vnet2Vnet ...
|
||||
Vnet2Vnet VirtualNetworkGatewayConnectionType = "Vnet2Vnet"
|
||||
// VPNClient ...
|
||||
VPNClient VirtualNetworkGatewayConnectionType = "VPNClient"
|
||||
)
|
||||
|
||||
// PossibleVirtualNetworkGatewayConnectionTypeValues returns an array of possible values for the VirtualNetworkGatewayConnectionType const type.
|
||||
func PossibleVirtualNetworkGatewayConnectionTypeValues() []VirtualNetworkGatewayConnectionType {
|
||||
return []VirtualNetworkGatewayConnectionType{ExpressRoute, IPsec, Vnet2Vnet, VPNClient}
|
||||
}
|
||||
|
||||
// VirtualNetworkGatewaySkuName enumerates the values for virtual network gateway sku name.
|
||||
type VirtualNetworkGatewaySkuName string
|
||||
|
||||
const (
|
||||
// VirtualNetworkGatewaySkuNameBasic ...
|
||||
VirtualNetworkGatewaySkuNameBasic VirtualNetworkGatewaySkuName = "Basic"
|
||||
// VirtualNetworkGatewaySkuNameHighPerformance ...
|
||||
VirtualNetworkGatewaySkuNameHighPerformance VirtualNetworkGatewaySkuName = "HighPerformance"
|
||||
// VirtualNetworkGatewaySkuNameStandard ...
|
||||
VirtualNetworkGatewaySkuNameStandard VirtualNetworkGatewaySkuName = "Standard"
|
||||
)
|
||||
|
||||
// PossibleVirtualNetworkGatewaySkuNameValues returns an array of possible values for the VirtualNetworkGatewaySkuName const type.
|
||||
func PossibleVirtualNetworkGatewaySkuNameValues() []VirtualNetworkGatewaySkuName {
|
||||
return []VirtualNetworkGatewaySkuName{VirtualNetworkGatewaySkuNameBasic, VirtualNetworkGatewaySkuNameHighPerformance, VirtualNetworkGatewaySkuNameStandard}
|
||||
}
|
||||
|
||||
// VirtualNetworkGatewaySkuTier enumerates the values for virtual network gateway sku tier.
|
||||
type VirtualNetworkGatewaySkuTier string
|
||||
|
||||
const (
|
||||
// VirtualNetworkGatewaySkuTierBasic ...
|
||||
VirtualNetworkGatewaySkuTierBasic VirtualNetworkGatewaySkuTier = "Basic"
|
||||
// VirtualNetworkGatewaySkuTierHighPerformance ...
|
||||
VirtualNetworkGatewaySkuTierHighPerformance VirtualNetworkGatewaySkuTier = "HighPerformance"
|
||||
// VirtualNetworkGatewaySkuTierStandard ...
|
||||
VirtualNetworkGatewaySkuTierStandard VirtualNetworkGatewaySkuTier = "Standard"
|
||||
)
|
||||
|
||||
// PossibleVirtualNetworkGatewaySkuTierValues returns an array of possible values for the VirtualNetworkGatewaySkuTier const type.
|
||||
func PossibleVirtualNetworkGatewaySkuTierValues() []VirtualNetworkGatewaySkuTier {
|
||||
return []VirtualNetworkGatewaySkuTier{VirtualNetworkGatewaySkuTierBasic, VirtualNetworkGatewaySkuTierHighPerformance, VirtualNetworkGatewaySkuTierStandard}
|
||||
}
|
||||
|
||||
// VirtualNetworkGatewayType enumerates the values for virtual network gateway type.
|
||||
type VirtualNetworkGatewayType string
|
||||
|
||||
const (
|
||||
// VirtualNetworkGatewayTypeExpressRoute ...
|
||||
VirtualNetworkGatewayTypeExpressRoute VirtualNetworkGatewayType = "ExpressRoute"
|
||||
// VirtualNetworkGatewayTypeVpn ...
|
||||
VirtualNetworkGatewayTypeVpn VirtualNetworkGatewayType = "Vpn"
|
||||
)
|
||||
|
||||
// PossibleVirtualNetworkGatewayTypeValues returns an array of possible values for the VirtualNetworkGatewayType const type.
|
||||
func PossibleVirtualNetworkGatewayTypeValues() []VirtualNetworkGatewayType {
|
||||
return []VirtualNetworkGatewayType{VirtualNetworkGatewayTypeExpressRoute, VirtualNetworkGatewayTypeVpn}
|
||||
}
|
||||
|
||||
// VpnType enumerates the values for vpn type.
|
||||
type VpnType string
|
||||
|
||||
const (
|
||||
// PolicyBased ...
|
||||
PolicyBased VpnType = "PolicyBased"
|
||||
// RouteBased ...
|
||||
RouteBased VpnType = "RouteBased"
|
||||
)
|
||||
|
||||
// PossibleVpnTypeValues returns an array of possible values for the VpnType const type.
|
||||
func PossibleVpnTypeValues() []VpnType {
|
||||
return []VpnType{PolicyBased, RouteBased}
|
||||
}
|
||||
|
|
@ -69,7 +69,7 @@ func (client ExpressRouteCircuitAuthorizationsClient) CreateOrUpdate(ctx context
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -108,7 +108,29 @@ func (client ExpressRouteCircuitAuthorizationsClient) CreateOrUpdateSender(req *
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ExpressRouteCircuitAuthorizationsClient) (erca ExpressRouteCircuitAuthorization, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if erca.Response.Response, err = future.GetResult(sender); err == nil && erca.Response.Response.StatusCode != http.StatusNoContent {
|
||||
erca, err = client.CreateOrUpdateResponder(erca.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsCreateOrUpdateFuture", "Result", erca.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -148,7 +170,7 @@ func (client ExpressRouteCircuitAuthorizationsClient) Delete(ctx context.Context
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -185,7 +207,23 @@ func (client ExpressRouteCircuitAuthorizationsClient) DeleteSender(req *http.Req
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ExpressRouteCircuitAuthorizationsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitAuthorizationsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -232,6 +270,7 @@ func (client ExpressRouteCircuitAuthorizationsClient) Get(ctx context.Context, r
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -309,6 +348,11 @@ func (client ExpressRouteCircuitAuthorizationsClient) List(ctx context.Context,
|
|||
result.alr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitAuthorizationsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.alr.hasNextLink() && result.alr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ func (client ExpressRouteCircuitPeeringsClient) CreateOrUpdate(ctx context.Conte
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -106,7 +106,29 @@ func (client ExpressRouteCircuitPeeringsClient) CreateOrUpdateSender(req *http.R
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ExpressRouteCircuitPeeringsClient) (ercp ExpressRouteCircuitPeering, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitPeeringsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if ercp.Response.Response, err = future.GetResult(sender); err == nil && ercp.Response.Response.StatusCode != http.StatusNoContent {
|
||||
ercp, err = client.CreateOrUpdateResponder(ercp.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsCreateOrUpdateFuture", "Result", ercp.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -146,7 +168,7 @@ func (client ExpressRouteCircuitPeeringsClient) Delete(ctx context.Context, reso
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -183,7 +205,23 @@ func (client ExpressRouteCircuitPeeringsClient) DeleteSender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ExpressRouteCircuitPeeringsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitPeeringsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -230,6 +268,7 @@ func (client ExpressRouteCircuitPeeringsClient) Get(ctx context.Context, resourc
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -307,6 +346,11 @@ func (client ExpressRouteCircuitPeeringsClient) List(ctx context.Context, resour
|
|||
result.ercplr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitPeeringsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ercplr.hasNextLink() && result.ercplr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ func (client ExpressRouteCircuitsClient) CreateOrUpdate(ctx context.Context, res
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -104,7 +104,29 @@ func (client ExpressRouteCircuitsClient) CreateOrUpdateSender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ExpressRouteCircuitsClient) (erc ExpressRouteCircuit, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if erc.Response.Response, err = future.GetResult(sender); err == nil && erc.Response.Response.StatusCode != http.StatusNoContent {
|
||||
erc, err = client.CreateOrUpdateResponder(erc.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsCreateOrUpdateFuture", "Result", erc.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -143,7 +165,7 @@ func (client ExpressRouteCircuitsClient) Delete(ctx context.Context, resourceGro
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -179,7 +201,23 @@ func (client ExpressRouteCircuitsClient) DeleteSender(req *http.Request) (future
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client ExpressRouteCircuitsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.ExpressRouteCircuitsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client ExpressRouteCircuitsClient) Get(ctx context.Context, resourceGroupN
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -300,6 +339,11 @@ func (client ExpressRouteCircuitsClient) List(ctx context.Context, resourceGroup
|
|||
result.erclr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.erclr.hasNextLink() && result.erclr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -409,6 +453,11 @@ func (client ExpressRouteCircuitsClient) ListAll(ctx context.Context) (result Ex
|
|||
result.erclr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsClient", "ListAll", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.erclr.hasNextLink() && result.erclr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -521,6 +570,11 @@ func (client ExpressRouteCircuitsClient) ListArpTable(ctx context.Context, resou
|
|||
result.ercatlr, err = client.ListArpTableResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsClient", "ListArpTable", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ercatlr.hasNextLink() && result.ercatlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -635,6 +689,11 @@ func (client ExpressRouteCircuitsClient) ListRoutesTable(ctx context.Context, re
|
|||
result.ercrtlr, err = client.ListRoutesTableResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsClient", "ListRoutesTable", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ercrtlr.hasNextLink() && result.ercrtlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -749,6 +808,11 @@ func (client ExpressRouteCircuitsClient) ListStats(ctx context.Context, resource
|
|||
result.ercslr, err = client.ListStatsResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteCircuitsClient", "ListStats", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ercslr.hasNextLink() && result.ercslr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -71,6 +71,11 @@ func (client ExpressRouteServiceProvidersClient) List(ctx context.Context) (resu
|
|||
result.ersplr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.ExpressRouteServiceProvidersClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ersplr.hasNextLink() && result.ersplr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ func (client InterfacesClient) CreateOrUpdate(ctx context.Context, resourceGroup
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -103,7 +103,29 @@ func (client InterfacesClient) CreateOrUpdateSender(req *http.Request) (future I
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client InterfacesClient) (i Interface, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.InterfacesCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if i.Response.Response, err = future.GetResult(sender); err == nil && i.Response.Response.StatusCode != http.StatusNoContent {
|
||||
i, err = client.CreateOrUpdateResponder(i.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesCreateOrUpdateFuture", "Result", i.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -142,7 +164,7 @@ func (client InterfacesClient) Delete(ctx context.Context, resourceGroupName str
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -178,7 +200,23 @@ func (client InterfacesClient) DeleteSender(req *http.Request) (future Interface
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client InterfacesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.InterfacesDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client InterfacesClient) Get(ctx context.Context, resourceGroupName string
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -306,6 +345,7 @@ func (client InterfacesClient) GetVirtualMachineScaleSetNetworkInterface(ctx con
|
|||
result, err = client.GetVirtualMachineScaleSetNetworkInterfaceResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesClient", "GetVirtualMachineScaleSetNetworkInterface", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -386,6 +426,11 @@ func (client InterfacesClient) List(ctx context.Context, resourceGroupName strin
|
|||
result.ilr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ilr.hasNextLink() && result.ilr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -495,6 +540,11 @@ func (client InterfacesClient) ListAll(ctx context.Context) (result InterfaceLis
|
|||
result.ilr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesClient", "ListAll", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ilr.hasNextLink() && result.ilr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -606,6 +656,11 @@ func (client InterfacesClient) ListVirtualMachineScaleSetNetworkInterfaces(ctx c
|
|||
result.ilr, err = client.ListVirtualMachineScaleSetNetworkInterfacesResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesClient", "ListVirtualMachineScaleSetNetworkInterfaces", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ilr.hasNextLink() && result.ilr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -721,6 +776,11 @@ func (client InterfacesClient) ListVirtualMachineScaleSetVMNetworkInterfaces(ctx
|
|||
result.ilr, err = client.ListVirtualMachineScaleSetVMNetworkInterfacesResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.InterfacesClient", "ListVirtualMachineScaleSetVMNetworkInterfaces", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ilr.hasNextLink() && result.ilr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ func (client LoadBalancersClient) CreateOrUpdate(ctx context.Context, resourceGr
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LoadBalancersClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.LoadBalancersClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -103,7 +103,29 @@ func (client LoadBalancersClient) CreateOrUpdateSender(req *http.Request) (futur
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client LoadBalancersClient) (lb LoadBalancer, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LoadBalancersCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.LoadBalancersCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if lb.Response.Response, err = future.GetResult(sender); err == nil && lb.Response.Response.StatusCode != http.StatusNoContent {
|
||||
lb, err = client.CreateOrUpdateResponder(lb.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LoadBalancersCreateOrUpdateFuture", "Result", lb.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -142,7 +164,7 @@ func (client LoadBalancersClient) Delete(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LoadBalancersClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.LoadBalancersClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -178,7 +200,23 @@ func (client LoadBalancersClient) DeleteSender(req *http.Request) (future LoadBa
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client LoadBalancersClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LoadBalancersDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.LoadBalancersDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client LoadBalancersClient) Get(ctx context.Context, resourceGroupName str
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LoadBalancersClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -303,6 +342,11 @@ func (client LoadBalancersClient) List(ctx context.Context, resourceGroupName st
|
|||
result.lblr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LoadBalancersClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.lblr.hasNextLink() && result.lblr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -412,6 +456,11 @@ func (client LoadBalancersClient) ListAll(ctx context.Context) (result LoadBalan
|
|||
result.lblr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LoadBalancersClient", "ListAll", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.lblr.hasNextLink() && result.lblr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ func (client LocalNetworkGatewaysClient) CreateOrUpdate(ctx context.Context, res
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -104,7 +104,29 @@ func (client LocalNetworkGatewaysClient) CreateOrUpdateSender(req *http.Request)
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client LocalNetworkGatewaysClient) (lng LocalNetworkGateway, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.LocalNetworkGatewaysCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if lng.Response.Response, err = future.GetResult(sender); err == nil && lng.Response.Response.StatusCode != http.StatusNoContent {
|
||||
lng, err = client.CreateOrUpdateResponder(lng.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysCreateOrUpdateFuture", "Result", lng.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -143,7 +165,7 @@ func (client LocalNetworkGatewaysClient) Delete(ctx context.Context, resourceGro
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -179,7 +201,23 @@ func (client LocalNetworkGatewaysClient) DeleteSender(req *http.Request) (future
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client LocalNetworkGatewaysClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.LocalNetworkGatewaysDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client LocalNetworkGatewaysClient) Get(ctx context.Context, resourceGroupN
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -300,6 +339,11 @@ func (client LocalNetworkGatewaysClient) List(ctx context.Context, resourceGroup
|
|||
result.lnglr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.LocalNetworkGatewaysClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.lnglr.hasNextLink() && result.lnglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
2058
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2015-06-15/network/models.go
generated
vendored
2058
vendor/github.com/Azure/azure-sdk-for-go/services/network/mgmt/2015-06-15/network/models.go
generated
vendored
File diff suppressed because it is too large
Load diff
|
|
@ -78,7 +78,7 @@ func (client PublicIPAddressesClient) CreateOrUpdate(ctx context.Context, resour
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PublicIPAddressesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.PublicIPAddressesClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -116,7 +116,29 @@ func (client PublicIPAddressesClient) CreateOrUpdateSender(req *http.Request) (f
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client PublicIPAddressesClient) (pia PublicIPAddress, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PublicIPAddressesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.PublicIPAddressesCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if pia.Response.Response, err = future.GetResult(sender); err == nil && pia.Response.Response.StatusCode != http.StatusNoContent {
|
||||
pia, err = client.CreateOrUpdateResponder(pia.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PublicIPAddressesCreateOrUpdateFuture", "Result", pia.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -155,7 +177,7 @@ func (client PublicIPAddressesClient) Delete(ctx context.Context, resourceGroupN
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PublicIPAddressesClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.PublicIPAddressesClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -191,7 +213,23 @@ func (client PublicIPAddressesClient) DeleteSender(req *http.Request) (future Pu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client PublicIPAddressesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PublicIPAddressesDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.PublicIPAddressesDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -238,6 +276,7 @@ func (client PublicIPAddressesClient) Get(ctx context.Context, resourceGroupName
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PublicIPAddressesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -316,6 +355,11 @@ func (client PublicIPAddressesClient) List(ctx context.Context, resourceGroupNam
|
|||
result.pialr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PublicIPAddressesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.pialr.hasNextLink() && result.pialr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -425,6 +469,11 @@ func (client PublicIPAddressesClient) ListAll(ctx context.Context) (result Publi
|
|||
result.pialr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.PublicIPAddressesClient", "ListAll", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.pialr.hasNextLink() && result.pialr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ func (client RoutesClient) CreateOrUpdate(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RoutesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.RoutesClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -105,7 +105,29 @@ func (client RoutesClient) CreateOrUpdateSender(req *http.Request) (future Route
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client RoutesClient) (r Route, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RoutesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.RoutesCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if r.Response.Response, err = future.GetResult(sender); err == nil && r.Response.Response.StatusCode != http.StatusNoContent {
|
||||
r, err = client.CreateOrUpdateResponder(r.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RoutesCreateOrUpdateFuture", "Result", r.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -145,7 +167,7 @@ func (client RoutesClient) Delete(ctx context.Context, resourceGroupName string,
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RoutesClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.RoutesClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -182,7 +204,23 @@ func (client RoutesClient) DeleteSender(req *http.Request) (future RoutesDeleteF
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client RoutesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RoutesDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.RoutesDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -229,6 +267,7 @@ func (client RoutesClient) Get(ctx context.Context, resourceGroupName string, ro
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RoutesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -306,6 +345,11 @@ func (client RoutesClient) List(ctx context.Context, resourceGroupName string, r
|
|||
result.rlr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RoutesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.rlr.hasNextLink() && result.rlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ func (client RouteTablesClient) CreateOrUpdate(ctx context.Context, resourceGrou
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RouteTablesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.RouteTablesClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -103,7 +103,29 @@ func (client RouteTablesClient) CreateOrUpdateSender(req *http.Request) (future
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client RouteTablesClient) (rt RouteTable, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RouteTablesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.RouteTablesCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if rt.Response.Response, err = future.GetResult(sender); err == nil && rt.Response.Response.StatusCode != http.StatusNoContent {
|
||||
rt, err = client.CreateOrUpdateResponder(rt.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RouteTablesCreateOrUpdateFuture", "Result", rt.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -142,7 +164,7 @@ func (client RouteTablesClient) Delete(ctx context.Context, resourceGroupName st
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RouteTablesClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.RouteTablesClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -178,7 +200,23 @@ func (client RouteTablesClient) DeleteSender(req *http.Request) (future RouteTab
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client RouteTablesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RouteTablesDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.RouteTablesDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client RouteTablesClient) Get(ctx context.Context, resourceGroupName strin
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RouteTablesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -303,6 +342,11 @@ func (client RouteTablesClient) List(ctx context.Context, resourceGroupName stri
|
|||
result.rtlr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RouteTablesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.rtlr.hasNextLink() && result.rtlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -412,6 +456,11 @@ func (client RouteTablesClient) ListAll(ctx context.Context) (result RouteTableL
|
|||
result.rtlr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.RouteTablesClient", "ListAll", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.rtlr.hasNextLink() && result.rtlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ func (client SecurityGroupsClient) CreateOrUpdate(ctx context.Context, resourceG
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityGroupsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityGroupsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -103,7 +103,29 @@ func (client SecurityGroupsClient) CreateOrUpdateSender(req *http.Request) (futu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SecurityGroupsClient) (sg SecurityGroup, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityGroupsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.SecurityGroupsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if sg.Response.Response, err = future.GetResult(sender); err == nil && sg.Response.Response.StatusCode != http.StatusNoContent {
|
||||
sg, err = client.CreateOrUpdateResponder(sg.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityGroupsCreateOrUpdateFuture", "Result", sg.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -142,7 +164,7 @@ func (client SecurityGroupsClient) Delete(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityGroupsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityGroupsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -178,7 +200,23 @@ func (client SecurityGroupsClient) DeleteSender(req *http.Request) (future Secur
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SecurityGroupsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityGroupsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.SecurityGroupsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client SecurityGroupsClient) Get(ctx context.Context, resourceGroupName st
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityGroupsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -303,6 +342,11 @@ func (client SecurityGroupsClient) List(ctx context.Context, resourceGroupName s
|
|||
result.sglr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityGroupsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.sglr.hasNextLink() && result.sglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -412,6 +456,11 @@ func (client SecurityGroupsClient) ListAll(ctx context.Context) (result Security
|
|||
result.sglr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityGroupsClient", "ListAll", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.sglr.hasNextLink() && result.sglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -76,7 +76,7 @@ func (client SecurityRulesClient) CreateOrUpdate(ctx context.Context, resourceGr
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityRulesClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityRulesClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -115,7 +115,29 @@ func (client SecurityRulesClient) CreateOrUpdateSender(req *http.Request) (futur
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SecurityRulesClient) (sr SecurityRule, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityRulesCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.SecurityRulesCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if sr.Response.Response, err = future.GetResult(sender); err == nil && sr.Response.Response.StatusCode != http.StatusNoContent {
|
||||
sr, err = client.CreateOrUpdateResponder(sr.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityRulesCreateOrUpdateFuture", "Result", sr.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -155,7 +177,7 @@ func (client SecurityRulesClient) Delete(ctx context.Context, resourceGroupName
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityRulesClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityRulesClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -192,7 +214,23 @@ func (client SecurityRulesClient) DeleteSender(req *http.Request) (future Securi
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SecurityRulesClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityRulesDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.SecurityRulesDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -239,6 +277,7 @@ func (client SecurityRulesClient) Get(ctx context.Context, resourceGroupName str
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityRulesClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -316,6 +355,11 @@ func (client SecurityRulesClient) List(ctx context.Context, resourceGroupName st
|
|||
result.srlr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SecurityRulesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.srlr.hasNextLink() && result.srlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ func (client SubnetsClient) CreateOrUpdate(ctx context.Context, resourceGroupNam
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SubnetsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.SubnetsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -105,7 +105,29 @@ func (client SubnetsClient) CreateOrUpdateSender(req *http.Request) (future Subn
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SubnetsClient) (s Subnet, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SubnetsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.SubnetsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if s.Response.Response, err = future.GetResult(sender); err == nil && s.Response.Response.StatusCode != http.StatusNoContent {
|
||||
s, err = client.CreateOrUpdateResponder(s.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SubnetsCreateOrUpdateFuture", "Result", s.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -145,7 +167,7 @@ func (client SubnetsClient) Delete(ctx context.Context, resourceGroupName string
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SubnetsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.SubnetsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -182,7 +204,23 @@ func (client SubnetsClient) DeleteSender(req *http.Request) (future SubnetsDelet
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client SubnetsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SubnetsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.SubnetsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -230,6 +268,7 @@ func (client SubnetsClient) Get(ctx context.Context, resourceGroupName string, v
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SubnetsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -310,6 +349,11 @@ func (client SubnetsClient) List(ctx context.Context, resourceGroupName string,
|
|||
result.slr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.SubnetsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.slr.hasNextLink() && result.slr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -79,6 +79,11 @@ func (client UsagesClient) List(ctx context.Context, location string) (result Us
|
|||
result.ulr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.UsagesClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ulr.hasNextLink() && result.ulr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ func (client VirtualNetworkGatewayConnectionsClient) CreateOrUpdate(ctx context.
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -104,7 +104,29 @@ func (client VirtualNetworkGatewayConnectionsClient) CreateOrUpdateSender(req *h
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualNetworkGatewayConnectionsClient) (vngc VirtualNetworkGatewayConnection, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewayConnectionsCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vngc.Response.Response, err = future.GetResult(sender); err == nil && vngc.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vngc, err = client.CreateOrUpdateResponder(vngc.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsCreateOrUpdateFuture", "Result", vngc.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -143,7 +165,7 @@ func (client VirtualNetworkGatewayConnectionsClient) Delete(ctx context.Context,
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -179,7 +201,23 @@ func (client VirtualNetworkGatewayConnectionsClient) DeleteSender(req *http.Requ
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualNetworkGatewayConnectionsClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewayConnectionsDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client VirtualNetworkGatewayConnectionsClient) Get(ctx context.Context, re
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -301,6 +340,7 @@ func (client VirtualNetworkGatewayConnectionsClient) GetSharedKey(ctx context.Co
|
|||
result, err = client.GetSharedKeyResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "GetSharedKey", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -377,6 +417,11 @@ func (client VirtualNetworkGatewayConnectionsClient) List(ctx context.Context, r
|
|||
result.vngclr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vngclr.hasNextLink() && result.vngclr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -484,7 +529,7 @@ func (client VirtualNetworkGatewayConnectionsClient) ResetSharedKey(ctx context.
|
|||
|
||||
result, err = client.ResetSharedKeySender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "ResetSharedKey", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "ResetSharedKey", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -522,7 +567,29 @@ func (client VirtualNetworkGatewayConnectionsClient) ResetSharedKeySender(req *h
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualNetworkGatewayConnectionsClient) (crsk ConnectionResetSharedKey, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsResetSharedKeyFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewayConnectionsResetSharedKeyFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if crsk.Response.Response, err = future.GetResult(sender); err == nil && crsk.Response.Response.StatusCode != http.StatusNoContent {
|
||||
crsk, err = client.ResetSharedKeyResponder(crsk.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsResetSharedKeyFuture", "Result", crsk.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -565,7 +632,7 @@ func (client VirtualNetworkGatewayConnectionsClient) SetSharedKey(ctx context.Co
|
|||
|
||||
result, err = client.SetSharedKeySender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "SetSharedKey", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsClient", "SetSharedKey", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -603,7 +670,29 @@ func (client VirtualNetworkGatewayConnectionsClient) SetSharedKeySender(req *htt
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualNetworkGatewayConnectionsClient) (csk ConnectionSharedKey, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsSetSharedKeyFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewayConnectionsSetSharedKeyFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if csk.Response.Response, err = future.GetResult(sender); err == nil && csk.Response.Response.StatusCode != http.StatusNoContent {
|
||||
csk, err = client.SetSharedKeyResponder(csk.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewayConnectionsSetSharedKeyFuture", "Result", csk.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ func (client VirtualNetworkGatewaysClient) CreateOrUpdate(ctx context.Context, r
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -104,7 +104,29 @@ func (client VirtualNetworkGatewaysClient) CreateOrUpdateSender(req *http.Reques
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualNetworkGatewaysClient) (vng VirtualNetworkGateway, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vng.Response.Response, err = future.GetResult(sender); err == nil && vng.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vng, err = client.CreateOrUpdateResponder(vng.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysCreateOrUpdateFuture", "Result", vng.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -143,7 +165,7 @@ func (client VirtualNetworkGatewaysClient) Delete(ctx context.Context, resourceG
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -179,7 +201,23 @@ func (client VirtualNetworkGatewaysClient) DeleteSender(req *http.Request) (futu
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualNetworkGatewaysClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -219,7 +257,7 @@ func (client VirtualNetworkGatewaysClient) Generatevpnclientpackage(ctx context.
|
|||
|
||||
result, err = client.GeneratevpnclientpackageSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysClient", "Generatevpnclientpackage", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysClient", "Generatevpnclientpackage", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -257,7 +295,29 @@ func (client VirtualNetworkGatewaysClient) GeneratevpnclientpackageSender(req *h
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualNetworkGatewaysClient) (s String, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGeneratevpnclientpackageFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysGeneratevpnclientpackageFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if s.Response.Response, err = future.GetResult(sender); err == nil && s.Response.Response.StatusCode != http.StatusNoContent {
|
||||
s, err = client.GeneratevpnclientpackageResponder(s.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysGeneratevpnclientpackageFuture", "Result", s.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -304,6 +364,7 @@ func (client VirtualNetworkGatewaysClient) Get(ctx context.Context, resourceGrou
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -379,6 +440,11 @@ func (client VirtualNetworkGatewaysClient) List(ctx context.Context, resourceGro
|
|||
result.vnglr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vnglr.hasNextLink() && result.vnglr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -484,7 +550,7 @@ func (client VirtualNetworkGatewaysClient) Reset(ctx context.Context, resourceGr
|
|||
|
||||
result, err = client.ResetSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysClient", "Reset", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysClient", "Reset", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -522,7 +588,29 @@ func (client VirtualNetworkGatewaysClient) ResetSender(req *http.Request) (futur
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualNetworkGatewaysClient) (vng VirtualNetworkGateway, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysResetFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.VirtualNetworkGatewaysResetFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vng.Response.Response, err = future.GetResult(sender); err == nil && vng.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vng, err = client.ResetResponder(vng.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworkGatewaysResetFuture", "Result", vng.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ func (client VirtualNetworksClient) CreateOrUpdate(ctx context.Context, resource
|
|||
|
||||
result, err = client.CreateOrUpdateSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworksClient", "CreateOrUpdate", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworksClient", "CreateOrUpdate", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -103,7 +103,29 @@ func (client VirtualNetworksClient) CreateOrUpdateSender(req *http.Request) (fut
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualNetworksClient) (vn VirtualNetwork, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworksCreateOrUpdateFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.VirtualNetworksCreateOrUpdateFuture")
|
||||
return
|
||||
}
|
||||
sender := autorest.DecorateSender(client, autorest.DoRetryForStatusCodes(client.RetryAttempts, client.RetryDuration, autorest.StatusCodesForRetry...))
|
||||
if vn.Response.Response, err = future.GetResult(sender); err == nil && vn.Response.Response.StatusCode != http.StatusNoContent {
|
||||
vn, err = client.CreateOrUpdateResponder(vn.Response.Response)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworksCreateOrUpdateFuture", "Result", vn.Response.Response, "Failure responding to request")
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -142,7 +164,7 @@ func (client VirtualNetworksClient) Delete(ctx context.Context, resourceGroupNam
|
|||
|
||||
result, err = client.DeleteSender(req)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworksClient", "Delete", result.Response(), "Failure sending request")
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworksClient", "Delete", nil, "Failure sending request")
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -178,7 +200,23 @@ func (client VirtualNetworksClient) DeleteSender(req *http.Request) (future Virt
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
future.Future, err = azure.NewFutureFromResponse(resp)
|
||||
var azf azure.Future
|
||||
azf, err = azure.NewFutureFromResponse(resp)
|
||||
future.FutureAPI = &azf
|
||||
future.Result = func(client VirtualNetworksClient) (ar autorest.Response, err error) {
|
||||
var done bool
|
||||
done, err = future.DoneWithContext(context.Background(), client)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworksDeleteFuture", "Result", future.Response(), "Polling failure")
|
||||
return
|
||||
}
|
||||
if !done {
|
||||
err = azure.NewAsyncOpIncompleteError("network.VirtualNetworksDeleteFuture")
|
||||
return
|
||||
}
|
||||
ar.Response = future.Response()
|
||||
return
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
@ -225,6 +263,7 @@ func (client VirtualNetworksClient) Get(ctx context.Context, resourceGroupName s
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworksClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -303,6 +342,11 @@ func (client VirtualNetworksClient) List(ctx context.Context, resourceGroupName
|
|||
result.vnlr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworksClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vnlr.hasNextLink() && result.vnlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -412,6 +456,11 @@ func (client VirtualNetworksClient) ListAll(ctx context.Context) (result Virtual
|
|||
result.vnlr, err = client.ListAllResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "network.VirtualNetworksClient", "ListAll", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.vnlr.hasNextLink() && result.vnlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
5
vendor/github.com/Azure/azure-sdk-for-go/services/preview/authorization/mgmt/2018-01-01-preview/authorization/CHANGELOG.md
generated
vendored
Normal file
5
vendor/github.com/Azure/azure-sdk-for-go/services/preview/authorization/mgmt/2018-01-01-preview/authorization/CHANGELOG.md
generated
vendored
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
Generated from https://github.com/Azure/azure-rest-api-specs/tree/3c764635e7d442b3e74caf593029fcd440b3ef82/specification/authorization/resource-manager/readme.md tag: `package-2018-01-01-preview`
|
||||
|
||||
Code generator @microsoft.azure/autorest.go@2.1.168
|
||||
|
||||
No exported changes
|
||||
|
|
@ -71,6 +71,11 @@ func (client ClassicAdministratorsClient) List(ctx context.Context) (result Clas
|
|||
result.calr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.ClassicAdministratorsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.calr.hasNextLink() && result.calr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -70,6 +70,7 @@ func (client GlobalAdministratorClient) ElevateAccess(ctx context.Context) (resu
|
|||
result, err = client.ElevateAccessResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.GlobalAdministratorClient", "ElevateAccess", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -188,10 +188,15 @@ func (calr ClassicAdministratorListResult) IsEmpty() bool {
|
|||
return calr.Value == nil || len(*calr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (calr ClassicAdministratorListResult) hasNextLink() bool {
|
||||
return calr.NextLink != nil && len(*calr.NextLink) != 0
|
||||
}
|
||||
|
||||
// classicAdministratorListResultPreparer prepares a request to retrieve the next set of results.
|
||||
// It returns nil if no more results exist.
|
||||
func (calr ClassicAdministratorListResult) classicAdministratorListResultPreparer(ctx context.Context) (*http.Request, error) {
|
||||
if calr.NextLink == nil || len(to.String(calr.NextLink)) < 1 {
|
||||
if !calr.hasNextLink() {
|
||||
return nil, nil
|
||||
}
|
||||
return autorest.Prepare((&http.Request{}).WithContext(ctx),
|
||||
|
|
@ -219,11 +224,16 @@ func (page *ClassicAdministratorListResultPage) NextWithContext(ctx context.Cont
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.calr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.calr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.calr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.calr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -253,8 +263,11 @@ func (page ClassicAdministratorListResultPage) Values() []ClassicAdministrator {
|
|||
}
|
||||
|
||||
// Creates a new instance of the ClassicAdministratorListResultPage type.
|
||||
func NewClassicAdministratorListResultPage(getNextPage func(context.Context, ClassicAdministratorListResult) (ClassicAdministratorListResult, error)) ClassicAdministratorListResultPage {
|
||||
return ClassicAdministratorListResultPage{fn: getNextPage}
|
||||
func NewClassicAdministratorListResultPage(cur ClassicAdministratorListResult, getNextPage func(context.Context, ClassicAdministratorListResult) (ClassicAdministratorListResult, error)) ClassicAdministratorListResultPage {
|
||||
return ClassicAdministratorListResultPage{
|
||||
fn: getNextPage,
|
||||
calr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// ClassicAdministratorProperties classic Administrator properties.
|
||||
|
|
@ -354,10 +367,15 @@ func (pgr PermissionGetResult) IsEmpty() bool {
|
|||
return pgr.Value == nil || len(*pgr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (pgr PermissionGetResult) hasNextLink() bool {
|
||||
return pgr.NextLink != nil && len(*pgr.NextLink) != 0
|
||||
}
|
||||
|
||||
// permissionGetResultPreparer prepares a request to retrieve the next set of results.
|
||||
// It returns nil if no more results exist.
|
||||
func (pgr PermissionGetResult) permissionGetResultPreparer(ctx context.Context) (*http.Request, error) {
|
||||
if pgr.NextLink == nil || len(to.String(pgr.NextLink)) < 1 {
|
||||
if !pgr.hasNextLink() {
|
||||
return nil, nil
|
||||
}
|
||||
return autorest.Prepare((&http.Request{}).WithContext(ctx),
|
||||
|
|
@ -385,11 +403,16 @@ func (page *PermissionGetResultPage) NextWithContext(ctx context.Context) (err e
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.pgr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.pgr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.pgr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.pgr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -419,8 +442,11 @@ func (page PermissionGetResultPage) Values() []Permission {
|
|||
}
|
||||
|
||||
// Creates a new instance of the PermissionGetResultPage type.
|
||||
func NewPermissionGetResultPage(getNextPage func(context.Context, PermissionGetResult) (PermissionGetResult, error)) PermissionGetResultPage {
|
||||
return PermissionGetResultPage{fn: getNextPage}
|
||||
func NewPermissionGetResultPage(cur PermissionGetResult, getNextPage func(context.Context, PermissionGetResult) (PermissionGetResult, error)) PermissionGetResultPage {
|
||||
return PermissionGetResultPage{
|
||||
fn: getNextPage,
|
||||
pgr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// ProviderOperation operation
|
||||
|
|
@ -534,10 +560,15 @@ func (pomlr ProviderOperationsMetadataListResult) IsEmpty() bool {
|
|||
return pomlr.Value == nil || len(*pomlr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (pomlr ProviderOperationsMetadataListResult) hasNextLink() bool {
|
||||
return pomlr.NextLink != nil && len(*pomlr.NextLink) != 0
|
||||
}
|
||||
|
||||
// providerOperationsMetadataListResultPreparer prepares a request to retrieve the next set of results.
|
||||
// It returns nil if no more results exist.
|
||||
func (pomlr ProviderOperationsMetadataListResult) providerOperationsMetadataListResultPreparer(ctx context.Context) (*http.Request, error) {
|
||||
if pomlr.NextLink == nil || len(to.String(pomlr.NextLink)) < 1 {
|
||||
if !pomlr.hasNextLink() {
|
||||
return nil, nil
|
||||
}
|
||||
return autorest.Prepare((&http.Request{}).WithContext(ctx),
|
||||
|
|
@ -565,11 +596,16 @@ func (page *ProviderOperationsMetadataListResultPage) NextWithContext(ctx contex
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.pomlr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.pomlr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.pomlr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.pomlr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -599,8 +635,11 @@ func (page ProviderOperationsMetadataListResultPage) Values() []ProviderOperatio
|
|||
}
|
||||
|
||||
// Creates a new instance of the ProviderOperationsMetadataListResultPage type.
|
||||
func NewProviderOperationsMetadataListResultPage(getNextPage func(context.Context, ProviderOperationsMetadataListResult) (ProviderOperationsMetadataListResult, error)) ProviderOperationsMetadataListResultPage {
|
||||
return ProviderOperationsMetadataListResultPage{fn: getNextPage}
|
||||
func NewProviderOperationsMetadataListResultPage(cur ProviderOperationsMetadataListResult, getNextPage func(context.Context, ProviderOperationsMetadataListResult) (ProviderOperationsMetadataListResult, error)) ProviderOperationsMetadataListResultPage {
|
||||
return ProviderOperationsMetadataListResultPage{
|
||||
fn: getNextPage,
|
||||
pomlr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// ResourceType resource Type
|
||||
|
|
@ -810,10 +849,15 @@ func (ralr RoleAssignmentListResult) IsEmpty() bool {
|
|||
return ralr.Value == nil || len(*ralr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (ralr RoleAssignmentListResult) hasNextLink() bool {
|
||||
return ralr.NextLink != nil && len(*ralr.NextLink) != 0
|
||||
}
|
||||
|
||||
// roleAssignmentListResultPreparer prepares a request to retrieve the next set of results.
|
||||
// It returns nil if no more results exist.
|
||||
func (ralr RoleAssignmentListResult) roleAssignmentListResultPreparer(ctx context.Context) (*http.Request, error) {
|
||||
if ralr.NextLink == nil || len(to.String(ralr.NextLink)) < 1 {
|
||||
if !ralr.hasNextLink() {
|
||||
return nil, nil
|
||||
}
|
||||
return autorest.Prepare((&http.Request{}).WithContext(ctx),
|
||||
|
|
@ -841,11 +885,16 @@ func (page *RoleAssignmentListResultPage) NextWithContext(ctx context.Context) (
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.ralr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.ralr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.ralr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.ralr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -875,8 +924,11 @@ func (page RoleAssignmentListResultPage) Values() []RoleAssignment {
|
|||
}
|
||||
|
||||
// Creates a new instance of the RoleAssignmentListResultPage type.
|
||||
func NewRoleAssignmentListResultPage(getNextPage func(context.Context, RoleAssignmentListResult) (RoleAssignmentListResult, error)) RoleAssignmentListResultPage {
|
||||
return RoleAssignmentListResultPage{fn: getNextPage}
|
||||
func NewRoleAssignmentListResultPage(cur RoleAssignmentListResult, getNextPage func(context.Context, RoleAssignmentListResult) (RoleAssignmentListResult, error)) RoleAssignmentListResultPage {
|
||||
return RoleAssignmentListResultPage{
|
||||
fn: getNextPage,
|
||||
ralr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// RoleAssignmentProperties role assignment properties.
|
||||
|
|
@ -1059,10 +1111,15 @@ func (rdlr RoleDefinitionListResult) IsEmpty() bool {
|
|||
return rdlr.Value == nil || len(*rdlr.Value) == 0
|
||||
}
|
||||
|
||||
// hasNextLink returns true if the NextLink is not empty.
|
||||
func (rdlr RoleDefinitionListResult) hasNextLink() bool {
|
||||
return rdlr.NextLink != nil && len(*rdlr.NextLink) != 0
|
||||
}
|
||||
|
||||
// roleDefinitionListResultPreparer prepares a request to retrieve the next set of results.
|
||||
// It returns nil if no more results exist.
|
||||
func (rdlr RoleDefinitionListResult) roleDefinitionListResultPreparer(ctx context.Context) (*http.Request, error) {
|
||||
if rdlr.NextLink == nil || len(to.String(rdlr.NextLink)) < 1 {
|
||||
if !rdlr.hasNextLink() {
|
||||
return nil, nil
|
||||
}
|
||||
return autorest.Prepare((&http.Request{}).WithContext(ctx),
|
||||
|
|
@ -1090,11 +1147,16 @@ func (page *RoleDefinitionListResultPage) NextWithContext(ctx context.Context) (
|
|||
tracing.EndSpan(ctx, sc, err)
|
||||
}()
|
||||
}
|
||||
next, err := page.fn(ctx, page.rdlr)
|
||||
if err != nil {
|
||||
return err
|
||||
for {
|
||||
next, err := page.fn(ctx, page.rdlr)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
page.rdlr = next
|
||||
if !next.hasNextLink() || !next.IsEmpty() {
|
||||
break
|
||||
}
|
||||
}
|
||||
page.rdlr = next
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
@ -1124,8 +1186,11 @@ func (page RoleDefinitionListResultPage) Values() []RoleDefinition {
|
|||
}
|
||||
|
||||
// Creates a new instance of the RoleDefinitionListResultPage type.
|
||||
func NewRoleDefinitionListResultPage(getNextPage func(context.Context, RoleDefinitionListResult) (RoleDefinitionListResult, error)) RoleDefinitionListResultPage {
|
||||
return RoleDefinitionListResultPage{fn: getNextPage}
|
||||
func NewRoleDefinitionListResultPage(cur RoleDefinitionListResult, getNextPage func(context.Context, RoleDefinitionListResult) (RoleDefinitionListResult, error)) RoleDefinitionListResultPage {
|
||||
return RoleDefinitionListResultPage{
|
||||
fn: getNextPage,
|
||||
rdlr: cur,
|
||||
}
|
||||
}
|
||||
|
||||
// RoleDefinitionProperties role definition properties.
|
||||
|
|
|
|||
|
|
@ -76,6 +76,11 @@ func (client PermissionsClient) ListForResource(ctx context.Context, resourceGro
|
|||
result.pgr, err = client.ListForResourceResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.PermissionsClient", "ListForResource", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.pgr.hasNextLink() && result.pgr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -191,6 +196,11 @@ func (client PermissionsClient) ListForResourceGroup(ctx context.Context, resour
|
|||
result.pgr, err = client.ListForResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.PermissionsClient", "ListForResourceGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.pgr.hasNextLink() && result.pgr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -74,6 +74,7 @@ func (client ProviderOperationsMetadataClient) Get(ctx context.Context, resource
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.ProviderOperationsMetadataClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -152,6 +153,11 @@ func (client ProviderOperationsMetadataClient) List(ctx context.Context, expand
|
|||
result.pomlr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.ProviderOperationsMetadataClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.pomlr.hasNextLink() && result.pomlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -87,6 +87,7 @@ func (client RoleAssignmentsClient) Create(ctx context.Context, scope string, ro
|
|||
result, err = client.CreateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleAssignmentsClient", "Create", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -172,6 +173,7 @@ func (client RoleAssignmentsClient) CreateByID(ctx context.Context, roleID strin
|
|||
result, err = client.CreateByIDResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleAssignmentsClient", "CreateByID", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -247,6 +249,7 @@ func (client RoleAssignmentsClient) Delete(ctx context.Context, scope string, ro
|
|||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleAssignmentsClient", "Delete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -320,6 +323,7 @@ func (client RoleAssignmentsClient) DeleteByID(ctx context.Context, roleID strin
|
|||
result, err = client.DeleteByIDResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleAssignmentsClient", "DeleteByID", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -393,6 +397,7 @@ func (client RoleAssignmentsClient) Get(ctx context.Context, scope string, roleA
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleAssignmentsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -466,6 +471,7 @@ func (client RoleAssignmentsClient) GetByID(ctx context.Context, roleID string)
|
|||
result, err = client.GetByIDResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleAssignmentsClient", "GetByID", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -541,6 +547,11 @@ func (client RoleAssignmentsClient) List(ctx context.Context, filter string) (re
|
|||
result.ralr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleAssignmentsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ralr.hasNextLink() && result.ralr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -661,6 +672,11 @@ func (client RoleAssignmentsClient) ListForResource(ctx context.Context, resourc
|
|||
result.ralr, err = client.ListForResourceResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleAssignmentsClient", "ListForResource", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ralr.hasNextLink() && result.ralr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -782,6 +798,11 @@ func (client RoleAssignmentsClient) ListForResourceGroup(ctx context.Context, re
|
|||
result.ralr, err = client.ListForResourceGroupResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleAssignmentsClient", "ListForResourceGroup", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ralr.hasNextLink() && result.ralr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -899,6 +920,11 @@ func (client RoleAssignmentsClient) ListForScope(ctx context.Context, scope stri
|
|||
result.ralr, err = client.ListForScopeResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleAssignmentsClient", "ListForScope", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.ralr.hasNextLink() && result.ralr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
|
|
@ -73,6 +73,7 @@ func (client RoleDefinitionsClient) CreateOrUpdate(ctx context.Context, scope st
|
|||
result, err = client.CreateOrUpdateResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleDefinitionsClient", "CreateOrUpdate", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -152,6 +153,7 @@ func (client RoleDefinitionsClient) Delete(ctx context.Context, scope string, ro
|
|||
result, err = client.DeleteResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleDefinitionsClient", "Delete", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -226,6 +228,7 @@ func (client RoleDefinitionsClient) Get(ctx context.Context, scope string, roleD
|
|||
result, err = client.GetResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleDefinitionsClient", "Get", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -302,6 +305,7 @@ func (client RoleDefinitionsClient) GetByID(ctx context.Context, roleID string)
|
|||
result, err = client.GetByIDResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleDefinitionsClient", "GetByID", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
@ -377,6 +381,11 @@ func (client RoleDefinitionsClient) List(ctx context.Context, scope string, filt
|
|||
result.rdlr, err = client.ListResponder(resp)
|
||||
if err != nil {
|
||||
err = autorest.NewErrorWithError(err, "authorization.RoleDefinitionsClient", "List", resp, "Failure responding to request")
|
||||
return
|
||||
}
|
||||
if result.rdlr.hasNextLink() && result.rdlr.IsEmpty() {
|
||||
err = result.NextWithContext(ctx)
|
||||
return
|
||||
}
|
||||
|
||||
return
|
||||
|
|
|
|||
2
vendor/github.com/Azure/azure-sdk-for-go/version/version.go
generated
vendored
2
vendor/github.com/Azure/azure-sdk-for-go/version/version.go
generated
vendored
|
|
@ -18,4 +18,4 @@ package version
|
|||
// Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
||||
|
||||
// Number contains the semantic version of this SDK.
|
||||
const Number = "v44.0.0"
|
||||
const Number = "v51.1.0"
|
||||
|
|
|
|||
1
vendor/github.com/Azure/go-autorest/autorest/adal/go.mod
generated
vendored
1
vendor/github.com/Azure/go-autorest/autorest/adal/go.mod
generated
vendored
|
|
@ -6,6 +6,7 @@ require (
|
|||
github.com/Azure/go-autorest v14.2.0+incompatible
|
||||
github.com/Azure/go-autorest/autorest/date v0.3.0
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.1
|
||||
github.com/Azure/go-autorest/logger v0.2.0
|
||||
github.com/Azure/go-autorest/tracing v0.6.0
|
||||
github.com/form3tech-oss/jwt-go v3.2.2+incompatible
|
||||
golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0
|
||||
|
|
|
|||
2
vendor/github.com/Azure/go-autorest/autorest/adal/go.sum
generated
vendored
2
vendor/github.com/Azure/go-autorest/autorest/adal/go.sum
generated
vendored
|
|
@ -4,6 +4,8 @@ github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8K
|
|||
github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
|
||||
github.com/Azure/go-autorest/logger v0.2.0 h1:e4RVHVZKC5p6UANLJHkM4OfR1UKZPj8Wt8Pcx+3oqrE=
|
||||
github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
|
||||
github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
|
||||
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
|
||||
github.com/form3tech-oss/jwt-go v3.2.2+incompatible h1:TcekIExNqud5crz4xD2pavyTgWiPvpYe4Xau31I0PRk=
|
||||
|
|
|
|||
1
vendor/github.com/Azure/go-autorest/autorest/adal/sender.go
generated
vendored
1
vendor/github.com/Azure/go-autorest/autorest/adal/sender.go
generated
vendored
|
|
@ -28,6 +28,7 @@ const (
|
|||
mimeTypeFormPost = "application/x-www-form-urlencoded"
|
||||
)
|
||||
|
||||
// DO NOT ACCESS THIS DIRECTLY. go through sender()
|
||||
var defaultSender Sender
|
||||
var defaultSenderInit = &sync.Once{}
|
||||
|
||||
|
|
|
|||
441
vendor/github.com/Azure/go-autorest/autorest/adal/token.go
generated
vendored
441
vendor/github.com/Azure/go-autorest/autorest/adal/token.go
generated
vendored
|
|
@ -30,11 +30,13 @@ import (
|
|||
"net/http"
|
||||
"net/url"
|
||||
"os"
|
||||
"strconv"
|
||||
"strings"
|
||||
"sync"
|
||||
"time"
|
||||
|
||||
"github.com/Azure/go-autorest/autorest/date"
|
||||
"github.com/Azure/go-autorest/logger"
|
||||
"github.com/form3tech-oss/jwt-go"
|
||||
)
|
||||
|
||||
|
|
@ -69,13 +71,22 @@ const (
|
|||
defaultMaxMSIRefreshAttempts = 5
|
||||
|
||||
// asMSIEndpointEnv is the environment variable used to store the endpoint on App Service and Functions
|
||||
asMSIEndpointEnv = "MSI_ENDPOINT"
|
||||
msiEndpointEnv = "MSI_ENDPOINT"
|
||||
|
||||
// asMSISecretEnv is the environment variable used to store the request secret on App Service and Functions
|
||||
asMSISecretEnv = "MSI_SECRET"
|
||||
msiSecretEnv = "MSI_SECRET"
|
||||
|
||||
// the API version to use for the App Service MSI endpoint
|
||||
appServiceAPIVersion = "2017-09-01"
|
||||
// the API version to use for the legacy App Service MSI endpoint
|
||||
appServiceAPIVersion2017 = "2017-09-01"
|
||||
|
||||
// secret header used when authenticating against app service MSI endpoint
|
||||
secretHeader = "Secret"
|
||||
|
||||
// the format for expires_on in UTC with AM/PM
|
||||
expiresOnDateFormatPM = "1/2/2006 15:04:05 PM +00:00"
|
||||
|
||||
// the format for expires_on in UTC without AM/PM
|
||||
expiresOnDateFormat = "1/2/2006 15:04:05 +00:00"
|
||||
)
|
||||
|
||||
// OAuthTokenProvider is an interface which should be implemented by an access token retriever
|
||||
|
|
@ -282,6 +293,8 @@ func (secret ServicePrincipalCertificateSecret) MarshalJSON() ([]byte, error) {
|
|||
|
||||
// ServicePrincipalMSISecret implements ServicePrincipalSecret for machines running the MSI Extension.
|
||||
type ServicePrincipalMSISecret struct {
|
||||
msiType msiType
|
||||
clientResourceID string
|
||||
}
|
||||
|
||||
// SetAuthenticationValues is a method of the interface ServicePrincipalSecret.
|
||||
|
|
@ -652,94 +665,173 @@ func NewServicePrincipalTokenFromAuthorizationCode(oauthConfig OAuthConfig, clie
|
|||
)
|
||||
}
|
||||
|
||||
type msiType int
|
||||
|
||||
const (
|
||||
msiTypeUnavailable msiType = iota
|
||||
msiTypeAppServiceV20170901
|
||||
msiTypeCloudShell
|
||||
msiTypeIMDS
|
||||
)
|
||||
|
||||
func (m msiType) String() string {
|
||||
switch m {
|
||||
case msiTypeUnavailable:
|
||||
return "unavailable"
|
||||
case msiTypeAppServiceV20170901:
|
||||
return "AppServiceV20170901"
|
||||
case msiTypeCloudShell:
|
||||
return "CloudShell"
|
||||
case msiTypeIMDS:
|
||||
return "IMDS"
|
||||
default:
|
||||
return fmt.Sprintf("unhandled MSI type %d", m)
|
||||
}
|
||||
}
|
||||
|
||||
// returns the MSI type and endpoint, or an error
|
||||
func getMSIType() (msiType, string, error) {
|
||||
if endpointEnvVar := os.Getenv(msiEndpointEnv); endpointEnvVar != "" {
|
||||
// if the env var MSI_ENDPOINT is set
|
||||
if secretEnvVar := os.Getenv(msiSecretEnv); secretEnvVar != "" {
|
||||
// if BOTH the env vars MSI_ENDPOINT and MSI_SECRET are set the msiType is AppService
|
||||
return msiTypeAppServiceV20170901, endpointEnvVar, nil
|
||||
}
|
||||
// if ONLY the env var MSI_ENDPOINT is set the msiType is CloudShell
|
||||
return msiTypeCloudShell, endpointEnvVar, nil
|
||||
} else if msiAvailableHook(context.Background(), sender()) {
|
||||
// if MSI_ENDPOINT is NOT set AND the IMDS endpoint is available the msiType is IMDS. This will timeout after 500 milliseconds
|
||||
return msiTypeIMDS, msiEndpoint, nil
|
||||
} else {
|
||||
// if MSI_ENDPOINT is NOT set and IMDS endpoint is not available Managed Identity is not available
|
||||
return msiTypeUnavailable, "", errors.New("MSI not available")
|
||||
}
|
||||
}
|
||||
|
||||
// GetMSIVMEndpoint gets the MSI endpoint on Virtual Machines.
|
||||
// NOTE: this always returns the IMDS endpoint, it does not work for app services or cloud shell.
|
||||
// Deprecated: NewServicePrincipalTokenFromMSI() and variants will automatically detect the endpoint.
|
||||
func GetMSIVMEndpoint() (string, error) {
|
||||
return msiEndpoint, nil
|
||||
}
|
||||
|
||||
// NOTE: this only indicates if the ASE environment credentials have been set
|
||||
// which does not necessarily mean that the caller is authenticating via ASE!
|
||||
func isAppService() bool {
|
||||
_, asMSIEndpointEnvExists := os.LookupEnv(asMSIEndpointEnv)
|
||||
_, asMSISecretEnvExists := os.LookupEnv(asMSISecretEnv)
|
||||
|
||||
return asMSIEndpointEnvExists && asMSISecretEnvExists
|
||||
}
|
||||
|
||||
// GetMSIAppServiceEndpoint get the MSI endpoint for App Service and Functions
|
||||
// GetMSIAppServiceEndpoint get the MSI endpoint for App Service and Functions.
|
||||
// It will return an error when not running in an app service/functions environment.
|
||||
// Deprecated: NewServicePrincipalTokenFromMSI() and variants will automatically detect the endpoint.
|
||||
func GetMSIAppServiceEndpoint() (string, error) {
|
||||
asMSIEndpoint, asMSIEndpointEnvExists := os.LookupEnv(asMSIEndpointEnv)
|
||||
|
||||
if asMSIEndpointEnvExists {
|
||||
return asMSIEndpoint, nil
|
||||
msiType, endpoint, err := getMSIType()
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
switch msiType {
|
||||
case msiTypeAppServiceV20170901:
|
||||
return endpoint, nil
|
||||
default:
|
||||
return "", fmt.Errorf("%s is not app service environment", msiType)
|
||||
}
|
||||
return "", errors.New("MSI endpoint not found")
|
||||
}
|
||||
|
||||
// GetMSIEndpoint get the appropriate MSI endpoint depending on the runtime environment
|
||||
// Deprecated: NewServicePrincipalTokenFromMSI() and variants will automatically detect the endpoint.
|
||||
func GetMSIEndpoint() (string, error) {
|
||||
if isAppService() {
|
||||
return GetMSIAppServiceEndpoint()
|
||||
}
|
||||
return GetMSIVMEndpoint()
|
||||
_, endpoint, err := getMSIType()
|
||||
return endpoint, err
|
||||
}
|
||||
|
||||
// NewServicePrincipalTokenFromMSI creates a ServicePrincipalToken via the MSI VM Extension.
|
||||
// It will use the system assigned identity when creating the token.
|
||||
// msiEndpoint - empty string, or pass a non-empty string to override the default value.
|
||||
// Deprecated: use NewServicePrincipalTokenFromManagedIdentity() instead.
|
||||
func NewServicePrincipalTokenFromMSI(msiEndpoint, resource string, callbacks ...TokenRefreshCallback) (*ServicePrincipalToken, error) {
|
||||
return newServicePrincipalTokenFromMSI(msiEndpoint, resource, nil, nil, callbacks...)
|
||||
return newServicePrincipalTokenFromMSI(msiEndpoint, resource, "", "", callbacks...)
|
||||
}
|
||||
|
||||
// NewServicePrincipalTokenFromMSIWithUserAssignedID creates a ServicePrincipalToken via the MSI VM Extension.
|
||||
// It will use the clientID of specified user assigned identity when creating the token.
|
||||
// msiEndpoint - empty string, or pass a non-empty string to override the default value.
|
||||
// Deprecated: use NewServicePrincipalTokenFromManagedIdentity() instead.
|
||||
func NewServicePrincipalTokenFromMSIWithUserAssignedID(msiEndpoint, resource string, userAssignedID string, callbacks ...TokenRefreshCallback) (*ServicePrincipalToken, error) {
|
||||
return newServicePrincipalTokenFromMSI(msiEndpoint, resource, &userAssignedID, nil, callbacks...)
|
||||
if err := validateStringParam(userAssignedID, "userAssignedID"); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return newServicePrincipalTokenFromMSI(msiEndpoint, resource, userAssignedID, "", callbacks...)
|
||||
}
|
||||
|
||||
// NewServicePrincipalTokenFromMSIWithIdentityResourceID creates a ServicePrincipalToken via the MSI VM Extension.
|
||||
// It will use the azure resource id of user assigned identity when creating the token.
|
||||
// msiEndpoint - empty string, or pass a non-empty string to override the default value.
|
||||
// Deprecated: use NewServicePrincipalTokenFromManagedIdentity() instead.
|
||||
func NewServicePrincipalTokenFromMSIWithIdentityResourceID(msiEndpoint, resource string, identityResourceID string, callbacks ...TokenRefreshCallback) (*ServicePrincipalToken, error) {
|
||||
return newServicePrincipalTokenFromMSI(msiEndpoint, resource, nil, &identityResourceID, callbacks...)
|
||||
}
|
||||
|
||||
func newServicePrincipalTokenFromMSI(msiEndpoint, resource string, userAssignedID *string, identityResourceID *string, callbacks ...TokenRefreshCallback) (*ServicePrincipalToken, error) {
|
||||
if err := validateStringParam(msiEndpoint, "msiEndpoint"); err != nil {
|
||||
if err := validateStringParam(identityResourceID, "identityResourceID"); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return newServicePrincipalTokenFromMSI(msiEndpoint, resource, "", identityResourceID, callbacks...)
|
||||
}
|
||||
|
||||
// ManagedIdentityOptions contains optional values for configuring managed identity authentication.
|
||||
type ManagedIdentityOptions struct {
|
||||
// ClientID is the user-assigned identity to use during authentication.
|
||||
// It is mutually exclusive with IdentityResourceID.
|
||||
ClientID string
|
||||
|
||||
// IdentityResourceID is the resource ID of the user-assigned identity to use during authentication.
|
||||
// It is mutually exclusive with ClientID.
|
||||
IdentityResourceID string
|
||||
}
|
||||
|
||||
// NewServicePrincipalTokenFromManagedIdentity creates a ServicePrincipalToken using a managed identity.
|
||||
// It supports the following managed identity environments.
|
||||
// - App Service Environment (API version 2017-09-01 only)
|
||||
// - Cloud shell
|
||||
// - IMDS with a system or user assigned identity
|
||||
func NewServicePrincipalTokenFromManagedIdentity(resource string, options *ManagedIdentityOptions, callbacks ...TokenRefreshCallback) (*ServicePrincipalToken, error) {
|
||||
if options == nil {
|
||||
options = &ManagedIdentityOptions{}
|
||||
}
|
||||
return newServicePrincipalTokenFromMSI("", resource, options.ClientID, options.IdentityResourceID, callbacks...)
|
||||
}
|
||||
|
||||
func newServicePrincipalTokenFromMSI(msiEndpoint, resource, userAssignedID, identityResourceID string, callbacks ...TokenRefreshCallback) (*ServicePrincipalToken, error) {
|
||||
if err := validateStringParam(resource, "resource"); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if userAssignedID != nil {
|
||||
if err := validateStringParam(*userAssignedID, "userAssignedID"); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if userAssignedID != "" && identityResourceID != "" {
|
||||
return nil, errors.New("cannot specify userAssignedID and identityResourceID")
|
||||
}
|
||||
if identityResourceID != nil {
|
||||
if err := validateStringParam(*identityResourceID, "identityResourceID"); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
msiType, endpoint, err := getMSIType()
|
||||
if err != nil {
|
||||
logger.Instance.Writef(logger.LogError, "Error determining managed identity environment: %v", err)
|
||||
return nil, err
|
||||
}
|
||||
// We set the oauth config token endpoint to be MSI's endpoint
|
||||
msiEndpointURL, err := url.Parse(msiEndpoint)
|
||||
logger.Instance.Writef(logger.LogInfo, "Managed identity environment is %s, endpoint is %s", msiType, endpoint)
|
||||
if msiEndpoint != "" {
|
||||
endpoint = msiEndpoint
|
||||
logger.Instance.Writef(logger.LogInfo, "Managed identity custom endpoint is %s", endpoint)
|
||||
}
|
||||
msiEndpointURL, err := url.Parse(endpoint)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
v := url.Values{}
|
||||
v.Set("resource", resource)
|
||||
// App Service MSI currently only supports token API version 2017-09-01
|
||||
if isAppService() {
|
||||
v.Set("api-version", appServiceAPIVersion)
|
||||
} else {
|
||||
v.Set("api-version", msiAPIVersion)
|
||||
// cloud shell sends its data in the request body
|
||||
if msiType != msiTypeCloudShell {
|
||||
v := url.Values{}
|
||||
v.Set("resource", resource)
|
||||
clientIDParam := "client_id"
|
||||
switch msiType {
|
||||
case msiTypeAppServiceV20170901:
|
||||
clientIDParam = "clientid"
|
||||
v.Set("api-version", appServiceAPIVersion2017)
|
||||
break
|
||||
case msiTypeIMDS:
|
||||
v.Set("api-version", msiAPIVersion)
|
||||
}
|
||||
if userAssignedID != "" {
|
||||
v.Set(clientIDParam, userAssignedID)
|
||||
} else if identityResourceID != "" {
|
||||
v.Set("mi_res_id", identityResourceID)
|
||||
}
|
||||
msiEndpointURL.RawQuery = v.Encode()
|
||||
}
|
||||
if userAssignedID != nil {
|
||||
v.Set("client_id", *userAssignedID)
|
||||
}
|
||||
if identityResourceID != nil {
|
||||
v.Set("mi_res_id", *identityResourceID)
|
||||
}
|
||||
msiEndpointURL.RawQuery = v.Encode()
|
||||
|
||||
spt := &ServicePrincipalToken{
|
||||
inner: servicePrincipalToken{
|
||||
|
|
@ -747,10 +839,14 @@ func newServicePrincipalTokenFromMSI(msiEndpoint, resource string, userAssignedI
|
|||
OauthConfig: OAuthConfig{
|
||||
TokenEndpoint: *msiEndpointURL,
|
||||
},
|
||||
Secret: &ServicePrincipalMSISecret{},
|
||||
Secret: &ServicePrincipalMSISecret{
|
||||
msiType: msiType,
|
||||
clientResourceID: identityResourceID,
|
||||
},
|
||||
Resource: resource,
|
||||
AutoRefresh: true,
|
||||
RefreshWithin: defaultRefresh,
|
||||
ClientID: userAssignedID,
|
||||
},
|
||||
refreshLock: &sync.RWMutex{},
|
||||
sender: sender(),
|
||||
|
|
@ -758,10 +854,6 @@ func newServicePrincipalTokenFromMSI(msiEndpoint, resource string, userAssignedI
|
|||
MaxMSIRefreshAttempts: defaultMaxMSIRefreshAttempts,
|
||||
}
|
||||
|
||||
if userAssignedID != nil {
|
||||
spt.inner.ClientID = *userAssignedID
|
||||
}
|
||||
|
||||
return spt, nil
|
||||
}
|
||||
|
||||
|
|
@ -858,31 +950,6 @@ func (spt *ServicePrincipalToken) getGrantType() string {
|
|||
}
|
||||
}
|
||||
|
||||
func isIMDS(u url.URL) bool {
|
||||
return isMSIEndpoint(u) == true || isASEEndpoint(u) == true
|
||||
}
|
||||
|
||||
func isMSIEndpoint(endpoint url.URL) bool {
|
||||
msi, err := url.Parse(msiEndpoint)
|
||||
if err != nil {
|
||||
return false
|
||||
}
|
||||
return endpoint.Host == msi.Host && endpoint.Path == msi.Path
|
||||
}
|
||||
|
||||
func isASEEndpoint(endpoint url.URL) bool {
|
||||
aseEndpoint, err := GetMSIAppServiceEndpoint()
|
||||
if err != nil {
|
||||
// app service environment isn't enabled
|
||||
return false
|
||||
}
|
||||
ase, err := url.Parse(aseEndpoint)
|
||||
if err != nil {
|
||||
return false
|
||||
}
|
||||
return endpoint.Host == ase.Host && endpoint.Path == ase.Path
|
||||
}
|
||||
|
||||
func (spt *ServicePrincipalToken) refreshInternal(ctx context.Context, resource string) error {
|
||||
if spt.customRefreshFunc != nil {
|
||||
token, err := spt.customRefreshFunc(ctx, resource)
|
||||
|
|
@ -892,19 +959,38 @@ func (spt *ServicePrincipalToken) refreshInternal(ctx context.Context, resource
|
|||
spt.inner.Token = *token
|
||||
return spt.InvokeRefreshCallbacks(spt.inner.Token)
|
||||
}
|
||||
|
||||
req, err := http.NewRequest(http.MethodPost, spt.inner.OauthConfig.TokenEndpoint.String(), nil)
|
||||
if err != nil {
|
||||
return fmt.Errorf("adal: Failed to build the refresh request. Error = '%v'", err)
|
||||
}
|
||||
req.Header.Add("User-Agent", UserAgent())
|
||||
// Add header when runtime is on App Service or Functions
|
||||
if isASEEndpoint(spt.inner.OauthConfig.TokenEndpoint) {
|
||||
asMSISecret, _ := os.LookupEnv(asMSISecretEnv)
|
||||
req.Header.Add("Secret", asMSISecret)
|
||||
}
|
||||
req = req.WithContext(ctx)
|
||||
if !isIMDS(spt.inner.OauthConfig.TokenEndpoint) {
|
||||
var resp *http.Response
|
||||
if msiSecret, ok := spt.inner.Secret.(*ServicePrincipalMSISecret); ok {
|
||||
switch msiSecret.msiType {
|
||||
case msiTypeAppServiceV20170901:
|
||||
req.Method = http.MethodGet
|
||||
req.Header.Set("secret", os.Getenv(msiSecretEnv))
|
||||
break
|
||||
case msiTypeCloudShell:
|
||||
req.Header.Set("Metadata", "true")
|
||||
data := url.Values{}
|
||||
data.Set("resource", spt.inner.Resource)
|
||||
if spt.inner.ClientID != "" {
|
||||
data.Set("client_id", spt.inner.ClientID)
|
||||
} else if msiSecret.clientResourceID != "" {
|
||||
data.Set("msi_res_id", msiSecret.clientResourceID)
|
||||
}
|
||||
req.Body = ioutil.NopCloser(strings.NewReader(data.Encode()))
|
||||
req.Header.Set("Content-Type", "application/x-www-form-urlencoded")
|
||||
break
|
||||
case msiTypeIMDS:
|
||||
req.Method = http.MethodGet
|
||||
req.Header.Set("Metadata", "true")
|
||||
break
|
||||
}
|
||||
resp, err = retryForIMDS(spt.sender, req, spt.MaxMSIRefreshAttempts)
|
||||
} else {
|
||||
v := url.Values{}
|
||||
v.Set("client_id", spt.inner.ClientID)
|
||||
v.Set("resource", resource)
|
||||
|
|
@ -933,27 +1019,9 @@ func (spt *ServicePrincipalToken) refreshInternal(ctx context.Context, resource
|
|||
req.ContentLength = int64(len(s))
|
||||
req.Header.Set(contentType, mimeTypeFormPost)
|
||||
req.Body = body
|
||||
}
|
||||
|
||||
if _, ok := spt.inner.Secret.(*ServicePrincipalMSISecret); ok {
|
||||
req.Method = http.MethodGet
|
||||
req.Header.Set(metadataHeader, "true")
|
||||
}
|
||||
|
||||
var resp *http.Response
|
||||
if isMSIEndpoint(spt.inner.OauthConfig.TokenEndpoint) {
|
||||
resp, err = getMSIEndpoint(ctx, spt.sender)
|
||||
if err != nil {
|
||||
// return a TokenRefreshError here so that we don't keep retrying
|
||||
return newTokenRefreshError(fmt.Sprintf("the MSI endpoint is not available. Failed HTTP request to MSI endpoint: %v", err), nil)
|
||||
}
|
||||
resp.Body.Close()
|
||||
}
|
||||
if isIMDS(spt.inner.OauthConfig.TokenEndpoint) {
|
||||
resp, err = retryForIMDS(spt.sender, req, spt.MaxMSIRefreshAttempts)
|
||||
} else {
|
||||
resp, err = spt.sender.Do(req)
|
||||
}
|
||||
|
||||
if err != nil {
|
||||
// don't return a TokenRefreshError here; this will allow retry logic to apply
|
||||
return fmt.Errorf("adal: Failed to execute the refresh request. Error = '%v'", err)
|
||||
|
|
@ -964,9 +1032,9 @@ func (spt *ServicePrincipalToken) refreshInternal(ctx context.Context, resource
|
|||
|
||||
if resp.StatusCode != http.StatusOK {
|
||||
if err != nil {
|
||||
return newTokenRefreshError(fmt.Sprintf("adal: Refresh request failed. Status Code = '%d'. Failed reading response body: %v", resp.StatusCode, err), resp)
|
||||
return newTokenRefreshError(fmt.Sprintf("adal: Refresh request failed. Status Code = '%d'. Failed reading response body: %v Endpoint %s", resp.StatusCode, err, req.URL.String()), resp)
|
||||
}
|
||||
return newTokenRefreshError(fmt.Sprintf("adal: Refresh request failed. Status Code = '%d'. Response body: %s", resp.StatusCode, string(rb)), resp)
|
||||
return newTokenRefreshError(fmt.Sprintf("adal: Refresh request failed. Status Code = '%d'. Response body: %s Endpoint %s", resp.StatusCode, string(rb), req.URL.String()), resp)
|
||||
}
|
||||
|
||||
// for the following error cases don't return a TokenRefreshError. the operation succeeded
|
||||
|
|
@ -979,15 +1047,60 @@ func (spt *ServicePrincipalToken) refreshInternal(ctx context.Context, resource
|
|||
if len(strings.Trim(string(rb), " ")) == 0 {
|
||||
return fmt.Errorf("adal: Empty service principal token received during refresh")
|
||||
}
|
||||
var token Token
|
||||
token := struct {
|
||||
AccessToken string `json:"access_token"`
|
||||
RefreshToken string `json:"refresh_token"`
|
||||
|
||||
// AAD returns expires_in as a string, ADFS returns it as an int
|
||||
ExpiresIn json.Number `json:"expires_in"`
|
||||
// expires_on can be in two formats, a UTC time stamp or the number of seconds.
|
||||
ExpiresOn string `json:"expires_on"`
|
||||
NotBefore json.Number `json:"not_before"`
|
||||
|
||||
Resource string `json:"resource"`
|
||||
Type string `json:"token_type"`
|
||||
}{}
|
||||
// return a TokenRefreshError in the follow error cases as the token is in an unexpected format
|
||||
err = json.Unmarshal(rb, &token)
|
||||
if err != nil {
|
||||
return fmt.Errorf("adal: Failed to unmarshal the service principal token during refresh. Error = '%v' JSON = '%s'", err, string(rb))
|
||||
return newTokenRefreshError(fmt.Sprintf("adal: Failed to unmarshal the service principal token during refresh. Error = '%v' JSON = '%s'", err, string(rb)), resp)
|
||||
}
|
||||
expiresOn := json.Number("")
|
||||
// ADFS doesn't include the expires_on field
|
||||
if token.ExpiresOn != "" {
|
||||
if expiresOn, err = parseExpiresOn(token.ExpiresOn); err != nil {
|
||||
return newTokenRefreshError(fmt.Sprintf("adal: failed to parse expires_on: %v value '%s'", err, token.ExpiresOn), resp)
|
||||
}
|
||||
}
|
||||
spt.inner.Token.AccessToken = token.AccessToken
|
||||
spt.inner.Token.RefreshToken = token.RefreshToken
|
||||
spt.inner.Token.ExpiresIn = token.ExpiresIn
|
||||
spt.inner.Token.ExpiresOn = expiresOn
|
||||
spt.inner.Token.NotBefore = token.NotBefore
|
||||
spt.inner.Token.Resource = token.Resource
|
||||
spt.inner.Token.Type = token.Type
|
||||
|
||||
spt.inner.Token = token
|
||||
return spt.InvokeRefreshCallbacks(spt.inner.Token)
|
||||
}
|
||||
|
||||
return spt.InvokeRefreshCallbacks(token)
|
||||
// converts expires_on to the number of seconds
|
||||
func parseExpiresOn(s string) (json.Number, error) {
|
||||
// convert the expiration date to the number of seconds from now
|
||||
timeToDuration := func(t time.Time) json.Number {
|
||||
dur := t.Sub(time.Now().UTC())
|
||||
return json.Number(strconv.FormatInt(int64(dur.Round(time.Second).Seconds()), 10))
|
||||
}
|
||||
if _, err := strconv.ParseInt(s, 10, 64); err == nil {
|
||||
// this is the number of seconds case, no conversion required
|
||||
return json.Number(s), nil
|
||||
} else if eo, err := time.Parse(expiresOnDateFormatPM, s); err == nil {
|
||||
return timeToDuration(eo), nil
|
||||
} else if eo, err := time.Parse(expiresOnDateFormat, s); err == nil {
|
||||
return timeToDuration(eo), nil
|
||||
} else {
|
||||
// unknown format
|
||||
return json.Number(""), err
|
||||
}
|
||||
}
|
||||
|
||||
// retry logic specific to retrieving a token from the IMDS endpoint
|
||||
|
|
@ -1118,46 +1231,6 @@ func (mt *MultiTenantServicePrincipalToken) AuxiliaryOAuthTokens() []string {
|
|||
return tokens
|
||||
}
|
||||
|
||||
// EnsureFreshWithContext will refresh the token if it will expire within the refresh window (as set by
|
||||
// RefreshWithin) and autoRefresh flag is on. This method is safe for concurrent use.
|
||||
func (mt *MultiTenantServicePrincipalToken) EnsureFreshWithContext(ctx context.Context) error {
|
||||
if err := mt.PrimaryToken.EnsureFreshWithContext(ctx); err != nil {
|
||||
return fmt.Errorf("failed to refresh primary token: %v", err)
|
||||
}
|
||||
for _, aux := range mt.AuxiliaryTokens {
|
||||
if err := aux.EnsureFreshWithContext(ctx); err != nil {
|
||||
return fmt.Errorf("failed to refresh auxiliary token: %v", err)
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// RefreshWithContext obtains a fresh token for the Service Principal.
|
||||
func (mt *MultiTenantServicePrincipalToken) RefreshWithContext(ctx context.Context) error {
|
||||
if err := mt.PrimaryToken.RefreshWithContext(ctx); err != nil {
|
||||
return fmt.Errorf("failed to refresh primary token: %v", err)
|
||||
}
|
||||
for _, aux := range mt.AuxiliaryTokens {
|
||||
if err := aux.RefreshWithContext(ctx); err != nil {
|
||||
return fmt.Errorf("failed to refresh auxiliary token: %v", err)
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// RefreshExchangeWithContext refreshes the token, but for a different resource.
|
||||
func (mt *MultiTenantServicePrincipalToken) RefreshExchangeWithContext(ctx context.Context, resource string) error {
|
||||
if err := mt.PrimaryToken.RefreshExchangeWithContext(ctx, resource); err != nil {
|
||||
return fmt.Errorf("failed to refresh primary token: %v", err)
|
||||
}
|
||||
for _, aux := range mt.AuxiliaryTokens {
|
||||
if err := aux.RefreshExchangeWithContext(ctx, resource); err != nil {
|
||||
return fmt.Errorf("failed to refresh auxiliary token: %v", err)
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// NewMultiTenantServicePrincipalToken creates a new MultiTenantServicePrincipalToken with the specified credentials and resource.
|
||||
func NewMultiTenantServicePrincipalToken(multiTenantCfg MultiTenantOAuthConfig, clientID string, secret string, resource string) (*MultiTenantServicePrincipalToken, error) {
|
||||
if err := validateStringParam(clientID, "clientID"); err != nil {
|
||||
|
|
@ -1188,6 +1261,55 @@ func NewMultiTenantServicePrincipalToken(multiTenantCfg MultiTenantOAuthConfig,
|
|||
return &m, nil
|
||||
}
|
||||
|
||||
// NewMultiTenantServicePrincipalTokenFromCertificate creates a new MultiTenantServicePrincipalToken with the specified certificate credentials and resource.
|
||||
func NewMultiTenantServicePrincipalTokenFromCertificate(multiTenantCfg MultiTenantOAuthConfig, clientID string, certificate *x509.Certificate, privateKey *rsa.PrivateKey, resource string) (*MultiTenantServicePrincipalToken, error) {
|
||||
if err := validateStringParam(clientID, "clientID"); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if err := validateStringParam(resource, "resource"); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if certificate == nil {
|
||||
return nil, fmt.Errorf("parameter 'certificate' cannot be nil")
|
||||
}
|
||||
if privateKey == nil {
|
||||
return nil, fmt.Errorf("parameter 'privateKey' cannot be nil")
|
||||
}
|
||||
auxTenants := multiTenantCfg.AuxiliaryTenants()
|
||||
m := MultiTenantServicePrincipalToken{
|
||||
AuxiliaryTokens: make([]*ServicePrincipalToken, len(auxTenants)),
|
||||
}
|
||||
primary, err := NewServicePrincipalTokenWithSecret(
|
||||
*multiTenantCfg.PrimaryTenant(),
|
||||
clientID,
|
||||
resource,
|
||||
&ServicePrincipalCertificateSecret{
|
||||
PrivateKey: privateKey,
|
||||
Certificate: certificate,
|
||||
},
|
||||
)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to create SPT for primary tenant: %v", err)
|
||||
}
|
||||
m.PrimaryToken = primary
|
||||
for i := range auxTenants {
|
||||
aux, err := NewServicePrincipalTokenWithSecret(
|
||||
*auxTenants[i],
|
||||
clientID,
|
||||
resource,
|
||||
&ServicePrincipalCertificateSecret{
|
||||
PrivateKey: privateKey,
|
||||
Certificate: certificate,
|
||||
},
|
||||
)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to create SPT for auxiliary tenant: %v", err)
|
||||
}
|
||||
m.AuxiliaryTokens[i] = aux
|
||||
}
|
||||
return &m, nil
|
||||
}
|
||||
|
||||
// MSIAvailable returns true if the MSI endpoint is available for authentication.
|
||||
func MSIAvailable(ctx context.Context, sender Sender) bool {
|
||||
resp, err := getMSIEndpoint(ctx, sender)
|
||||
|
|
@ -1196,3 +1318,8 @@ func MSIAvailable(ctx context.Context, sender Sender) bool {
|
|||
}
|
||||
return err == nil
|
||||
}
|
||||
|
||||
// used for testing purposes
|
||||
var msiAvailableHook = func(ctx context.Context, sender Sender) bool {
|
||||
return MSIAvailable(ctx, sender)
|
||||
}
|
||||
|
|
|
|||
43
vendor/github.com/Azure/go-autorest/autorest/adal/token_1.13.go
generated
vendored
43
vendor/github.com/Azure/go-autorest/autorest/adal/token_1.13.go
generated
vendored
|
|
@ -18,13 +18,12 @@ package adal
|
|||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"net/http"
|
||||
"time"
|
||||
)
|
||||
|
||||
func getMSIEndpoint(ctx context.Context, sender Sender) (*http.Response, error) {
|
||||
// this cannot fail, the return sig is due to legacy reasons
|
||||
msiEndpoint, _ := GetMSIVMEndpoint()
|
||||
tempCtx, cancel := context.WithTimeout(ctx, 500*time.Millisecond)
|
||||
defer cancel()
|
||||
// http.NewRequestWithContext() was added in Go 1.13
|
||||
|
|
@ -34,3 +33,43 @@ func getMSIEndpoint(ctx context.Context, sender Sender) (*http.Response, error)
|
|||
req.URL.RawQuery = q.Encode()
|
||||
return sender.Do(req)
|
||||
}
|
||||
|
||||
// EnsureFreshWithContext will refresh the token if it will expire within the refresh window (as set by
|
||||
// RefreshWithin) and autoRefresh flag is on. This method is safe for concurrent use.
|
||||
func (mt *MultiTenantServicePrincipalToken) EnsureFreshWithContext(ctx context.Context) error {
|
||||
if err := mt.PrimaryToken.EnsureFreshWithContext(ctx); err != nil {
|
||||
return fmt.Errorf("failed to refresh primary token: %w", err)
|
||||
}
|
||||
for _, aux := range mt.AuxiliaryTokens {
|
||||
if err := aux.EnsureFreshWithContext(ctx); err != nil {
|
||||
return fmt.Errorf("failed to refresh auxiliary token: %w", err)
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// RefreshWithContext obtains a fresh token for the Service Principal.
|
||||
func (mt *MultiTenantServicePrincipalToken) RefreshWithContext(ctx context.Context) error {
|
||||
if err := mt.PrimaryToken.RefreshWithContext(ctx); err != nil {
|
||||
return fmt.Errorf("failed to refresh primary token: %w", err)
|
||||
}
|
||||
for _, aux := range mt.AuxiliaryTokens {
|
||||
if err := aux.RefreshWithContext(ctx); err != nil {
|
||||
return fmt.Errorf("failed to refresh auxiliary token: %w", err)
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// RefreshExchangeWithContext refreshes the token, but for a different resource.
|
||||
func (mt *MultiTenantServicePrincipalToken) RefreshExchangeWithContext(ctx context.Context, resource string) error {
|
||||
if err := mt.PrimaryToken.RefreshExchangeWithContext(ctx, resource); err != nil {
|
||||
return fmt.Errorf("failed to refresh primary token: %w", err)
|
||||
}
|
||||
for _, aux := range mt.AuxiliaryTokens {
|
||||
if err := aux.RefreshExchangeWithContext(ctx, resource); err != nil {
|
||||
return fmt.Errorf("failed to refresh auxiliary token: %w", err)
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
|
|
|||
42
vendor/github.com/Azure/go-autorest/autorest/adal/token_legacy.go
generated
vendored
42
vendor/github.com/Azure/go-autorest/autorest/adal/token_legacy.go
generated
vendored
|
|
@ -23,8 +23,6 @@ import (
|
|||
)
|
||||
|
||||
func getMSIEndpoint(ctx context.Context, sender Sender) (*http.Response, error) {
|
||||
// this cannot fail, the return sig is due to legacy reasons
|
||||
msiEndpoint, _ := GetMSIVMEndpoint()
|
||||
tempCtx, cancel := context.WithTimeout(ctx, 500*time.Millisecond)
|
||||
defer cancel()
|
||||
req, _ := http.NewRequest(http.MethodGet, msiEndpoint, nil)
|
||||
|
|
@ -34,3 +32,43 @@ func getMSIEndpoint(ctx context.Context, sender Sender) (*http.Response, error)
|
|||
req.URL.RawQuery = q.Encode()
|
||||
return sender.Do(req)
|
||||
}
|
||||
|
||||
// EnsureFreshWithContext will refresh the token if it will expire within the refresh window (as set by
|
||||
// RefreshWithin) and autoRefresh flag is on. This method is safe for concurrent use.
|
||||
func (mt *MultiTenantServicePrincipalToken) EnsureFreshWithContext(ctx context.Context) error {
|
||||
if err := mt.PrimaryToken.EnsureFreshWithContext(ctx); err != nil {
|
||||
return err
|
||||
}
|
||||
for _, aux := range mt.AuxiliaryTokens {
|
||||
if err := aux.EnsureFreshWithContext(ctx); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// RefreshWithContext obtains a fresh token for the Service Principal.
|
||||
func (mt *MultiTenantServicePrincipalToken) RefreshWithContext(ctx context.Context) error {
|
||||
if err := mt.PrimaryToken.RefreshWithContext(ctx); err != nil {
|
||||
return err
|
||||
}
|
||||
for _, aux := range mt.AuxiliaryTokens {
|
||||
if err := aux.RefreshWithContext(ctx); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// RefreshExchangeWithContext refreshes the token, but for a different resource.
|
||||
func (mt *MultiTenantServicePrincipalToken) RefreshExchangeWithContext(ctx context.Context, resource string) error {
|
||||
if err := mt.PrimaryToken.RefreshExchangeWithContext(ctx, resource); err != nil {
|
||||
return err
|
||||
}
|
||||
for _, aux := range mt.AuxiliaryTokens {
|
||||
if err := aux.RefreshExchangeWithContext(ctx, resource); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
|
|
|||
57
vendor/github.com/Azure/go-autorest/autorest/azure/async.go
generated
vendored
57
vendor/github.com/Azure/go-autorest/autorest/azure/async.go
generated
vendored
|
|
@ -42,6 +42,52 @@ const (
|
|||
|
||||
var pollingCodes = [...]int{http.StatusNoContent, http.StatusAccepted, http.StatusCreated, http.StatusOK}
|
||||
|
||||
// FutureAPI contains the set of methods on the Future type.
|
||||
type FutureAPI interface {
|
||||
// Response returns the last HTTP response.
|
||||
Response() *http.Response
|
||||
|
||||
// Status returns the last status message of the operation.
|
||||
Status() string
|
||||
|
||||
// PollingMethod returns the method used to monitor the status of the asynchronous operation.
|
||||
PollingMethod() PollingMethodType
|
||||
|
||||
// DoneWithContext queries the service to see if the operation has completed.
|
||||
DoneWithContext(context.Context, autorest.Sender) (bool, error)
|
||||
|
||||
// GetPollingDelay returns a duration the application should wait before checking
|
||||
// the status of the asynchronous request and true; this value is returned from
|
||||
// the service via the Retry-After response header. If the header wasn't returned
|
||||
// then the function returns the zero-value time.Duration and false.
|
||||
GetPollingDelay() (time.Duration, bool)
|
||||
|
||||
// WaitForCompletionRef will return when one of the following conditions is met: the long
|
||||
// running operation has completed, the provided context is cancelled, or the client's
|
||||
// polling duration has been exceeded. It will retry failed polling attempts based on
|
||||
// the retry value defined in the client up to the maximum retry attempts.
|
||||
// If no deadline is specified in the context then the client.PollingDuration will be
|
||||
// used to determine if a default deadline should be used.
|
||||
// If PollingDuration is greater than zero the value will be used as the context's timeout.
|
||||
// If PollingDuration is zero then no default deadline will be used.
|
||||
WaitForCompletionRef(context.Context, autorest.Client) error
|
||||
|
||||
// MarshalJSON implements the json.Marshaler interface.
|
||||
MarshalJSON() ([]byte, error)
|
||||
|
||||
// MarshalJSON implements the json.Unmarshaler interface.
|
||||
UnmarshalJSON([]byte) error
|
||||
|
||||
// PollingURL returns the URL used for retrieving the status of the long-running operation.
|
||||
PollingURL() string
|
||||
|
||||
// GetResult should be called once polling has completed successfully.
|
||||
// It makes the final GET call to retrieve the resultant payload.
|
||||
GetResult(autorest.Sender) (*http.Response, error)
|
||||
}
|
||||
|
||||
var _ FutureAPI = (*Future)(nil)
|
||||
|
||||
// Future provides a mechanism to access the status and results of an asynchronous request.
|
||||
// Since futures are stateful they should be passed by value to avoid race conditions.
|
||||
type Future struct {
|
||||
|
|
@ -413,12 +459,12 @@ func (pt *pollingTrackerBase) updateRawBody() error {
|
|||
if err != nil {
|
||||
return autorest.NewErrorWithError(err, "pollingTrackerBase", "updateRawBody", nil, "failed to read response body")
|
||||
}
|
||||
// put the body back so it's available to other callers
|
||||
pt.resp.Body = ioutil.NopCloser(bytes.NewReader(b))
|
||||
// observed in 204 responses over HTTP/2.0; the content length is -1 but body is empty
|
||||
if len(b) == 0 {
|
||||
return nil
|
||||
}
|
||||
// put the body back so it's available to other callers
|
||||
pt.resp.Body = ioutil.NopCloser(bytes.NewReader(b))
|
||||
if err = json.Unmarshal(b, &pt.rawBody); err != nil {
|
||||
return autorest.NewErrorWithError(err, "pollingTrackerBase", "updateRawBody", nil, "failed to unmarshal response body")
|
||||
}
|
||||
|
|
@ -466,7 +512,12 @@ func (pt *pollingTrackerBase) updateErrorFromResponse() {
|
|||
re := respErr{}
|
||||
defer pt.resp.Body.Close()
|
||||
var b []byte
|
||||
if b, err = ioutil.ReadAll(pt.resp.Body); err != nil || len(b) == 0 {
|
||||
if b, err = ioutil.ReadAll(pt.resp.Body); err != nil {
|
||||
goto Default
|
||||
}
|
||||
// put the body back so it's available to other callers
|
||||
pt.resp.Body = ioutil.NopCloser(bytes.NewReader(b))
|
||||
if len(b) == 0 {
|
||||
goto Default
|
||||
}
|
||||
if err = json.Unmarshal(b, &re); err != nil {
|
||||
|
|
|
|||
92
vendor/github.com/Azure/go-autorest/autorest/azure/auth/auth.go
generated
vendored
92
vendor/github.com/Azure/go-autorest/autorest/azure/auth/auth.go
generated
vendored
|
|
@ -16,8 +16,6 @@ package auth
|
|||
|
||||
import (
|
||||
"bytes"
|
||||
"crypto/rsa"
|
||||
"crypto/x509"
|
||||
"encoding/binary"
|
||||
"encoding/json"
|
||||
"errors"
|
||||
|
|
@ -32,8 +30,8 @@ import (
|
|||
"github.com/Azure/go-autorest/autorest/adal"
|
||||
"github.com/Azure/go-autorest/autorest/azure"
|
||||
"github.com/Azure/go-autorest/autorest/azure/cli"
|
||||
"github.com/Azure/go-autorest/logger"
|
||||
"github.com/dimchansky/utfbom"
|
||||
"golang.org/x/crypto/pkcs12"
|
||||
)
|
||||
|
||||
// The possible keys in the Values map.
|
||||
|
|
@ -63,6 +61,7 @@ const (
|
|||
// 3. Username password
|
||||
// 4. MSI
|
||||
func NewAuthorizerFromEnvironment() (autorest.Authorizer, error) {
|
||||
logger.Instance.Writeln(logger.LogInfo, "NewAuthorizerFromEnvironment() determining authentication mechanism")
|
||||
settings, err := GetSettingsFromEnvironment()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
|
@ -76,6 +75,7 @@ func NewAuthorizerFromEnvironment() (autorest.Authorizer, error) {
|
|||
// 3. Username password
|
||||
// 4. MSI
|
||||
func NewAuthorizerFromEnvironmentWithResource(resource string) (autorest.Authorizer, error) {
|
||||
logger.Instance.Writeln(logger.LogInfo, "NewAuthorizerFromEnvironmentWithResource() determining authentication mechanism")
|
||||
settings, err := GetSettingsFromEnvironment()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
|
@ -125,6 +125,7 @@ func (settings EnvironmentSettings) GetSubscriptionID() string {
|
|||
// adds the specified environment variable value to the Values map if it exists
|
||||
func (settings EnvironmentSettings) setValue(key string) {
|
||||
if v := os.Getenv(key); v != "" {
|
||||
logger.Instance.Writef(logger.LogInfo, "GetSettingsFromEnvironment() found environment var %s\n", key)
|
||||
settings.Values[key] = v
|
||||
}
|
||||
}
|
||||
|
|
@ -141,6 +142,7 @@ func (settings EnvironmentSettings) getClientAndTenant() (string, string) {
|
|||
func (settings EnvironmentSettings) GetClientCredentials() (ClientCredentialsConfig, error) {
|
||||
secret := settings.Values[ClientSecret]
|
||||
if secret == "" {
|
||||
logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetClientCredentials() missing client secret")
|
||||
return ClientCredentialsConfig{}, errors.New("missing client secret")
|
||||
}
|
||||
clientID, tenantID := settings.getClientAndTenant()
|
||||
|
|
@ -161,6 +163,7 @@ func (settings EnvironmentSettings) GetClientCredentials() (ClientCredentialsCon
|
|||
func (settings EnvironmentSettings) GetClientCertificate() (ClientCertificateConfig, error) {
|
||||
certPath := settings.Values[CertificatePath]
|
||||
if certPath == "" {
|
||||
logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetClientCertificate() missing certificate path")
|
||||
return ClientCertificateConfig{}, errors.New("missing certificate path")
|
||||
}
|
||||
certPwd := settings.Values[CertificatePassword]
|
||||
|
|
@ -177,6 +180,7 @@ func (settings EnvironmentSettings) GetUsernamePassword() (UsernamePasswordConfi
|
|||
username := settings.Values[Username]
|
||||
password := settings.Values[Password]
|
||||
if username == "" || password == "" {
|
||||
logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetUsernamePassword() missing username and/or password")
|
||||
return UsernamePasswordConfig{}, errors.New("missing username/password")
|
||||
}
|
||||
clientID, tenantID := settings.getClientAndTenant()
|
||||
|
|
@ -211,35 +215,41 @@ func (settings EnvironmentSettings) GetDeviceFlow() DeviceFlowConfig {
|
|||
func (settings EnvironmentSettings) GetAuthorizer() (autorest.Authorizer, error) {
|
||||
//1.Client Credentials
|
||||
if c, e := settings.GetClientCredentials(); e == nil {
|
||||
logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetAuthorizer() using client secret credentials")
|
||||
return c.Authorizer()
|
||||
}
|
||||
|
||||
//2. Client Certificate
|
||||
if c, e := settings.GetClientCertificate(); e == nil {
|
||||
logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetAuthorizer() using client certificate credentials")
|
||||
return c.Authorizer()
|
||||
}
|
||||
|
||||
//3. Username Password
|
||||
if c, e := settings.GetUsernamePassword(); e == nil {
|
||||
logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetAuthorizer() using user name/password credentials")
|
||||
return c.Authorizer()
|
||||
}
|
||||
|
||||
// 4. MSI
|
||||
logger.Instance.Writeln(logger.LogInfo, "EnvironmentSettings.GetAuthorizer() using MSI authentication")
|
||||
return settings.GetMSI().Authorizer()
|
||||
}
|
||||
|
||||
// NewAuthorizerFromFile creates an Authorizer configured from a configuration file in the following order.
|
||||
// 1. Client credentials
|
||||
// 2. Client certificate
|
||||
func NewAuthorizerFromFile(baseURI string) (autorest.Authorizer, error) {
|
||||
// The path to the configuration file must be specified in the AZURE_AUTH_LOCATION environment variable.
|
||||
// resourceBaseURI - used to determine the resource type
|
||||
func NewAuthorizerFromFile(resourceBaseURI string) (autorest.Authorizer, error) {
|
||||
settings, err := GetSettingsFromFile()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if a, err := settings.ClientCredentialsAuthorizer(baseURI); err == nil {
|
||||
if a, err := settings.ClientCredentialsAuthorizer(resourceBaseURI); err == nil {
|
||||
return a, err
|
||||
}
|
||||
if a, err := settings.ClientCertificateAuthorizer(baseURI); err == nil {
|
||||
if a, err := settings.ClientCertificateAuthorizer(resourceBaseURI); err == nil {
|
||||
return a, err
|
||||
}
|
||||
return nil, errors.New("auth file missing client and certificate credentials")
|
||||
|
|
@ -248,6 +258,7 @@ func NewAuthorizerFromFile(baseURI string) (autorest.Authorizer, error) {
|
|||
// NewAuthorizerFromFileWithResource creates an Authorizer configured from a configuration file in the following order.
|
||||
// 1. Client credentials
|
||||
// 2. Client certificate
|
||||
// The path to the configuration file must be specified in the AZURE_AUTH_LOCATION environment variable.
|
||||
func NewAuthorizerFromFileWithResource(resource string) (autorest.Authorizer, error) {
|
||||
s, err := GetSettingsFromFile()
|
||||
if err != nil {
|
||||
|
|
@ -599,6 +610,7 @@ type ClientCertificateConfig struct {
|
|||
CertificatePath string
|
||||
CertificatePassword string
|
||||
TenantID string
|
||||
AuxTenants []string
|
||||
AADEndpoint string
|
||||
Resource string
|
||||
}
|
||||
|
|
@ -613,20 +625,44 @@ func (ccc ClientCertificateConfig) ServicePrincipalToken() (*adal.ServicePrincip
|
|||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to read the certificate file (%s): %v", ccc.CertificatePath, err)
|
||||
}
|
||||
certificate, rsaPrivateKey, err := decodePkcs12(certData, ccc.CertificatePassword)
|
||||
certificate, rsaPrivateKey, err := adal.DecodePfxCertificateData(certData, ccc.CertificatePassword)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to decode pkcs12 certificate while creating spt: %v", err)
|
||||
}
|
||||
return adal.NewServicePrincipalTokenFromCertificate(*oauthConfig, ccc.ClientID, certificate, rsaPrivateKey, ccc.Resource)
|
||||
}
|
||||
|
||||
// MultiTenantServicePrincipalToken creates a MultiTenantServicePrincipalToken from client certificate.
|
||||
func (ccc ClientCertificateConfig) MultiTenantServicePrincipalToken() (*adal.MultiTenantServicePrincipalToken, error) {
|
||||
oauthConfig, err := adal.NewMultiTenantOAuthConfig(ccc.AADEndpoint, ccc.TenantID, ccc.AuxTenants, adal.OAuthOptions{})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
certData, err := ioutil.ReadFile(ccc.CertificatePath)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to read the certificate file (%s): %v", ccc.CertificatePath, err)
|
||||
}
|
||||
certificate, rsaPrivateKey, err := adal.DecodePfxCertificateData(certData, ccc.CertificatePassword)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to decode pkcs12 certificate while creating spt: %v", err)
|
||||
}
|
||||
return adal.NewMultiTenantServicePrincipalTokenFromCertificate(oauthConfig, ccc.ClientID, certificate, rsaPrivateKey, ccc.Resource)
|
||||
}
|
||||
|
||||
// Authorizer gets an authorizer object from client certificate.
|
||||
func (ccc ClientCertificateConfig) Authorizer() (autorest.Authorizer, error) {
|
||||
spToken, err := ccc.ServicePrincipalToken()
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to get oauth token from certificate auth: %v", err)
|
||||
if len(ccc.AuxTenants) == 0 {
|
||||
spToken, err := ccc.ServicePrincipalToken()
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to get oauth token from certificate auth: %v", err)
|
||||
}
|
||||
return autorest.NewBearerAuthorizer(spToken), nil
|
||||
}
|
||||
return autorest.NewBearerAuthorizer(spToken), nil
|
||||
mtSPT, err := ccc.MultiTenantServicePrincipalToken()
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to get multitenant SPT from certificate auth: %v", err)
|
||||
}
|
||||
return autorest.NewMultiTenantServicePrincipalTokenAuthorizer(mtSPT), nil
|
||||
}
|
||||
|
||||
// DeviceFlowConfig provides the options to get a bearer authorizer using device flow authentication.
|
||||
|
|
@ -665,20 +701,6 @@ func (dfc DeviceFlowConfig) ServicePrincipalToken() (*adal.ServicePrincipalToken
|
|||
return adal.NewServicePrincipalTokenFromManualToken(*oauthConfig, dfc.ClientID, dfc.Resource, *token)
|
||||
}
|
||||
|
||||
func decodePkcs12(pkcs []byte, password string) (*x509.Certificate, *rsa.PrivateKey, error) {
|
||||
privateKey, certificate, err := pkcs12.Decode(pkcs, password)
|
||||
if err != nil {
|
||||
return nil, nil, err
|
||||
}
|
||||
|
||||
rsaPrivateKey, isRsaKey := privateKey.(*rsa.PrivateKey)
|
||||
if !isRsaKey {
|
||||
return nil, nil, fmt.Errorf("PKCS#12 certificate must contain an RSA private key")
|
||||
}
|
||||
|
||||
return certificate, rsaPrivateKey, nil
|
||||
}
|
||||
|
||||
// UsernamePasswordConfig provides the options to get a bearer authorizer from a username and a password.
|
||||
type UsernamePasswordConfig struct {
|
||||
ClientID string
|
||||
|
|
@ -715,24 +737,12 @@ type MSIConfig struct {
|
|||
|
||||
// ServicePrincipalToken creates a ServicePrincipalToken from MSI.
|
||||
func (mc MSIConfig) ServicePrincipalToken() (*adal.ServicePrincipalToken, error) {
|
||||
msiEndpoint, err := adal.GetMSIEndpoint()
|
||||
spToken, err := adal.NewServicePrincipalTokenFromManagedIdentity(mc.Resource, &adal.ManagedIdentityOptions{
|
||||
ClientID: mc.ClientID,
|
||||
})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
return nil, fmt.Errorf("failed to get oauth token from MSI: %v", err)
|
||||
}
|
||||
|
||||
var spToken *adal.ServicePrincipalToken
|
||||
if mc.ClientID == "" {
|
||||
spToken, err = adal.NewServicePrincipalTokenFromMSI(msiEndpoint, mc.Resource)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to get oauth token from MSI: %v", err)
|
||||
}
|
||||
} else {
|
||||
spToken, err = adal.NewServicePrincipalTokenFromMSIWithUserAssignedID(msiEndpoint, mc.Resource, mc.ClientID)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("failed to get oauth token from MSI for user assigned identity: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
return spToken, nil
|
||||
}
|
||||
|
||||
|
|
|
|||
11
vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.mod
generated
vendored
11
vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.mod
generated
vendored
|
|
@ -4,9 +4,10 @@ go 1.12
|
|||
|
||||
require (
|
||||
github.com/Azure/go-autorest v14.2.0+incompatible
|
||||
github.com/Azure/go-autorest/autorest v0.11.0
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.0
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.4.0
|
||||
github.com/dimchansky/utfbom v1.1.0
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9
|
||||
github.com/Azure/go-autorest/autorest v0.11.17
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.11
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.4.2
|
||||
github.com/Azure/go-autorest/logger v0.2.0
|
||||
github.com/dimchansky/utfbom v1.1.1
|
||||
golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad // indirect
|
||||
)
|
||||
|
|
|
|||
32
vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.sum
generated
vendored
32
vendor/github.com/Azure/go-autorest/autorest/azure/auth/go.sum
generated
vendored
|
|
@ -1,29 +1,37 @@
|
|||
github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
|
||||
github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
|
||||
github.com/Azure/go-autorest/autorest v0.11.0 h1:tnO41Uo+/0sxTMFY/U7aKg2abek3JOnnXcuSuba74jI=
|
||||
github.com/Azure/go-autorest/autorest v0.11.0/go.mod h1:JFgpikqFJ/MleTTxwepExTKnFUKKszPS8UavbQYUMuw=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.0 h1:SigMbuFNuKgc1xcGhaeapbh+8fgsu+GxgDRFyg7f5lM=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.0/go.mod h1:/c022QCutn2P7uY+/oQWWNcK9YU+MH96NgK+jErpbcg=
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.4.0 h1:Ml+UCrnlKD+cJmSzrZ/RDcDw86NjkRUpnFh7V5JUhzU=
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.4.0/go.mod h1:JljT387FplPzBA31vUcvsetLKF3pec5bdAxjVU4kI2s=
|
||||
github.com/Azure/go-autorest/autorest v0.11.17 h1:2zCdHwNgRH+St1J+ZMf66xI8aLr/5KMy+wWLH97zwYM=
|
||||
github.com/Azure/go-autorest/autorest v0.11.17/go.mod h1:eipySxLmqSyC5s5k1CLupqet0PSENBEDP93LQ9a8QYw=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.5 h1:Y3bBUV4rTuxenJJs41HU3qmqsb+auo+a3Lz+PlJPpL0=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.5/go.mod h1:B7KF7jKIeC9Mct5spmyCB/A8CG/sEz1vwIRGv/bbw7A=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.11 h1:L4/pmq7poLdsy41Bj1FayKvBhayuWRYkx9HU5i4Ybl0=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.11/go.mod h1:nBKAnTomx8gDtl+3ZCJv2v0KACFHWTB2drffI1B68Pk=
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.4.2 h1:dMOmEJfkLKW/7JsokJqkyoYSgmR08hi9KrhjZb+JALY=
|
||||
github.com/Azure/go-autorest/autorest/azure/cli v0.4.2/go.mod h1:7qkJkT+j6b+hIpzMOwPChJhTqS8VbsqqgULzMNRugoM=
|
||||
github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
|
||||
github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.0 h1:z20OWOSG5aCye0HEkDp6TPmP17ZcfeMxPi6HnSALa8c=
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.0/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
|
||||
github.com/Azure/go-autorest/logger v0.2.0 h1:e4RVHVZKC5p6UANLJHkM4OfR1UKZPj8Wt8Pcx+3oqrE=
|
||||
github.com/Azure/go-autorest/logger v0.2.0/go.mod h1:T9E3cAhj2VqvPOtCYAvby9aBXkZmbF5NWuPV8+WeEW8=
|
||||
github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
|
||||
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM=
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
|
||||
github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
|
||||
github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
|
||||
github.com/dimchansky/utfbom v1.1.1 h1:vV6w1AhK4VMnhBno/TPVCoK9U/LP0PkLCS9tbxHdi/U=
|
||||
github.com/dimchansky/utfbom v1.1.1/go.mod h1:SxdoEBH5qIqFocHMyGOXVAybYJdr71b1Q/j0mACtrfE=
|
||||
github.com/form3tech-oss/jwt-go v3.2.2+incompatible h1:TcekIExNqud5crz4xD2pavyTgWiPvpYe4Xau31I0PRk=
|
||||
github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
|
||||
github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
|
||||
github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9 h1:psW17arqaxU48Z5kZ0CQnkZWQJsqcURM6tKiBApRjXI=
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0 h1:hb9wdF1z5waM+dSIICn1l0DkLVDT3hqhhQsDNUmHPRE=
|
||||
golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad h1:DN0cp81fZ3njFcrLCytUHRSUkqBjfTo4Tx9RJTWs0EY=
|
||||
golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I=
|
||||
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
||||
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
|
||||
golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw=
|
||||
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
|
||||
|
|
|
|||
133
vendor/github.com/Azure/go-autorest/autorest/azure/azure.go
generated
vendored
133
vendor/github.com/Azure/go-autorest/autorest/azure/azure.go
generated
vendored
|
|
@ -37,6 +37,9 @@ const (
|
|||
// should be included in the response.
|
||||
HeaderReturnClientID = "x-ms-return-client-request-id"
|
||||
|
||||
// HeaderContentType is the type of the content in the HTTP response.
|
||||
HeaderContentType = "Content-Type"
|
||||
|
||||
// HeaderRequestID is the Azure extension header of the service generated request ID returned
|
||||
// in the response.
|
||||
HeaderRequestID = "x-ms-request-id"
|
||||
|
|
@ -89,54 +92,85 @@ func (se ServiceError) Error() string {
|
|||
|
||||
// UnmarshalJSON implements the json.Unmarshaler interface for the ServiceError type.
|
||||
func (se *ServiceError) UnmarshalJSON(b []byte) error {
|
||||
// per the OData v4 spec the details field must be an array of JSON objects.
|
||||
// unfortunately not all services adhear to the spec and just return a single
|
||||
// object instead of an array with one object. so we have to perform some
|
||||
// shenanigans to accommodate both cases.
|
||||
// http://docs.oasis-open.org/odata/odata-json-format/v4.0/os/odata-json-format-v4.0-os.html#_Toc372793091
|
||||
|
||||
type serviceError1 struct {
|
||||
type serviceErrorInternal struct {
|
||||
Code string `json:"code"`
|
||||
Message string `json:"message"`
|
||||
Target *string `json:"target"`
|
||||
Details []map[string]interface{} `json:"details"`
|
||||
InnerError map[string]interface{} `json:"innererror"`
|
||||
AdditionalInfo []map[string]interface{} `json:"additionalInfo"`
|
||||
Target *string `json:"target,omitempty"`
|
||||
AdditionalInfo []map[string]interface{} `json:"additionalInfo,omitempty"`
|
||||
// not all services conform to the OData v4 spec.
|
||||
// the following fields are where we've seen discrepancies
|
||||
|
||||
// spec calls for []map[string]interface{} but have seen map[string]interface{}
|
||||
Details interface{} `json:"details,omitempty"`
|
||||
|
||||
// spec calls for map[string]interface{} but have seen []map[string]interface{} and string
|
||||
InnerError interface{} `json:"innererror,omitempty"`
|
||||
}
|
||||
|
||||
type serviceError2 struct {
|
||||
Code string `json:"code"`
|
||||
Message string `json:"message"`
|
||||
Target *string `json:"target"`
|
||||
Details map[string]interface{} `json:"details"`
|
||||
InnerError map[string]interface{} `json:"innererror"`
|
||||
AdditionalInfo []map[string]interface{} `json:"additionalInfo"`
|
||||
sei := serviceErrorInternal{}
|
||||
if err := json.Unmarshal(b, &sei); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
se1 := serviceError1{}
|
||||
err := json.Unmarshal(b, &se1)
|
||||
if err == nil {
|
||||
se.populate(se1.Code, se1.Message, se1.Target, se1.Details, se1.InnerError, se1.AdditionalInfo)
|
||||
return nil
|
||||
// copy the fields we know to be correct
|
||||
se.AdditionalInfo = sei.AdditionalInfo
|
||||
se.Code = sei.Code
|
||||
se.Message = sei.Message
|
||||
se.Target = sei.Target
|
||||
|
||||
// converts an []interface{} to []map[string]interface{}
|
||||
arrayOfObjs := func(v interface{}) ([]map[string]interface{}, bool) {
|
||||
arrayOf, ok := v.([]interface{})
|
||||
if !ok {
|
||||
return nil, false
|
||||
}
|
||||
final := []map[string]interface{}{}
|
||||
for _, item := range arrayOf {
|
||||
as, ok := item.(map[string]interface{})
|
||||
if !ok {
|
||||
return nil, false
|
||||
}
|
||||
final = append(final, as)
|
||||
}
|
||||
return final, true
|
||||
}
|
||||
|
||||
se2 := serviceError2{}
|
||||
err = json.Unmarshal(b, &se2)
|
||||
if err == nil {
|
||||
se.populate(se2.Code, se2.Message, se2.Target, nil, se2.InnerError, se2.AdditionalInfo)
|
||||
se.Details = append(se.Details, se2.Details)
|
||||
return nil
|
||||
}
|
||||
return err
|
||||
}
|
||||
// convert the remaining fields, falling back to raw JSON if necessary
|
||||
|
||||
func (se *ServiceError) populate(code, message string, target *string, details []map[string]interface{}, inner map[string]interface{}, additional []map[string]interface{}) {
|
||||
se.Code = code
|
||||
se.Message = message
|
||||
se.Target = target
|
||||
se.Details = details
|
||||
se.InnerError = inner
|
||||
se.AdditionalInfo = additional
|
||||
if c, ok := arrayOfObjs(sei.Details); ok {
|
||||
se.Details = c
|
||||
} else if c, ok := sei.Details.(map[string]interface{}); ok {
|
||||
se.Details = []map[string]interface{}{c}
|
||||
} else if sei.Details != nil {
|
||||
// stuff into Details
|
||||
se.Details = []map[string]interface{}{
|
||||
{"raw": sei.Details},
|
||||
}
|
||||
}
|
||||
|
||||
if c, ok := sei.InnerError.(map[string]interface{}); ok {
|
||||
se.InnerError = c
|
||||
} else if c, ok := arrayOfObjs(sei.InnerError); ok {
|
||||
// if there's only one error extract it
|
||||
if len(c) == 1 {
|
||||
se.InnerError = c[0]
|
||||
} else {
|
||||
// multiple errors, stuff them into the value
|
||||
se.InnerError = map[string]interface{}{
|
||||
"multi": c,
|
||||
}
|
||||
}
|
||||
} else if c, ok := sei.InnerError.(string); ok {
|
||||
se.InnerError = map[string]interface{}{"error": c}
|
||||
} else if sei.InnerError != nil {
|
||||
// stuff into InnerError
|
||||
se.InnerError = map[string]interface{}{
|
||||
"raw": sei.InnerError,
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// RequestError describes an error response returned by Azure service.
|
||||
|
|
@ -171,6 +205,11 @@ type Resource struct {
|
|||
ResourceName string
|
||||
}
|
||||
|
||||
// String function returns a string in form of azureResourceID
|
||||
func (r Resource) String() string {
|
||||
return fmt.Sprintf("/subscriptions/%s/resourceGroups/%s/providers/%s/%s/%s", r.SubscriptionID, r.ResourceGroup, r.Provider, r.ResourceType, r.ResourceName)
|
||||
}
|
||||
|
||||
// ParseResourceID parses a resource ID into a ResourceDetails struct.
|
||||
// See https://docs.microsoft.com/en-us/azure/azure-resource-manager/resource-group-template-functions-resource#return-value-4.
|
||||
func ParseResourceID(resourceID string) (Resource, error) {
|
||||
|
|
@ -302,16 +341,30 @@ func WithErrorUnlessStatusCode(codes ...int) autorest.RespondDecorator {
|
|||
// Check if error is unwrapped ServiceError
|
||||
decoder := autorest.NewDecoder(encodedAs, bytes.NewReader(b.Bytes()))
|
||||
if err := decoder.Decode(&e.ServiceError); err != nil {
|
||||
return err
|
||||
return fmt.Errorf("autorest/azure: error response cannot be parsed: %q error: %v", b.String(), err)
|
||||
}
|
||||
|
||||
// for example, should the API return the literal value `null` as the response
|
||||
if e.ServiceError == nil {
|
||||
e.ServiceError = &ServiceError{
|
||||
Code: "Unknown",
|
||||
Message: "Unknown service error",
|
||||
Details: []map[string]interface{}{
|
||||
{
|
||||
"HttpResponse.Body": b.String(),
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
if e.ServiceError.Message == "" {
|
||||
|
||||
if e.ServiceError != nil && e.ServiceError.Message == "" {
|
||||
// if we're here it means the returned error wasn't OData v4 compliant.
|
||||
// try to unmarshal the body in hopes of getting something.
|
||||
rawBody := map[string]interface{}{}
|
||||
decoder := autorest.NewDecoder(encodedAs, bytes.NewReader(b.Bytes()))
|
||||
if err := decoder.Decode(&rawBody); err != nil {
|
||||
return err
|
||||
return fmt.Errorf("autorest/azure: error response cannot be parsed: %q error: %v", b.String(), err)
|
||||
}
|
||||
|
||||
e.ServiceError = &ServiceError{
|
||||
|
|
|
|||
2
vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.mod
generated
vendored
2
vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.mod
generated
vendored
|
|
@ -4,7 +4,7 @@ go 1.12
|
|||
|
||||
require (
|
||||
github.com/Azure/go-autorest v14.2.0+incompatible
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.0
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.5
|
||||
github.com/Azure/go-autorest/autorest/date v0.3.0
|
||||
github.com/dimchansky/utfbom v1.1.0
|
||||
github.com/mitchellh/go-homedir v1.1.0
|
||||
|
|
|
|||
15
vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.sum
generated
vendored
15
vendor/github.com/Azure/go-autorest/autorest/azure/cli/go.sum
generated
vendored
|
|
@ -1,21 +1,22 @@
|
|||
github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs=
|
||||
github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.0 h1:SigMbuFNuKgc1xcGhaeapbh+8fgsu+GxgDRFyg7f5lM=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.0/go.mod h1:/c022QCutn2P7uY+/oQWWNcK9YU+MH96NgK+jErpbcg=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.5 h1:Y3bBUV4rTuxenJJs41HU3qmqsb+auo+a3Lz+PlJPpL0=
|
||||
github.com/Azure/go-autorest/autorest/adal v0.9.5/go.mod h1:B7KF7jKIeC9Mct5spmyCB/A8CG/sEz1vwIRGv/bbw7A=
|
||||
github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw=
|
||||
github.com/Azure/go-autorest/autorest/date v0.3.0/go.mod h1:BI0uouVdmngYNUzGWeSYnokU+TrmwEsOqdt8Y6sso74=
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.0 h1:z20OWOSG5aCye0HEkDp6TPmP17ZcfeMxPi6HnSALa8c=
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.0/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.1 h1:K0laFcLE6VLTOwNgSxaGbUcLPuGXlNkbVvq4cW4nIHk=
|
||||
github.com/Azure/go-autorest/autorest/mocks v0.4.1/go.mod h1:LTp+uSrOhSkaKrUy935gNZuuIPPVsHlr9DSOxSayd+k=
|
||||
github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo=
|
||||
github.com/Azure/go-autorest/tracing v0.6.0/go.mod h1:+vhtPC754Xsa23ID7GlGsrdKBpUA79WCAKPPZVC2DeU=
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM=
|
||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ=
|
||||
github.com/dimchansky/utfbom v1.1.0 h1:FcM3g+nofKgUteL8dm/UpdRXNC9KmADgTpLKsu0TRo4=
|
||||
github.com/dimchansky/utfbom v1.1.0/go.mod h1:rO41eb7gLfo8SF1jd9F8HplJm1Fewwi4mQvIirEdv+8=
|
||||
github.com/form3tech-oss/jwt-go v3.2.2+incompatible h1:TcekIExNqud5crz4xD2pavyTgWiPvpYe4Xau31I0PRk=
|
||||
github.com/form3tech-oss/jwt-go v3.2.2+incompatible/go.mod h1:pbq4aXjuKjdthFRnoDwaVPLA+WlJuPGy+QneDUgJi2k=
|
||||
github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y=
|
||||
github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0=
|
||||
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
|
||||
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0 h1:hb9wdF1z5waM+dSIICn1l0DkLVDT3hqhhQsDNUmHPRE=
|
||||
golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto=
|
||||
golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
|
||||
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a h1:1BGLXjeY4akVXGgbC9HugT3Jv3hCI0z56oJR5vAMgBU=
|
||||
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
|
||||
|
|
|
|||
3
vendor/github.com/Azure/go-autorest/autorest/client.go
generated
vendored
3
vendor/github.com/Azure/go-autorest/autorest/client.go
generated
vendored
|
|
@ -165,7 +165,8 @@ type Client struct {
|
|||
// Setting this to zero will use the provided context to control the duration.
|
||||
PollingDuration time.Duration
|
||||
|
||||
// RetryAttempts sets the default number of retry attempts for client.
|
||||
// RetryAttempts sets the total number of times the client will attempt to make an HTTP request.
|
||||
// Set the value to 1 to disable retries. DO NOT set the value to less than 1.
|
||||
RetryAttempts int
|
||||
|
||||
// RetryDuration sets the delay duration for retries.
|
||||
|
|
|
|||
5
vendor/github.com/Azure/go-autorest/autorest/error.go
generated
vendored
5
vendor/github.com/Azure/go-autorest/autorest/error.go
generated
vendored
|
|
@ -96,3 +96,8 @@ func (e DetailedError) Error() string {
|
|||
}
|
||||
return fmt.Sprintf("%s#%s: %s: StatusCode=%d -- Original Error: %v", e.PackageType, e.Method, e.Message, e.StatusCode, e.Original)
|
||||
}
|
||||
|
||||
// Unwrap returns the original error.
|
||||
func (e DetailedError) Unwrap() error {
|
||||
return e.Original
|
||||
}
|
||||
|
|
|
|||
14
vendor/github.com/Azure/go-autorest/autorest/utility.go
generated
vendored
14
vendor/github.com/Azure/go-autorest/autorest/utility.go
generated
vendored
|
|
@ -26,8 +26,6 @@ import (
|
|||
"net/url"
|
||||
"reflect"
|
||||
"strings"
|
||||
|
||||
"github.com/Azure/go-autorest/autorest/adal"
|
||||
)
|
||||
|
||||
// EncodedAs is a series of constants specifying various data encodings
|
||||
|
|
@ -207,18 +205,6 @@ func ChangeToGet(req *http.Request) *http.Request {
|
|||
return req
|
||||
}
|
||||
|
||||
// IsTokenRefreshError returns true if the specified error implements the TokenRefreshError
|
||||
// interface. If err is a DetailedError it will walk the chain of Original errors.
|
||||
func IsTokenRefreshError(err error) bool {
|
||||
if _, ok := err.(adal.TokenRefreshError); ok {
|
||||
return true
|
||||
}
|
||||
if de, ok := err.(DetailedError); ok {
|
||||
return IsTokenRefreshError(de.Original)
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
// IsTemporaryNetworkError returns true if the specified error is a temporary network error or false
|
||||
// if it's not. If the error doesn't implement the net.Error interface the return value is true.
|
||||
func IsTemporaryNetworkError(err error) bool {
|
||||
|
|
|
|||
29
vendor/github.com/Azure/go-autorest/autorest/utility_1.13.go
generated
vendored
Normal file
29
vendor/github.com/Azure/go-autorest/autorest/utility_1.13.go
generated
vendored
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
// +build go1.13
|
||||
|
||||
// Copyright 2017 Microsoft Corporation
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package autorest
|
||||
|
||||
import (
|
||||
"errors"
|
||||
|
||||
"github.com/Azure/go-autorest/autorest/adal"
|
||||
)
|
||||
|
||||
// IsTokenRefreshError returns true if the specified error implements the TokenRefreshError interface.
|
||||
func IsTokenRefreshError(err error) bool {
|
||||
var tre adal.TokenRefreshError
|
||||
return errors.As(err, &tre)
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue