go-livepeer
go-livepeer copied to clipboard
ai: add models webhook url param
What does this pull request do? Explain your changes. (required)
In order to avoid restarting orchestrators whenever we change the runners list we'd like to have a dynamic way of setting up the -aiModels. Similarly to [-orchWebhookUrl](https://github.com/livepeer/go-livepeer/blob/master/doc/orchwebhook.md?plain=1#L4) that can be used for providing dynamic list or orchestrators on the broadcaster side.
Specific updates (required)
- Add
aiModelsWebhookUrl
param, accepting a string which can be either a webhook url or a file path - Webhook gets called every 1 minute, updating the model configs
-
Webhook.GetConfigs()
returns the most recent config - Added tests for both url and file updates
How did you test each of these updates (required)
unit tests
Does this pull request close any open issues?
Checklist:
- [X] Read the contribution guide
- [ ]
make
runs successfully - [ ] All tests in
./test.sh
pass - [ ] README and other documentation updated
- [ ] Pending changelog updated