joyent / conch-ui

Web UI for Conch (https://github.com/joyent/conch-api)
2 stars 5 forks source link

Review time-to-validate logic in conch-ui #16

Open bdha opened 6 years ago

bdha commented 6 years ago

There are several issues here: the max_burnin is hardcoded, even though we use user settings (picked up via the Relay) to decide how long burnin actually is. This one is a bit tough as the UI only has access to the logged in user settings; we might want a hash here and we just have to keep it updated by hand until we have another facility for managing this.

I suspect the math is also wrong in Conch::Rebooter, and we aren't accounting for how long firmware upgrades can take. So while it's fine if the TTV is an estimate, being off by 25% isn't great.

sungo commented 6 years ago

A long time ago, we discussed maybe moving burnin times to the device itself, rather than the user that's bound to that DRD/Relay. The shell would let us automate the initial change and we could put a default on the value from the API. (I assume it will be in device settings so a real postgres default isn't possible).

It's a little clunky but it would allow the UI to show the value without strange machinations and it would also allow us to customize burnin time, if necessary, for each device.

bdha commented 6 years ago

When the device registers, it should get the default automatically assigned to it, unless we specify an override. That will still lead to some confusion if a chassis is swapped out during integration, but it's still quite a bit better than what we have now -- and it's easy to "true up" an entire build/workspace from the shell.