Investigate whether we can skip CreateOrderService in purchase flow
Problem
Further investigation here: https://gitlab.com/gitlab-org/customers-gitlab-com/-/issues/7737#note_1651044797.
Related discussion here: https://gitlab.com/gitlab-org/customers-gitlab-com/-/issues/8369#note_1748504712
Currently, the CreateOrderService
is called twice in the purchase flow (potentially with race-condition timing too).
It's called:
- After the initial call to Zuora is made
- When we receive a callout from Zuora
Proposal
Investigate if it's necessary to call this service twice, or if we can rely on just the callout from Zuora. In particular, it would be worth considering:
- Are there attributes in the create service that aren't available in the callout?
- Does this cause issues if the callout from Zuora is delayed due to:
- being for a future subscription
- Zuora callouts lagging
Edited by Josianne Hyson