diff --git a/go.mod b/go.mod index 2a000bc380..8f08dcc737 100644 --- a/go.mod +++ b/go.mod @@ -4,7 +4,7 @@ go 1.15 require ( github.com/aws/aws-lambda-go v1.19.1 - github.com/aws/aws-sdk-go v1.34.18 + github.com/aws/aws-sdk-go v1.34.23 github.com/cenkalti/backoff/v4 v4.0.2 github.com/fatih/structtag v1.2.0 github.com/go-openapi/errors v0.19.6 diff --git a/go.sum b/go.sum index bd2ba262fa..c7772e8efd 100644 --- a/go.sum +++ b/go.sum @@ -12,8 +12,8 @@ github.com/asaskevich/govalidator v0.0.0-20200428143746-21a406dcc535 h1:4daAzAu0 github.com/asaskevich/govalidator v0.0.0-20200428143746-21a406dcc535/go.mod h1:oGkLhpf+kjZl6xBf758TQhh5XrAeiJv/7FRz/2spLIg= github.com/aws/aws-lambda-go v1.19.1 h1:5iUHbIZ2sG6Yq/J1IN3sWm3+vAB1CWwhI21NffLNuNI= github.com/aws/aws-lambda-go v1.19.1/go.mod h1:jJmlefzPfGnckuHdXX7/80O3BvUUi12XOkbv4w9SGLU= -github.com/aws/aws-sdk-go v1.34.18 h1:Mo/Clq3u1dQFzpg8YQqBii8m+Vl3fWIfHi6kXs5wpuM= -github.com/aws/aws-sdk-go v1.34.18/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= +github.com/aws/aws-sdk-go v1.34.23 h1:ZUqMEJRjQUpZNA/OOhFmjWtWxD3n8XbOrC5rC1djl5s= +github.com/aws/aws-sdk-go v1.34.23/go.mod h1:5zCpMtNQVjRREroY7sYe8lOMRSxkhG6MZveU8YkpAk0= github.com/cenkalti/backoff/v4 v4.0.2 h1:JIufpQLbh4DkbQoii76ItQIUFzevQSqOLZca4eamEDs= github.com/cenkalti/backoff/v4 v4.0.2/go.mod h1:eEew/i+1Q6OrCDZh3WiXYv3+nJwBASZ8Bog/87DQnVg= github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= diff --git a/internal/log_analysis/awsglue/table_metadata.go b/internal/log_analysis/awsglue/table_metadata.go index d58aacd5f5..8ca5329958 100644 --- a/internal/log_analysis/awsglue/table_metadata.go +++ b/internal/log_analysis/awsglue/table_metadata.go @@ -210,6 +210,23 @@ func (gm *GlueTableMetadata) CreateOrUpdateTable(glueClient glueiface.GlueAPI, b createTableInput := &glue.CreateTableInput{ DatabaseName: &gm.databaseName, TableInput: tableInput, + PartitionIndexes: []*glue.PartitionIndex{ + { + IndexName: aws.String("month_idx"), + Keys: []*string{ + aws.String("year"), + aws.String("month"), + }, + }, + { + IndexName: aws.String("day_idx"), + Keys: []*string{ + aws.String("year"), + aws.String("month"), + aws.String("day"), + }, + }, + }, } _, err := glueClient.CreateTable(createTableInput) if err != nil {