go-livepeer
go-livepeer copied to clipboard
Dynamic ticket EV validation on startup
trafficstars
What does this pull request do? Explain your changes. (required)
This change validates the ticket EV of an orchestrator to ensure it is sufficient for the prices that are set during startup.
Specific updates (required)
- Adds
getLargestPriceto startup.go. This determines the largest price across all models, gateway prices and default price to verify if the-ticketEVis large enough.
How did you test each of these updates (required)
Started orchestrator:
- Without
-ticketEV 2999999999999and with model price at4768372. Verified it failed validation. - With
-ticketEV 2999999999999and verified it passed validation.
However, larger price values will not pass validation without a larger ticket EV being set. I added a recommendation in the log entry based on the current formula.
This change currently does not prevent dynamic price changes outside of valid ticketEV while the orchestrator is running.
Does this pull request close any open issues?
AI-461
Checklist:
- [ ] Read the contribution guide
- [ ]
makeruns successfully - [ ] All tests in
./test.shpass - [ ] README and other documentation updated
- [ ] Pending changelog updated