Ticket #278 (closed enhancement: fixed)

Opened 8 months ago

Last modified 5 months ago

enhanced /buildslaves page

Reported by: bhearsum Assigned to: bhearsum
Priority: minor Milestone: 0.7.9
Component: statusplugins-web Version: 0.7.7
Keywords: Cc: dustin, Pike

Description

This is a short patch I wrote to make the /buildslaves WebStatus? page a little more useful. It does do things: 1) bolds the 'slave is NOT connected' line to make it more visible 2) shows whether each slave is busy (building) or not

Also included is my attempt at a unit test for it. The test fails, but everything works as intended during manual testing. I suspect runutils.py needs a bit of modification to work like I need it to, but I couldn't manage to get it working myself.

Attachments

enhancedBuildSlavesPage.diff (4.6 kB) - added by bhearsum on 05/15/08 10:54:37.
enhanced /buildslaves page
enhancedBuildSlavesPage-v2.diff (8.4 kB) - added by bhearsum on 05/27/08 06:07:50.
again, with tests + working

Change History

05/15/08 10:54:37 changed by bhearsum

  • attachment enhancedBuildSlavesPage.diff added.

enhanced /buildslaves page

05/15/08 10:56:13 changed by bhearsum

  • status changed from new to assigned.

I find the 'is the slave busy' part to be especially useful when you have many builders that share a pool of slaves -- afaict there isn't another way to quickly tell 'what slaves are doing things right now'.

05/15/08 12:12:35 changed by dustin

  • cc set to dustin.

05/15/08 16:04:59 changed by dustin

Problem is, a buildslave can be running more than one build at a given time -- thats what the canStartBuild stuff in buildbot/buildslave.py is all about. The patch will also get confused if slaves connect or disconnect, I think.

It might be easiest to add an updateSlaveStatus method to BuildSlave, which records in the SlaveStatus? object the number of builds (or maybe a list of the BuildStatus? objects, or BuilderStatus? objects) that are currently running on the slave.

05/15/08 23:26:02 changed by Pike

  • cc changed from dustin to dustin, Pike.

05/27/08 06:07:50 changed by bhearsum

  • attachment enhancedBuildSlavesPage-v2.diff added.

again, with tests + working

05/27/08 06:15:32 changed by bhearsum

Thanks for the suggestions Dustin, they helped a lot. I added an updateSlaveStatus to BuildSlave which gets called in Build.startBuild() and _release_slave(). I'm not sure if Build talking directly to BuildSlave is a good idea or not, I'm happy to add an intermediate method to SlaveBuilder? if that's the right way to do it.

All tests + the new ones in this patch are passing, and I've done manual testing with different numbers of builders, slaves while running/stopping builds, disconnecting slaves, etc.

06/01/08 10:39:22 changed by dustin

Looks great! In the devel tree as #278:enhancedBuildSlavesPage-v2.diff.

It will get pushed to Brian's tree in a bit, unless I hear any problems.

07/15/08 12:31:44 changed by dustin

  • milestone changed from undecided to 0.7.8.

08/20/08 06:36:00 changed by dustin

  • status changed from assigned to closed.
  • resolution set to fixed.