How to version workers?

Hi,

So we have scenarios where we have workers and each of them has given some name example “intiatePayment”. When developing these I have a few questions popping up.

  • What is the naming convention for the workers?
  • How do you version them ? should be start naming then as “initiatePayment-v1” or some other recommendation?
1 Like

Hi @sherry-ummen,

thank you for raising this up!

How do you version them ? should be start naming then as “initiatePayment-v1” or some other recommendation?

Encoding the version in the job type is a good idea :+1:

As an alternative, you could delegate/root in job in the worker itself. The job worker reads the version from the job headers and delegates it to the specific implementation.

1 Like