-
Notifications
You must be signed in to change notification settings - Fork 880
feat(shard-distributor-canary): add support of multiple executors #7619
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
base: master
Are you sure you want to change the base?
feat(shard-distributor-canary): add support of multiple executors #7619
Conversation
e3da20a to
796e5fc
Compare
| if numExecutors <= 0 { | ||
| numExecutors = 1 | ||
| } |
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.
nit: just curious - how this can be if that's an argument?
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.
It's more for safe merging into internal code and to not have any blockers for merging into. I'm planning to make changes internally and remove these later :)
|
|
||
| func opts(names NamespacesNames) fx.Option { | ||
| return fx.Options( | ||
| fx.Supply(names.Config), |
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.
A bit unusual - I wonder why we use fx.Supply instead of providing config? (and reader initially populating it)
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 didn't want to bring a load of configuration to this PR, but to have some starting point for config. Later, we can add a PR adding a config to main.go. But I also don't want to have it as a failure point for internal code due to a change of app initialization, so I want to make it as much as smothier way.
Right now, there is no real reason for us to use config locally; however internally we need to be able to modify these values, because we don't use flags internally. So I introduced config here and I didn't want to make it a required parameter for the canary.Module to not break the app initialization internally, but at the same time, I want to have it as a required parameter for Executors and ShardCreator later.
So for this, I decided to supply config, but internally I can use a decorator to override values and load configuration by using internal configuration functions.
986f967 to
e26eacc
Compare
|
gitar apply your changes |
✅ Applied the typo fix: Changed |
bff0ab7 to
f381d24
Compare
Code Review ✅ Approved 2 resolved / 2 findingsThe flag precedence issue has been properly fixed using ✅ 2 resolved✅ Bug: Flag precedence logic contradicts documentation
✅ Bug: Typo in variable name: `numEphemeralxecutors`
OptionsAuto-apply is off → Gitar will not commit updates to this branch. Comment with these commands to change:
Was this helpful? React with 👍 / 👎 | Gitar |
What changed?
shard-distributor-canarygot an option to run multiple executors for fixed and ephemeral namespacesnum-executors(for both namespaces),num-ephemeral-executors,num-fixed-executorsflags were added to configure how many executors should be runconfigfolder was addedWhy?
configwas added to make advanced configuration for canary running internally without using flags.How did you test it?
make sharddistributor-canary && ./sharddistributor-canary start --num-executors=10