wiki:ProjectIdeas

Version 19 (modified by ayust, 8 years ago) (diff)

--

GSoC 2011

If you're interested in working on any of these ideas, or have ideas of your own that you'd like to work on, get in touch! See the links on Development, or email the project maintainer directly - dustin@… or maruel@….

Keep in mind that we have three goals for GSoC:

  • We gain new contributors to Buildbot
  • You learn about open-source development by doing it
  • Users get amazing new Buildbot features

We'd like to achieve all three goals, but the world is messy, and predictions are hard. If you finish the summer having learned a lot and become a lifelong contributor to Buildbot, but without wrapping up a user-visible feature, that's still OK.

Your Idea Here!

We are open to any ideas that will make Buildbot better - think of this page as a set of ideas to get you started.

JavaScript Frontend

Owner: maruel

Currently, the web frontend is rendered synchronously by the Buildmaster, based on data from the database and from build pickles. This has two disadvantages:

  • the entire Buildmaster is blocked while the page is being rendered, which can be a significant time as build pickles are slow to laod
  • once SQLAlchemy is fully implemented (which will happen before GSoC 2011 begins), database queries cannot be made synchronously

The preferred solution at this point is to write the web frontend in browser-side JavaScript, using the existing JSON interface to gather the necessary data.

Scope

Work on this project would begin with a simple proof-of-concept page, selection of a JavaScript framework, and the necessary Python code to support all of it. This will involve a lot of discussion about problems that may come up later in the project, and planning ahead for them. Once this has been reviewed and accepted, you can go page-by-page through the Buildbot interface, rewriting each (or even parts of each) in JavaScript.

The JS frontend will talk to a REST service provided by the Buildmaster. Much of this service is already implemented, but it will need to be expanded and improved, which will require some Python programming and learning a bit about Twisted Python.

Issues to consider:

  • testing - how will we test the JS?
  • compatibility - what browsers will we support? Way probably want to focus on latest version of browsers but care about mobile browsers too.
  • configuration - how can we configure the frontend using parameters in the Buildmaster's configuration file?
  • security - how can we protect information from being seen by those who should not see it? How can we limit who can start or stop builds?
  • licensing - if we redistribute a JS framework, its license must be compatible with Buildbot's
  • documentation - how can we do a better job of documenting the web frontend for others to use?

Windows Process Management

Owner: djmitche

The windows tag documents a number of bugs about starting and killing processes on Windows. Buildbot uses Twisted's process-handling code, so these bugs may be fixed by either re-implementing better support directly in Buildbot, or by patching Twisted's process-handling code.

See also:

Scope

To do well with this project, you would need to bring a lot of the Windows experience that is lacking in the Buildbot development community. Assuming you're familiar with Windows APIs and accessing them from Python, this bug would entail

  • writing test cases to reproduce bugs users have seen
  • interacting with the Twisted community to design solutions that can be merged upstream
  • implementing portable fixes to those bugs
  • documenting them

User Objects

Buildbot deals with "users" in a number of ways: commits are generated by users, and those cause builds that the users may want to know about. Users can also cause builds via the web, IRC, or from command-line tools. Buildbot communicates results back to people through a number of mechanisms, too: email, IRC, web, and so on. In many cases, Buildbot administrators need to ensure that only certain people can perform certain operations, such as starting or cancelling builds.

The project, then, is to design and implement a consistent way to represent "users" throughout Buildbot.

Scope

This project has a significant design component, since there is very little code related to users in Buildbot right now. The design would need to address backward compatibility (users should not have to change their buildbot configurations when upgrading), security, flexibility (we have almost a dozen version control backends, and each thinks about users differently!), and configurability. There will most likely be a new database table or two to add.

Once the design is done, this project should have a few concrete milestones where particular parts of Buildbot start using the new functionality. For example, when MailNotifier? can use the new functionality to translate the author of a source-code commit into an email address, that is a concrete milestone.

Multi-Repository Builds and Build Coordination

Owner: djmitche As implemented right now, a single Buildmaster can build multiple projects, but each project must be built from a single source code repository, and builds of the projects must not interact. Increasingly, though, users want to build projects that require source from multiple repositories, and where a checkin to any of those repositories should trigger a build. Similarly, users often want to coordinate multiple projects, for example a web frontend and backend server that are built separately but must be tested together or packaged into a single installer.

