简体   繁体   English

uber-cadence 中的工作流工作者是否可以控制协程的数量?

[英]Whether the workflow worker in uber-cadence has control of the number of coroutines?

如果工作流执行时间长(比如工作流执行休眠),会不会产生大量的协程?

Cadence or Temporal workflow only needs a worker to generate the next steps to execute. Cadence 或Temporal工作流程只需要一个工作人员来生成接下来要执行的步骤。 When it is blocked waiting for an external event like a timer it doesn't consume any worker resources.当它被阻塞等待像计时器这样的外部事件时,它不会消耗任何工作资源。 So a single worker can process a practically unlimited number of workflows given that it can keep up with their execution rate.因此,一个工作人员可以处理几乎无限数量的工作流,因为它可以跟上他们的执行速度。

As an optimization workflows are cached on a worker.作为优化工作流缓存在工作人员上。 But any of them can be kicked out of cache at any time without affecting their correctness.但是它们中的任何一个都可以随时被踢出缓存,而不会影响它们的正确性。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM