Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gracefully reject concurrent requests from OSB clients (such as K8S svcat) #220

Open
gberche-orange opened this issue Dec 16, 2019 · 2 comments
Labels

Comments

@gberche-orange
Copy link
Member

Requirements

As a service operator,

  • in order to support K8S clients that trigger concurrent update/get/delete requests without concurrency checks (as OSB mandates but CF currently prevents)
  • I need concurrent updates/deletes to be rejected with a useful error message

Design outline

This is a refinement of #40

Steps

  • Refine exiting endpont such as PATCH /v2/service_instances/:instance_id
    • Apply concurrency validation
      • Reject request if there is an ongoing update request pending
      • Reject concurrent update requests (OSB states it's broker responsibility to detect concurrency and reject concurrent requests)

Details of concurrency validation:

  • Reject request if there is an ongoing update request pending
    • Before accepting a new update, compare (D)esired state and (A)ctual state. If D!=A then reject a concurrent update
  • Reject update halting requests, Clarify what happens when deleting during a provision/bind request openservicebrokerapi/servicebroker#581
    • Compare (D)esired state and (A)ctual state. If D!=A then delete request
  • Reject concurrent update requests (OSB states it's broker responsibility to detect concurrency and reject concurrent requests)
    • Rely on git to conflict on the epoq value with different timestamps
@gberche-orange
Copy link
Member Author

Note that following introduction of osb-cmdb, all OSB requests are now originated from cloudfoundry, which currently ensures serialization of requests

@gberche-orange
Copy link
Member Author

closing as won't fix since osb-cmdb protects coab from this scenario

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant