Currently we have a timestamp showing when a power command was added to the queue (activity.created) but beaker-provision won't run the command straight away so it might be many seconds later that it actually starts and then finishes running. We have no timestamp record for that right now.
There is a column command_queue.updated which might have been intended for this purpose but it's never set apart from defaulting to datetime.datetime.utcnow, which means it's currently always just the same as the creation time.
We want to know the completion time of power commands so that we can show accurate information for recipe installation progress -- for example the timestamp at which the netboot configuration was actually written to disk.
I think the first step is to divorce command_queue from the activity hierarchy, the decision to have it inherit from activity has proven to be a mistake.
Then we can clarify the timestamp columns. To be analagous with recipes I guess we could have:
* queue_time (the current created column)
and just drop the updated column.
This would also be our opportunity to introduce a proper column for recording the full error message in case of failure (the current new_value column, we would just drop old_value) which is part of bug 968715.
http://gerrit.beaker-project.org/5129 separate command_queue table from activity
http://gerrit.beaker-project.org/5185 record start_time and finish_time for power commands
But on thinking about it, I realise that this bug should also include updating the UI to display the new timestamps... so leaving this ASSIGNED for now.
This patch shows the new timestamps in the system commands grid (Power tab of the system page):
although I am not really happy with the whole grid approach there, since now we have so many columns that at most viewport widths the error message is going to be tightly wrapped and basically unreadable...
It is really begging for some kind of timeline view, showing the commands in sequence with an icon indicating their status and a bit of info below each one indicating what it is for/where it came from. And with the error message below each failed command. But that's a bigger redesign which will have to come later...
And this patch changes the recipe installation tab to use the actual finish_time instead of queue_time as the timestamp for "Netboot configured":
Beaker 24.0 has been released.