-
Notifications
You must be signed in to change notification settings - Fork 547
fix(aws): Remove Resource Specific Parallelization For S3 to use only the SDK parallelization #10255
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
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bbernays
commented
Apr 21, 2023
| } | ||
| return err | ||
| } | ||
| } |
Collaborator
Author
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.
this function moved to bucket_grants.go
bbernays
commented
Apr 21, 2023
Comment on lines
-56
to
-80
| var wg sync.WaitGroup | ||
| buckets := make(chan types.Bucket) | ||
| errs := make(chan error) | ||
| for i := 0; i < fetchS3BucketsPoolSize; i++ { | ||
| wg.Add(1) | ||
| go fetchS3BucketsWorker(ctx, meta, buckets, errs, res, &wg) | ||
| } | ||
| go func() { | ||
| defer close(buckets) | ||
| for _, bucket := range response.Buckets { | ||
| select { | ||
| case <-ctx.Done(): | ||
| return | ||
| case buckets <- bucket: | ||
| } | ||
| } | ||
| }() | ||
| done := make(chan struct{}) | ||
| go func() { | ||
| for err = range errs { | ||
| cl.Logger().Err(err).Msg("failed to fetch s3 bucket") | ||
| } | ||
| close(done) | ||
| }() | ||
| wg.Wait() |
Collaborator
Author
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.
Using Resolver and PreResourceResolver instead of custom channels and go routines
hermanschaaf
approved these changes
Apr 21, 2023
kodiakhq bot
pushed a commit
that referenced
this pull request
Apr 25, 2023
🤖 I have created a release *beep* *boop* --- ## [17.0.0](plugins-source-aws-v16.3.0...plugins-source-aws-v17.0.0) (2023-04-25) ### ⚠ BREAKING CHANGES * **aws:** Move EC2 EBS Snapshot `attributes` column to standalone table ([#10247](#10247)) * **aws-resources:** Query issue on `aws_cloudwatchlogs_log_group_data_protection_policies` ([#10243](#10243)) * **aws:** Fix Primary Key for `aws_directconnect_gateways` ([#10233](#10233)) ### Features * **aws-services:** Support newly added regions ([#10289](#10289)) ([dd6c034](dd6c034)) * **aws:** Store Spec in Client ([#10286](#10286)) ([2561d5c](2561d5c)) ### Bug Fixes * **aws-docs:** Policy docs should include tables used in views ([#10250](#10250)) ([08c4d91](08c4d91)) * **aws-resources:** Query issue on `aws_cloudwatchlogs_log_group_data_protection_policies` ([#10243](#10243)) ([4e9bb39](4e9bb39)), closes [#10216](#10216) * **aws:** Fix Primary Key for `aws_directconnect_gateways` ([#10233](#10233)) ([fc9094f](fc9094f)) * **aws:** Move EC2 EBS Snapshot `attributes` column to standalone table ([#10247](#10247)) ([bdb421b](bdb421b)) * **aws:** Remove Resource Specific Parallelization For S3 to use only the SDK parallelization ([#10255](#10255)) ([07c7edb](07c7edb)) * **deps:** Update module github.com/aws/aws-sdk-go-v2/feature/s3/manager to v1.11.63 ([#10267](#10267)) ([7a8a4c7](7a8a4c7)) * **deps:** Update module github.com/aws/aws-sdk-go-v2/service/amp to v1.16.8 ([#10268](#10268)) ([d4ec528](d4ec528)) * **deps:** Update module github.com/aws/aws-sdk-go-v2/service/amplify to v1.13.8 ([#10269](#10269)) ([8d5d163](8d5d163)) * **deps:** Update module github.com/aws/aws-sdk-go-v2/service/apigateway to v1.16.9 ([#10270](#10270)) ([dc8fd93](dc8fd93)) * **deps:** Update module github.com/aws/aws-sdk-go-v2/service/apigatewayv2 to v1.13.9 ([#10271](#10271)) ([e3e3f0a](e3e3f0a)) * **deps:** Update module github.com/aws/aws-sdk-go-v2/service/autoscalingplans to v1.13.8 ([#10272](#10272)) ([cd7bcee](cd7bcee)) * **deps:** Update module github.com/cloudquery/plugin-sdk/v2 to v2.3.8 ([#10213](#10213)) ([f358666](f358666)) * **deps:** Update module github.com/cloudquery/plugin-sdk/v2 to v2.4.0 ([#10278](#10278)) ([a0a713e](a0a713e)) * **policies-cloudtrail:** Add region criteria to inner join ([#10246](#10246)) ([c9fd369](c9fd369)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please).
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Was trying to look into an issue with S3 ACL Pks and removed this refactor from my investigation code. Removed all custom/resource specific parallelization to rely solely on the SDK provided parallelization