open-feature / spec

OpenFeature specification
https://openfeature.dev
Apache License 2.0
666 stars 35 forks source link

Oversight: We don't have a mechanism to order hooks #114

Closed justinabrahms closed 2 years ago

justinabrahms commented 2 years ago

There's not currently a way, according to the spec, to control the ordering of specs WITHIN the "before" stage. Given these short-circuit (e.g. if an error happens, we skip the rest of the hooks), this seems like an oversight.

toddbaert commented 2 years ago

There's not currently a way, according to the spec, to control the ordering of specs WITHIN the "before" stage.

Do you mean the "ordering of hooks"?

Yes, I think this might be a miss... I think most implementations run them in the order applied, with the other stages running in reverse order... but we seemed to have neglected to mention this.

toddbaert commented 2 years ago

@justinabrahms - any more thoughts on this? Should we add a point to the spec saying that within a stage they run in the order added? All SDKs work this way, so it won't be a big deal.

If you think we need something more than that, I'm interested in proposals!

justinabrahms commented 2 years ago

Fine to drop this for now.