openservicebrokerapi / servicebroker

Open Service Broker API Specification
https://openservicebrokerapi.org/
Apache License 2.0
1.19k stars 434 forks source link

feature request: a history of last operation descriptions #404

Closed maleck13 closed 5 years ago

maleck13 commented 6 years ago

The last operation description is useful and relates (obv) just to the last operation, however as this is a polling endpoint, there is the possibility of missing some feedback / operation descriptions. I think it would be valuable to have a way of viewing all descriptions for a particular operation. It could provide nice feedback and information to the end user particularly if you are using some kind of UI in front of the catalog.

avade commented 6 years ago

This would be useful for audit as well I could imagine. Do you have any other use cases in mind?

Currently, a platform that calls a service broker could cache the result, but it is possible that some description updates were missed.

This ties into the discussions around operations becoming first-class resources.

maleck13 commented 6 years ago

Yes the issue is that the last operation endpoint is something that you poll so you could easily miss an update. I don't have additional usecases at this point, but agree audit is another thing that could make use of this.

leonwanghui commented 6 years ago

@maleck13 @avade This point is quite interesting, could we add this topic into meeting agenda this week?

maleck13 commented 6 years ago

I would love to see it discussed. Not sure how to add it to the agenda though perhaps @avade is more knowledgable

duglin commented 6 years ago

I added it

maleck13 commented 6 years ago

Thanks will the outcome be posted here? Not sure where or when the meeting is on. Also I am on GMT time so could potentially be late here

duglin commented 6 years ago

See https://docs.google.com/document/d/1OqY5DoJuRKnlyF1w1XrhxlW9PjymEStU3IIG0qQLXfg/edit# for info on the call. Yes any resolution/comments should be posted in the issue.

leonwanghui commented 6 years ago

@maleck13 I guess you are better than me, the meeting time is 1:30 am my time : )

maleck13 commented 6 years ago

I wasn't able to make this call, was it actually discussed or do I need to be present before it can be discussed?

duglin commented 6 years ago

We didn't discuss this on that week's call. Typically, we focus calls on PRs unless someone specifically asks for a topic to be discussed. Which hasn't happened yet. @avade owns this one so he might be waiting until he has more time to formalize a direction he'd recommend.

Are you able to make our call today? 12:30pm ET. If not, one way to move this forward would be to submit a PR with the exact spec changes you'd like to see. Things tend to move much faster when we have a concrete proposal to think about.

w.r.t. this issue... are you asking for a "description" for all operations? To me the "description" on "last_op" is less about the operation (what it does) and more about the status of it, which really only makes sense for last_op since that's the way we query the status of async ops. Or am I missing something?

maleck13 commented 6 years ago

Yes I guess in reality it is an operation log that the broker would append too each time that it updated the last operation. I am happy to look at putting together a PR with proposed spec changes. I had thought this could be something that could be fulfilled by the last operation API, but perhaps it is a separate API altogether. Although personally I like the idea of having last_operation description and adding last_operation log / description_log to this API

duglin commented 6 years ago

oh, I'm sorry. You're just looking for a history of last_op descriptions not all ops. Sorry - I totally misread things.

I'm not against the idea, but I am curious to know what a user would do with that info. Having the latest I understand, but seeing the full history seems more like something the service broker admin would be more interested in.

maleck13 commented 6 years ago

So I think this would be potentially useful for an operator or admin attempting to debug what happened during a provision (giving a quick and simple overview), however my initial use case was to give the user a consistent log and feedback (rather than just what we happen to catch as part of the polling operation). This would let them know what has been done (since the last check) and what is currently being done. Providing the full history of last op descriptions I believe would allow for less sporadic feedback and provide the information to provide a compelling UX (CLI or Web) when working with the services.

maleck13 commented 6 years ago

Will create a proposal based on altering the last_operation api to also return a log of descriptions

mattmcneeney commented 6 years ago

This should be an optional feature, as many brokers aim to retain little or no state (or rely on other components to do this for them). Granted they already have to remember the operation string to fetch the status, but retaining a log of previous responses could be non-trivial for many service authors.

mattmcneeney commented 5 years ago

Given that many of the service brokers we support have little or no state, and that demand for this feature doesn't seem to be high, I'm going to close this. If this is still important to anyone, please do re-open it though.