Skip to content

Pass update_sequence_id to JiraConnect workers

What does this MR do?

Pass update_sequence_id argument to all invocations of JiraConnect::SyncMergeRequestWorker and JiraConnect::SyncBranchWorker

This is the part 2 of a multi release effort to make JiraConnect workers idempotent. After adding the argument with a default value in !46535 (merged), This MR makes sure an update_sequence_id is always used when scheduling a JiraConnect worker.

The workers sync repository and merge request data with Jira. They send an API request containing a update_sequence_id which is generated from a timestemp and helps Jira to avoid conflicts.

In my first attempt to make the workers idempotent, it was discovered that update_sequence_id would change when the worker would run twice with the same argument and because of this wouldn't be idempotent. To fix this, update_sequence_id needs to be generated outside the worker and provided as an argument.

Related issues

Realted MRs

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Edited by Andy Schoenen

Merge request reports

Loading