change github.com/aws/aws-sdk-go to be the same revision in kubernetes

This commit is contained in:
Jingfang Liu
2018-10-16 09:34:22 -07:00
parent e0958159f3
commit c6a78cee92
462 changed files with 20605 additions and 85780 deletions

View File

@@ -49,7 +49,7 @@ func BenchmarkEC2QueryBuild_Complex_ec2AuthorizeSecurityGroupEgress(b *testing.B
IpProtocol: aws.String("String"),
SourceSecurityGroupName: aws.String("String"),
SourceSecurityGroupOwnerId: aws.String("String"),
ToPort: aws.Int64(1),
ToPort: aws.Int64(1),
}
benchEC2QueryBuild(b, "AuthorizeSecurityGroupEgress", params)

View File

@@ -651,12 +651,36 @@ func (c *InputService4ProtocolTest) InputService4TestCaseOperation1WithContext(c
type InputService4TestShapeInputService4TestCaseOperation1Input struct {
_ struct{} `type:"structure"`
ListArg []*string `type:"list"`
ListBools []*bool `type:"list"`
ListFloats []*float64 `type:"list"`
ListIntegers []*int64 `type:"list"`
ListStrings []*string `type:"list"`
}
// SetListArg sets the ListArg field's value.
func (s *InputService4TestShapeInputService4TestCaseOperation1Input) SetListArg(v []*string) *InputService4TestShapeInputService4TestCaseOperation1Input {
s.ListArg = v
// SetListBools sets the ListBools field's value.
func (s *InputService4TestShapeInputService4TestCaseOperation1Input) SetListBools(v []*bool) *InputService4TestShapeInputService4TestCaseOperation1Input {
s.ListBools = v
return s
}
// SetListFloats sets the ListFloats field's value.
func (s *InputService4TestShapeInputService4TestCaseOperation1Input) SetListFloats(v []*float64) *InputService4TestShapeInputService4TestCaseOperation1Input {
s.ListFloats = v
return s
}
// SetListIntegers sets the ListIntegers field's value.
func (s *InputService4TestShapeInputService4TestCaseOperation1Input) SetListIntegers(v []*int64) *InputService4TestShapeInputService4TestCaseOperation1Input {
s.ListIntegers = v
return s
}
// SetListStrings sets the ListStrings field's value.
func (s *InputService4TestShapeInputService4TestCaseOperation1Input) SetListStrings(v []*string) *InputService4TestShapeInputService4TestCaseOperation1Input {
s.ListStrings = v
return s
}
@@ -1236,11 +1260,7 @@ func (c *InputService8ProtocolTest) InputService8TestCaseOperation1WithContext(c
type InputService8TestShapeInputService8TestCaseOperation1Input struct {
_ struct{} `type:"structure"`
TimeArg *time.Time `type:"timestamp"`
TimeCustom *time.Time `type:"timestamp" timestampFormat:"unixTimestamp"`
TimeFormat *time.Time `type:"timestamp" timestampFormat:"unixTimestamp"`
TimeArg *time.Time `type:"timestamp" timestampFormat:"iso8601"`
}
// SetTimeArg sets the TimeArg field's value.
@@ -1249,18 +1269,6 @@ func (s *InputService8TestShapeInputService8TestCaseOperation1Input) SetTimeArg(
return s
}
// SetTimeCustom sets the TimeCustom field's value.
func (s *InputService8TestShapeInputService8TestCaseOperation1Input) SetTimeCustom(v time.Time) *InputService8TestShapeInputService8TestCaseOperation1Input {
s.TimeCustom = &v
return s
}
// SetTimeFormat sets the TimeFormat field's value.
func (s *InputService8TestShapeInputService8TestCaseOperation1Input) SetTimeFormat(v time.Time) *InputService8TestShapeInputService8TestCaseOperation1Input {
s.TimeFormat = &v
return s
}
type InputService8TestShapeInputService8TestCaseOperation1Output struct {
_ struct{} `type:"structure"`
}
@@ -1349,14 +1357,14 @@ const opInputService9TestCaseOperation1 = "OperationName"
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
func (c *InputService9ProtocolTest) InputService9TestCaseOperation1Request(input *InputService9TestShapeInputService9TestCaseOperation1Input) (req *request.Request, output *InputService9TestShapeInputService9TestCaseOperation1Output) {
func (c *InputService9ProtocolTest) InputService9TestCaseOperation1Request(input *InputService9TestShapeInputService9TestCaseOperation2Input) (req *request.Request, output *InputService9TestShapeInputService9TestCaseOperation1Output) {
op := &request.Operation{
Name: opInputService9TestCaseOperation1,
HTTPPath: "/",
}
if input == nil {
input = &InputService9TestShapeInputService9TestCaseOperation1Input{}
input = &InputService9TestShapeInputService9TestCaseOperation2Input{}
}
output = &InputService9TestShapeInputService9TestCaseOperation1Output{}
@@ -1374,7 +1382,7 @@ func (c *InputService9ProtocolTest) InputService9TestCaseOperation1Request(input
//
// See the AWS API reference guide for 's
// API operation InputService9TestCaseOperation1 for usage and error information.
func (c *InputService9ProtocolTest) InputService9TestCaseOperation1(input *InputService9TestShapeInputService9TestCaseOperation1Input) (*InputService9TestShapeInputService9TestCaseOperation1Output, error) {
func (c *InputService9ProtocolTest) InputService9TestCaseOperation1(input *InputService9TestShapeInputService9TestCaseOperation2Input) (*InputService9TestShapeInputService9TestCaseOperation1Output, error) {
req, out := c.InputService9TestCaseOperation1Request(input)
return out, req.Send()
}
@@ -1388,7 +1396,7 @@ func (c *InputService9ProtocolTest) InputService9TestCaseOperation1(input *Input
// the context is nil a panic will occur. In the future the SDK may create
// sub-contexts for http.Requests. See https://golang.org/pkg/context/
// for more information on using Contexts.
func (c *InputService9ProtocolTest) InputService9TestCaseOperation1WithContext(ctx aws.Context, input *InputService9TestShapeInputService9TestCaseOperation1Input, opts ...request.Option) (*InputService9TestShapeInputService9TestCaseOperation1Output, error) {
func (c *InputService9ProtocolTest) InputService9TestCaseOperation1WithContext(ctx aws.Context, input *InputService9TestShapeInputService9TestCaseOperation2Input, opts ...request.Option) (*InputService9TestShapeInputService9TestCaseOperation1Output, error) {
req, out := c.InputService9TestCaseOperation1Request(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
@@ -1465,18 +1473,6 @@ func (c *InputService9ProtocolTest) InputService9TestCaseOperation2WithContext(c
return out, req.Send()
}
type InputService9TestShapeInputService9TestCaseOperation1Input struct {
_ struct{} `type:"structure"`
Token *string `type:"string" idempotencyToken:"true"`
}
// SetToken sets the Token field's value.
func (s *InputService9TestShapeInputService9TestCaseOperation1Input) SetToken(v string) *InputService9TestShapeInputService9TestCaseOperation1Input {
s.Token = &v
return s
}
type InputService9TestShapeInputService9TestCaseOperation1Output struct {
_ struct{} `type:"structure"`
}
@@ -1581,14 +1577,14 @@ const opInputService10TestCaseOperation1 = "OperationName"
// if err == nil { // resp is now filled
// fmt.Println(resp)
// }
func (c *InputService10ProtocolTest) InputService10TestCaseOperation1Request(input *InputService10TestShapeInputService10TestCaseOperation1Input) (req *request.Request, output *InputService10TestShapeInputService10TestCaseOperation1Output) {
func (c *InputService10ProtocolTest) InputService10TestCaseOperation1Request(input *InputService10TestShapeInputService10TestCaseOperation2Input) (req *request.Request, output *InputService10TestShapeInputService10TestCaseOperation1Output) {
op := &request.Operation{
Name: opInputService10TestCaseOperation1,
HTTPPath: "/",
}
if input == nil {
input = &InputService10TestShapeInputService10TestCaseOperation1Input{}
input = &InputService10TestShapeInputService10TestCaseOperation2Input{}
}
output = &InputService10TestShapeInputService10TestCaseOperation1Output{}
@@ -1606,7 +1602,7 @@ func (c *InputService10ProtocolTest) InputService10TestCaseOperation1Request(inp
//
// See the AWS API reference guide for 's
// API operation InputService10TestCaseOperation1 for usage and error information.
func (c *InputService10ProtocolTest) InputService10TestCaseOperation1(input *InputService10TestShapeInputService10TestCaseOperation1Input) (*InputService10TestShapeInputService10TestCaseOperation1Output, error) {
func (c *InputService10ProtocolTest) InputService10TestCaseOperation1(input *InputService10TestShapeInputService10TestCaseOperation2Input) (*InputService10TestShapeInputService10TestCaseOperation1Output, error) {
req, out := c.InputService10TestCaseOperation1Request(input)
return out, req.Send()
}
@@ -1620,7 +1616,7 @@ func (c *InputService10ProtocolTest) InputService10TestCaseOperation1(input *Inp
// the context is nil a panic will occur. In the future the SDK may create
// sub-contexts for http.Requests. See https://golang.org/pkg/context/
// for more information on using Contexts.
func (c *InputService10ProtocolTest) InputService10TestCaseOperation1WithContext(ctx aws.Context, input *InputService10TestShapeInputService10TestCaseOperation1Input, opts ...request.Option) (*InputService10TestShapeInputService10TestCaseOperation1Output, error) {
func (c *InputService10ProtocolTest) InputService10TestCaseOperation1WithContext(ctx aws.Context, input *InputService10TestShapeInputService10TestCaseOperation2Input, opts ...request.Option) (*InputService10TestShapeInputService10TestCaseOperation1Output, error) {
req, out := c.InputService10TestCaseOperation1Request(input)
req.SetContext(ctx)
req.ApplyOptions(opts...)
@@ -1697,26 +1693,6 @@ func (c *InputService10ProtocolTest) InputService10TestCaseOperation2WithContext
return out, req.Send()
}
type InputService10TestShapeInputService10TestCaseOperation1Input struct {
_ struct{} `type:"structure"`
FooEnum *string `type:"string" enum:"InputService10TestShapeEnumType"`
ListEnums []*string `type:"list"`
}
// SetFooEnum sets the FooEnum field's value.
func (s *InputService10TestShapeInputService10TestCaseOperation1Input) SetFooEnum(v string) *InputService10TestShapeInputService10TestCaseOperation1Input {
s.FooEnum = &v
return s
}
// SetListEnums sets the ListEnums field's value.
func (s *InputService10TestShapeInputService10TestCaseOperation1Input) SetListEnums(v []*string) *InputService10TestShapeInputService10TestCaseOperation1Input {
s.ListEnums = v
return s
}
type InputService10TestShapeInputService10TestCaseOperation1Output struct {
_ struct{} `type:"structure"`
}
@@ -1849,7 +1825,22 @@ func TestInputService3ProtocolTestNestedStructureMembersCase1(t *testing.T) {
func TestInputService4ProtocolTestListTypesCase1(t *testing.T) {
svc := NewInputService4ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
input := &InputService4TestShapeInputService4TestCaseOperation1Input{
ListArg: []*string{
ListBools: []*bool{
aws.Bool(true),
aws.Bool(false),
aws.Bool(false),
},
ListFloats: []*float64{
aws.Float64(1.1),
aws.Float64(2.718),
aws.Float64(3.14),
},
ListIntegers: []*int64{
aws.Int64(0),
aws.Int64(1),
aws.Int64(2),
},
ListStrings: []*string{
aws.String("foo"),
aws.String("bar"),
aws.String("baz"),
@@ -1869,7 +1860,7 @@ func TestInputService4ProtocolTestListTypesCase1(t *testing.T) {
t.Errorf("expect body not to be nil")
}
body, _ := ioutil.ReadAll(r.Body)
awstesting.AssertQuery(t, `Action=OperationName&ListArg.1=foo&ListArg.2=bar&ListArg.3=baz&Version=2014-01-01`, util.Trim(string(body)))
awstesting.AssertQuery(t, `Action=OperationName&ListBools.1=true&ListBools.2=false&ListBools.3=false&ListFloats.1=1.1&ListFloats.2=2.718&ListFloats.3=3.14&ListIntegers.1=0&ListIntegers.2=1&ListIntegers.3=2&ListStrings.1=foo&ListStrings.2=bar&ListStrings.3=baz&Version=2014-01-01`, util.Trim(string(body)))
// assert URL
awstesting.AssertURL(t, "https://test/", r.URL.String())
@@ -1973,9 +1964,7 @@ func TestInputService7ProtocolTestBase64EncodedBlobsCase1(t *testing.T) {
func TestInputService8ProtocolTestTimestampValuesCase1(t *testing.T) {
svc := NewInputService8ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
input := &InputService8TestShapeInputService8TestCaseOperation1Input{
TimeArg: aws.Time(time.Unix(1422172800, 0)),
TimeCustom: aws.Time(time.Unix(1422172800, 0)),
TimeFormat: aws.Time(time.Unix(1422172800, 0)),
TimeArg: aws.Time(time.Unix(1422172800, 0)),
}
req, _ := svc.InputService8TestCaseOperation1Request(input)
r := req.HTTPRequest
@@ -1991,7 +1980,7 @@ func TestInputService8ProtocolTestTimestampValuesCase1(t *testing.T) {
t.Errorf("expect body not to be nil")
}
body, _ := ioutil.ReadAll(r.Body)
awstesting.AssertQuery(t, `Action=OperationName&TimeArg=2015-01-25T08%3A00%3A00Z&TimeCustom=1422172800&TimeFormat=1422172800&Version=2014-01-01`, util.Trim(string(body)))
awstesting.AssertQuery(t, `Action=OperationName&TimeArg=2015-01-25T08%3A00%3A00Z&Version=2014-01-01`, util.Trim(string(body)))
// assert URL
awstesting.AssertURL(t, "https://test/", r.URL.String())
@@ -2002,7 +1991,7 @@ func TestInputService8ProtocolTestTimestampValuesCase1(t *testing.T) {
func TestInputService9ProtocolTestIdempotencyTokenAutoFillCase1(t *testing.T) {
svc := NewInputService9ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
input := &InputService9TestShapeInputService9TestCaseOperation1Input{
input := &InputService9TestShapeInputService9TestCaseOperation2Input{
Token: aws.String("abc123"),
}
req, _ := svc.InputService9TestCaseOperation1Request(input)
@@ -2056,7 +2045,7 @@ func TestInputService9ProtocolTestIdempotencyTokenAutoFillCase2(t *testing.T) {
func TestInputService10ProtocolTestEnumCase1(t *testing.T) {
svc := NewInputService10ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
input := &InputService10TestShapeInputService10TestCaseOperation1Input{
input := &InputService10TestShapeInputService10TestCaseOperation2Input{
ListEnums: []*string{
aws.String("foo"),
aws.String(""),

View File

@@ -1544,58 +1544,30 @@ type OutputService10TestShapeOutputService10TestCaseOperation1Input struct {
type OutputService10TestShapeOutputService10TestCaseOperation1Output struct {
_ struct{} `type:"structure"`
StructMember *OutputService10TestShapeTimeContainer `type:"structure"`
FooEnum *string `type:"string" enum:"OutputService10TestShapeEC2EnumType"`
TimeArg *time.Time `type:"timestamp"`
TimeCustom *time.Time `type:"timestamp" timestampFormat:"rfc822"`
TimeFormat *time.Time `type:"timestamp" timestampFormat:"unixTimestamp"`
ListEnums []*string `type:"list"`
}
// SetStructMember sets the StructMember field's value.
func (s *OutputService10TestShapeOutputService10TestCaseOperation1Output) SetStructMember(v *OutputService10TestShapeTimeContainer) *OutputService10TestShapeOutputService10TestCaseOperation1Output {
s.StructMember = v
// SetFooEnum sets the FooEnum field's value.
func (s *OutputService10TestShapeOutputService10TestCaseOperation1Output) SetFooEnum(v string) *OutputService10TestShapeOutputService10TestCaseOperation1Output {
s.FooEnum = &v
return s
}
// SetTimeArg sets the TimeArg field's value.
func (s *OutputService10TestShapeOutputService10TestCaseOperation1Output) SetTimeArg(v time.Time) *OutputService10TestShapeOutputService10TestCaseOperation1Output {
s.TimeArg = &v
// SetListEnums sets the ListEnums field's value.
func (s *OutputService10TestShapeOutputService10TestCaseOperation1Output) SetListEnums(v []*string) *OutputService10TestShapeOutputService10TestCaseOperation1Output {
s.ListEnums = v
return s
}
// SetTimeCustom sets the TimeCustom field's value.
func (s *OutputService10TestShapeOutputService10TestCaseOperation1Output) SetTimeCustom(v time.Time) *OutputService10TestShapeOutputService10TestCaseOperation1Output {
s.TimeCustom = &v
return s
}
const (
// EC2EnumTypeFoo is a OutputService10TestShapeEC2EnumType enum value
EC2EnumTypeFoo = "foo"
// SetTimeFormat sets the TimeFormat field's value.
func (s *OutputService10TestShapeOutputService10TestCaseOperation1Output) SetTimeFormat(v time.Time) *OutputService10TestShapeOutputService10TestCaseOperation1Output {
s.TimeFormat = &v
return s
}
type OutputService10TestShapeTimeContainer struct {
_ struct{} `type:"structure"`
Bar *time.Time `locationName:"bar" type:"timestamp" timestampFormat:"unixTimestamp"`
Foo *time.Time `locationName:"foo" type:"timestamp"`
}
// SetBar sets the Bar field's value.
func (s *OutputService10TestShapeTimeContainer) SetBar(v time.Time) *OutputService10TestShapeTimeContainer {
s.Bar = &v
return s
}
// SetFoo sets the Foo field's value.
func (s *OutputService10TestShapeTimeContainer) SetFoo(v time.Time) *OutputService10TestShapeTimeContainer {
s.Foo = &v
return s
}
// EC2EnumTypeBar is a OutputService10TestShapeEC2EnumType enum value
EC2EnumTypeBar = "bar"
)
//
// Tests begin here
@@ -1874,10 +1846,10 @@ func TestOutputService9ProtocolTestEmptyStringCase1(t *testing.T) {
}
func TestOutputService10ProtocolTestTimestampMembersCase1(t *testing.T) {
func TestOutputService10ProtocolTestEnumOutputCase1(t *testing.T) {
svc := NewOutputService10ProtocolTest(unit.Session, &aws.Config{Endpoint: aws.String("https://test")})
buf := bytes.NewReader([]byte("<OperationNameResponse><StructMember><foo>2014-04-29T18:30:38Z</foo><bar>1398796238</bar></StructMember><TimeArg>2014-04-29T18:30:38Z</TimeArg><TimeCustom>Tue, 29 Apr 2014 18:30:38 GMT</TimeCustom><TimeFormat>1398796238</TimeFormat><RequestId>requestid</RequestId></OperationNameResponse>"))
buf := bytes.NewReader([]byte("<OperationNameResponse><FooEnum>foo</FooEnum><ListEnums><member>foo</member><member>bar</member></ListEnums></OperationNameResponse>"))
req, out := svc.OutputService10TestCaseOperation1Request(nil)
req.HTTPResponse = &http.Response{StatusCode: 200, Body: ioutil.NopCloser(buf), Header: http.Header{}}
@@ -1894,19 +1866,13 @@ func TestOutputService10ProtocolTestTimestampMembersCase1(t *testing.T) {
if out == nil {
t.Errorf("expect not to be nil")
}
if e, a := time.Unix(1.398796238e+09, 0).UTC().String(), out.StructMember.Bar.UTC().String(); e != a {
if e, a := "foo", *out.FooEnum; e != a {
t.Errorf("expect %v, got %v", e, a)
}
if e, a := time.Unix(1.398796238e+09, 0).UTC().String(), out.StructMember.Foo.UTC().String(); e != a {
if e, a := "foo", *out.ListEnums[0]; e != a {
t.Errorf("expect %v, got %v", e, a)
}
if e, a := time.Unix(1.398796238e+09, 0).UTC().String(), out.TimeArg.UTC().String(); e != a {
t.Errorf("expect %v, got %v", e, a)
}
if e, a := time.Unix(1.398796238e+09, 0).UTC().String(), out.TimeCustom.UTC().String(); e != a {
t.Errorf("expect %v, got %v", e, a)
}
if e, a := time.Unix(1.398796238e+09, 0).UTC().String(), out.TimeFormat.UTC().String(); e != a {
if e, a := "bar", *out.ListEnums[1]; e != a {
t.Errorf("expect %v, got %v", e, a)
}