Skip to content
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

refactor: add delayed startup of Controllers #384

Merged
merged 2 commits into from
Jun 9, 2023

Conversation

chrisgacsal
Copy link
Contributor

Description

Make Orchestrator to wait for a predefined time period before starting each Controller to avoid them hitting the API at the same time and allow one Controller to pick up an event generated by the other without waiting until the next polling cycle.

Type of Change

[ ] Bug Fix
[ ] New Feature
[ ] Breaking Change
[x] Refactor
[ ] Documentation
[ ] Other (please describe)

Checklist

  • I have read the contributing guidelines
  • Existing issues have been referenced (where applicable)
  • I have verified this change is not present in other open pull requests
  • Functionality is documented
  • All code style checks pass
  • New code contribution is covered by automated tests
  • All new and existing tests pass

@chrisgacsal chrisgacsal requested a review from a team as a code owner June 9, 2023 11:17
@chrisgacsal chrisgacsal self-assigned this Jun 9, 2023
@chrisgacsal chrisgacsal added the enhancement New feature or request label Jun 9, 2023
Make Orchestrator to wait for a predefined time period before starting
each Controller to avoid them hitting the API at the same time and allow
one Controller to pick up an event generated by the other without waiting
until the next polling cycle.
ghost
ghost previously approved these changes Jun 9, 2023
@chrisgacsal chrisgacsal requested a review from a user June 9, 2023 12:31
@chrisgacsal chrisgacsal added this pull request to the merge queue Jun 9, 2023
Merged via the queue into main with commit c0acad9 Jun 9, 2023
5 checks passed
@chrisgacsal chrisgacsal deleted the reduce-polling-interval branch June 9, 2023 15:25
)

type Config struct {
AWSConfig *aws.Config
ScannerBackendAddress string

// The Orchestrator starts the Controller(s) in a sequence and the ControllerStartupDelay is used for waiting
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Saw that it was merged but maybe worth stating in the comment that the delay is between controller starts (just for users not to be confused why the first one starts without a delay). "..used for waiting between Controller starts to ..."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants