feat: Reject requests and skip expiration stops for instances without sablier.enable=true#901
Conversation
acouvreur
left a comment
There was a problem hiding this comment.
Overall, very nice changes.
But I have the feeling that it should be 2 different flags.
One to require the sablier.enable on the instances
One to ignore expiration on instances that are disabled.
As I mentioned, it is a valid scenario for users to start an instance with the sablier.enable, update the instance to remove sablier.enable and let it run for ever.
Obviously some provider do not support that without restarting the instance, but some do. So I think that it's important.
What do you think ?
I suggest two new flags:
require-enable/require-sablier-enabled/ other suggestion ? This is for incoming requests.verify-enable-on-expiration/stop-on-expiration-if-enabled/ other suggestion ? This is for the expiration function
|
Yes, it's better to split the flag, i would say |
I think those express a better intent:
Purpose: reject incoming requests when the target instance is not sablier.enable=true. EDIT: It's worth noting that
Purpose: on expiration, re-check the instance label and only stop if sablier.enable=true. I've made Claude Sonnet analyze the PR and give some suggestion, and I think I agree with those suggestions, the intent is very clear and represent properly the new features |
|
@louisdtt I'm sorry I've introduced new command flags recently, you have to rebase again. I will wait for your rebase before merging any further PRs |
|
Don't worry, l'll do it in a few hours |
cde8ebd to
3fde7ae
Compare
|
All tests ok, the build error is just sonar |
acouvreur
left a comment
There was a problem hiding this comment.
LGTM
A few code style could be improved, but we can do it in another pull request
|
Maybe one last thing, @louisdtt could you create 2 working examples under examples/ so that it is easy to demonstrate and test in an end to end scenario ? After that, we can merge if testing is successful |
|
Ok, let me try the examples and we're good to go |
|
Ok, I've tried both example. Both works, but I had a few issues with the verify example: I will merge it now as this is just an example. |
Adds provider.ignore-unlabeled at Sablier level without changing provider code.
Following #893