-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
add support for multiple regions #21065
add support for multiple regions #21065
Conversation
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
1 similar comment
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
x-pack/functionbeat/config/config.go
Outdated
@@ -16,7 +16,7 @@ import ( | |||
) | |||
|
|||
var ( | |||
functionPattern = "^[A-Za-z][A-Za-z0-9\\-]{0,139}$" | |||
functionPattern = "^[A-Za-z][A-Za-z0-9\\-]{0,29}$" |
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.
I have added this change because, as we're appending the function name to the role name, the role name would exceed AWS's limit of 64 characters. I can change the implementation based on the feedback from the maintainers. Other alternative is to add a conditional for creating the role.
Either ways, the 140 character limit for the function name needs to be reduced as we're already appending the function name in the role name.
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 is a good point. However, I am bit worried if we change the role name, we might forgot to change this number. Do you mind refactoring it so the length of the pattern depends on the role name prefix? Or at least add a comment to the code about why the max length is 29?
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.
I was off by one on the limit, it can be 30 instead of 29. I've updated the regex, tests and added a comment on how I got to the number 30.
2db857c
to
3024ba7
Compare
Pinging @elastic/integrations (Team:Integrations) |
Pinging @elastic/integrations-services (Team:Services) |
@ph thank you for self-requesting review, let me know if the changes makes sense, happy to discuss alternatives too! |
@kvch can you give a second pair of eye on this. I think this looks ok, I am a bit worried about the new limit and the impact on existing deployment? |
jenkins run tests |
Thank you! |
(cherry picked from commit ee95f3d)
What does this PR do?
This PR adds support for deploying functionbeat in multiple regions.
Why is it important?
Teams can deploy the functionbeat in multiple regions and
Checklist
CHANGELOG.next.asciidoc
orCHANGELOG-developer.next.asciidoc
.Author's Checklist
How to test this PR locally
Related issues
Use cases
Screenshots
Logs