New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: allow more than 1000 state files #223
Conversation
Upgrade to the newest AWS API For ListObjectsV2 and then also add the ability to have more than 1000 state files
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
The AWS tests are actually failing. @hbollon do you see why? |
Hi guys! from type s3Mock struct {
s3iface.S3API
}
func (s *s3Mock) ListObjects(_ *s3.ListObjectsInput) (*s3.ListObjectsOutput, error) {
return &s3.ListObjectsOutput{Contents: []*s3.Object{{Key: aws.String("test.tfstate")}}}, nil
}
func (s *s3Mock) ListObjectVersions(_ *s3.ListObjectVersionsInput) (*s3.ListObjectVersionsOutput, error) {
return &s3.ListObjectVersionsOutput{
Versions: []*s3.ObjectVersion{
{Key: aws.String("testId"), VersionId: aws.String("test"), LastModified: aws.Time(time.Now())},
{Key: aws.String("testId2"), VersionId: aws.String("test2"), LastModified: aws.Time(time.Now())},
},
}, nil
}
func (s *s3Mock) GetObjectWithContext(_ aws.Context, _ *s3.GetObjectInput, _ ...request.Option) (*s3.GetObjectOutput, error) {
return &s3.GetObjectOutput{
Body: ioutil.NopCloser(bytes.NewReader([]byte(`{"Version": 4, "Serial": 3, "TerraformVersion": "0.12.0"}`))),
}, nil
} So with the AWS API upgrade and the use of |
@hbollon Sorry I didn't update the aws_test.go, I see how to do it, but it might be a bit before I can complete it. |
Fixing the test case
@bmpandrade I updated the PR with an updated version of aws_test.go. I think the workflow just needs to be rerun again to verify that everything is working as expected. |
@lorodoes , I took a look at the worfklows, but none allow for re-run, it requires explicit approval from maintainers to run them again. |
Hi guys, |
OK for me @hbollon |
Upgrade to the newest AWS API For ListObjectsV2 and then also add the ability to have more than 1000 state files