Conversation
dominikschubert
approved these changes
Mar 28, 2023
Member
dominikschubert
left a comment
There was a problem hiding this comment.
LGTM! 🚀
I like the new pattern. One issue I'm starting to see a bit is the manual specification of the service principal as a string literal. Maybe it would make sense to keep a list of all current AWS service principals and use an enum for these. Sometimes they really aren't as intuitive on AWS as they should be 😬 (e.g. states for stepfunctions)
f9a80f1 to
0c15734
Compare
0c15734 to
d936065
Compare
alexrashed
approved these changes
Mar 29, 2023
Member
alexrashed
left a comment
There was a problem hiding this comment.
The package installer API change looks good to me! Thanks for tackling this! 🚀
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
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.
Motivation
Changes
connect_to.with_assumed_role
A new method for the aws client factories.
Usage:
This call will assume the given role as the given service, and return a service level client factory, where various clients can be created using the returned credentials.
The assume role call will be done immediately, the other clients instantiated lazily as they are requested.
Client migrations
Several important inter-service calls between lambda, sqs and sns are migrated to the new clients.
This migration is ongoing, and not complete yet.
During this, I silently killed
SYNCHRONOUS_SNS_EVENTS, as it is scheduled to remove with 2.0 anyway.Fix check if installed check outside of installer lock
This one is a tricky one.
Basically, we are circumventing the lock if the
is_installed()method already returns true. But, the default is just checking if a directory is created, which can be true during the installation as well. Moving this entirely behind the lock avoids one thread installing while the other one is checking, and therefore avoids starting incompletely installed dependencies.This seems to be the root cause for the failing
test_kinesis_firehose_elasticsearch_s3_backuptest, which is so annoying. It is basically trying to start elasticsearch while we are still installing plugins -> class loading failure.