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

Consider deleting/invalidating status.yml files on service instance updates #22

Closed
JohannesRudolph opened this issue Apr 28, 2021 · 1 comment

Comments

@JohannesRudolph
Copy link
Member

Some service owners building services on top of unipipe-service-broker may want to support parameter updates on existing service instances, or even mark their services plan_updateable.

In this scenario we should consider invalidating the status.yml file, possibly by deleting it. Without this additional invalidation the behavior of unipipe-service-broker would be inconsistent as it would return the last status written by the pipeline (e.g. a "succeeded") when in fact the pipeline has not yet processed the update to the service instance.

There's already existing logic for returning a default last operation state in that case:

var status = OperationState.IN_PROGRESS
var description = "preparing deployment"
if (statusYml.exists()) {
val retrievedStatus = yamlHandler.readObject(statusYml, Status::class.java)
status = when (retrievedStatus.status) {
"succeeded" -> OperationState.SUCCEEDED
"failed" -> OperationState.FAILED
else -> OperationState.IN_PROGRESS
}
description = retrievedStatus.description
}

I'm not sure about the impact on service bindings, but maybe there are similar concerns for them.

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

1 participant