See also:

Projects and Scope

Fixing this is a big, ongoing task that cannot be completed in a summer, so this project would involve *improving* support for these sorts of configurations. Part of the project (and proposal), then, is defining what problem you'd like to solve. We have discussed a few ideas that might get you started:

  • Sourcestamps that point to multiple repositories and revisions in those repositories. Builds would then specify a way to check out the given revision of each repository before beginning the compile and test steps. Designing these would involve some significant changes to the database schema, as well as a solid plan for backward compatibility. Because changes would be required on the master and slave, you would need to think about compatibility between different versions of master and slaves, as well. If possible, it would be smart to concentrate on only one version-control system for a summer project, so that others could fill in the blanks later.
  • Source managers that know everything about a particular version control repository. A source manager, for example, could determine the changes that were made between two source stamps (revisions), or provide the information required to check out a particular revision from a repository. Source managers, too, could be implemented for a single version control system, so that others can finish the work for the remaining systems.
  • "Gaggles" of builds. Right now, it is very difficult to wait for a number of different builds to finish - for example, if you need the Windows and Linux builds to finish so that you can compress them into a CD image. The most difficult part is to determine when two builds "go together", even if they occur at different times. If we can group builds into gaggles, then it's easy to wait for, for example, all of the Linux and Windows builds in a particular gaggle to finish before starting the CD-burning build. This project would involve a lot of design discussions with Buildbot users, then some database and code changes to manage gaggle identifiers. Finally, some easy-to-use synchronization steps and documentation of how to use them would make this available to Buildbot's users.

Consistent, Efficient Source Steps

Owner: djmitche

Slaves often checkout/clone the entire repo (when doing full builds). This can take a lot of time and network traffic, and often takes *more* time with the new distributed version-control systems, since they like to download the entire history for each clone. There are a few "modes" defined which try to reduce this need (e.g., by copying an untouched checkout, or trying to "clean" the build artifacts out of a checkout), but these are implemented inconsistently across version control systems. They also do not take full advantage of the capabilities of all of the version control systems. For example, it may be possible to do a "shallow" clone that does not pull in unnecessary history; some version control systems support a cache of some sort that can store history that might be common across multiple builds on the same slave.

Buildbot needs a consistent, easy, and configurable way for users to take advantage of these behaviors.

See also

Scope

This project begins with a significant design problem: figure out the common behaviors across a number of version control systems, and how to represent those behaviors to Buildbot's users. Once that's done, you'll need to implement those new behaviors. To allow for different amounts of available time over the summer, it will be smart to start with one version-control system, then tackle more if time allows.

Master-Side Source Steps

Owner: djmitche or maruel

Buildbot currently implements a lot of the "smarts" of its source-checkout steps on the slave. That makes it hard to configure and change that behavior, since generally Buildbot users have one master a lot of slaves. Ideally, the slaves would just provide functions like "create this file", "run this command", and so on, and the smarts would all reside on the master, built using the slave functions.

Scope

This is an ongoing project, so a good proposal will carve out a smaller portion of it to work on. If you choose your steps wisely, you can make small improvements to Buildbot so that if you don't finish the whole project, all is not lost. For example, you could add some more slave-side commands that aren't available yet, and then begin using those to implement just one of the source steps on the master. Your work would then provide an example for others to implement the other steps on the master.

New Master-Slave Protocol

Owner: djmitche or maruel

Buildbot currently uses Twisted Python's perspective broker to communicate with slaves. This is a remote procedure call library that operates on TCP connections, and has a few disadvantages:

  • It is Python-only, so slaves must be implemented in Python
  • It keeps the TCP connection open for many hours, and does not handle connection failure well
  • The RPC model is complex and does not map well to the operations Buildbot performs

Scope

Here be dragons! Several people have attempted this before:

either of these may be a great starting point for this project, but at any rate this is a challenging project that will require a lot of thoughtful design work.

The best approach is to find a way to get some working code put together quickly, while still allowing Buildbot to do everything its users expect. For example, if you can write your new protocol such that Buildbot can use perspective broker or your protocol, but you only get as far as a simple slave that can run echo hello world, that's great! We can ship that code, and someone else can pick up where you've left off to add more capabilities to your protocol -- assuming your design does not make that impossible.