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

Support service instances provisionned by K8S svcat (idempotent dups calls) #337

Open
gberche-orange opened this issue Feb 26, 2020 · 3 comments

Comments

@gberche-orange
Copy link
Contributor

gberche-orange commented Feb 26, 2020

  • As a app broker operator
  • in order to expose app broker-based service brokers to K8S service catalog client
  • I need app broker to implement the concurrency control in the OSB spec

https://github.com/openservicebrokerapi/servicebroker/blob/master/spec.md#provisioning

PUT /v2/service_instances/:instance_id
Response

Status Code Description
200 OK SHOULD be returned if the Service Instance already exists, is fully provisioned, and the requested parameters are identical to the existing Service Instance. The expected response body is below.
201 Created MUST be returned if the Service Instance was provisioned as a result of this request. The expected response body is below.
202 Accepted MUST be returned if the Service Instance provisioning is in progress. The operation string MUST match that returned for the original request. This triggers the Platform to poll the Last Operation for Service Instances endpoint for operation status. Note that a re-sent PUT request MUST return a 202 Accepted, not a 200 OK, if the Service Instance is not yet fully provisioned.
400 Bad Request MUST be returned if the request is malformed or missing mandatory data. MAY be returned if the request contains invalid data, in which case the error response MAY include a helpful error message in the description field (see Service Broker Errors).
409 Conflict MUST be returned if a Service Instance with the same id already exists or is being provisioned but with different attributes.

See kubernetes-retired/service-catalog#1639 and case reproduced in OpenShift v3.9.51 ( Kubernetes v1.9.1+a0ce1bc657 )

Currently, duplicate provisionning calls leads to duplicate backend services, or depending on the configuration on errors from Cf reporting already existing app/service instance names

Same issue exist for deprovisionning and likely updates.

See orange-cloudfoundry/osb-cmdb#17 and orange-cloudfoundry/osb-cmdb#17 (comment) for considered fix using the service instance repository

@royclarkson
Copy link
Member

@gberche-orange thanks. good catch! I have an unrelated request. Mind if we don't use the acronym SCAB? It's our fault for naming the project that way, but that word has negative connotations in English. :-D Maybe let's just say "app broker"?

@gberche-orange
Copy link
Contributor Author

@royclarkson

Mind if we don't use the acronym SCAB?

Sure, I fixed that in the issue body, sorry I did not realize this semantic overriding

@royclarkson
Copy link
Member

Thanks! much appreciated. No need to apologize. It just reads better for others coming to the project.

@spikymonkey spikymonkey added this to the 1.2.0-M3 milestone Jun 11, 2020
@spikymonkey spikymonkey removed the 1.2.x label Jan 14, 2021
@spikymonkey spikymonkey modified the milestones: App Broker 1.4.0-M2, App Broker 1.4.0 Dec 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants