Avatar
0
Thân Nam Teacher
Thân Nam Teacher
cấu hình thời gian sử lí Job workers trong camuda platfrom 8
Làm sao để cấu hình Timeout không giới hạn - Job workers trong camuda platfrom 8 , và có cách nào để tự động sử lí Job workers khi hết thời gian không ạ.
  • Answer
Remain: 5
2 Answers
Avatar
tvd12 Teacher
tvd12 Teacher
Theo tài liệu về timeout ở đây:

"Timeouts

If the job is not completed or failed within the configured job activation timeout, Zeebe reassigns the job to another job worker. This does not affect the number of remaining retries.

A timeout may lead to two different workers working on the same job, possibly at the same time. If this occurs, only one worker successfully completes the job. The other complete job command is rejected with a NOT FOUND error.

The fact that jobs may be worked on more than once means that Zeebe is an "at least once" system with respect to job delivery and that worker code must be idempotent. In other words, workers must deal with jobs in a way that allows the code to be executed more than once for the same job, all while preserving the expected application state."

Thì anh thấy em bắt buộc phải set timeout, và nếu hết timeout thì job sẽ được chuyển qua cho worker khác xử lý, vậy anh nghĩ là nó tự động làm cho em rồi nhỉ?

  • 0
  • Reply
Avatar
Có 1 cách hay hơn timeout là bạn implement cơ chế extend lock nhé thay vì fix cứng 1 lock duration nhé.
  • 0
  • Reply