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

Improve batcher workflow metrics #3306

Merged
merged 14 commits into from
Sep 7, 2022
Merged

Conversation

yux0
Copy link
Contributor

@yux0 yux0 commented Sep 2, 2022

What changed?

  1. Improve batcher workflow metrics.
  2. Add frontend batch operation API feature flag.
  3. Enable batcher per ns worker by default.

Why?
Improve batcher workflow metrics

How did you test it?
Local test

Potential risks

Is hotfix candidate?

@yux0 yux0 requested a review from a team as a code owner September 2, 2022 20:52
service/frontend/service.go Outdated Show resolved Hide resolved
@@ -91,6 +91,8 @@ const (
EnableActivityEagerExecution = "system.enableActivityEagerExecution"
// NamespaceCacheRefreshInterval is the key for namespace cache refresh interval dynamic config
NamespaceCacheRefreshInterval = "system.namespaceCacheRefreshInterval"
// EnableBatcherPerNamespaceWorker decides whether start batcher worker per namespace
EnableBatcherPerNamespaceWorker = "system.enableBatcherPerNamespaceWorker"
Copy link
Member

Choose a reason for hiding this comment

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

maybe

Suggested change
EnableBatcherPerNamespaceWorker = "system.enableBatcherPerNamespaceWorker"
EnableBatcher = "system.enableBatcher"

?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I see the per namespace worker flag changed to worker count. I assume the worker count could use to disable the per ns worker if the count set to 0. So I don't need this per ns worker flag and I just follow the scheduler to have a separate flag in frontend.

Copy link
Member

Choose a reason for hiding this comment

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

It's still possible to enable/disable each worker component (scheduler, batcher) per-namespace, even though you can't change the count. So we could have another dynamic config for that. I don't feel strongly either way.

Copy link
Member

@dnr dnr left a comment

Choose a reason for hiding this comment

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

also add a line to the PR description about the frontend dynamic config

service/worker/batcher/activities.go Outdated Show resolved Hide resolved
Makefile Outdated
@@ -117,7 +117,7 @@ update-mockgen:

update-proto-plugins:
@printf $(COLOR) "Install/update proto plugins..."
@go install github.com/temporalio/gogo-protobuf/protoc-gen-gogoslick@latest
Copy link
Member

Choose a reason for hiding this comment

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

I released new version of plugin. Please revert this change and rebase after #3300 is merged.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sure. I reverted the commit and wait for the PR to merge.

@yux0 yux0 merged commit c74881b into temporalio:master Sep 7, 2022
@yux0 yux0 deleted the batcher-metrics branch September 7, 2022 02:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants