pipecd icon indicating copy to clipboard operation
pipecd copied to clipboard

feat(piped): make planpreview handler configurable via piped config

Open kadai0308 opened this issue 8 months ago • 0 comments

What this PR does: This PR makes the planpreview handler behavior configurable via the piped.yaml config file. This allows operators to tune performance and resource usage based on deployment scale or workload.

Changes

  • Added the following fields to PipedSpec:

  • handlerWorkerNum

  • handlerCommandQueueBufferSize

  • handlerCommandCheckInterval

  • handlerCommandHandleTimeout

Passed these values into the planpreview handler using new functional options:

  • WithWorkerNum

  • WithCommandQueueBufferSize

  • WithCommandCheckInterval

  • WithCommandHandleTimeout

Why we need it: We have some options in the planpreview package, but they are not used or are only used in the tests.

https://github.com/pipe-cd/pipecd/blob/d667a1c43fa245519079d106a717fe1e0125021a/pkg/app/piped/planpreview/handler.go#L52-L74

Which issue(s) this PR fixes:

Fixes #5916

Does this PR introduce a user-facing change? & How are users affected by this change: User now can add the handler configs.

  • Is this breaking change: no

kadai0308 avatar Jun 12 '25 06:06 kadai0308