Essentials

Download!

Documentation

Get Support

Get Involved

Subprojects

Miscellaneous

Apache Development Notes

This page is intended to provide some basic background about development nits and the maintenance of the developer site.

Overview

The Apache HTTP Server Project has switched to Subversion for hosting its source code.

To check out the 2.4.x branch:

svn checkout http://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x httpd-2.4.x

To check out the current development version (as of this writing, 2.5.x), use:

svn checkout http://svn.apache.org/repos/asf/httpd/httpd/trunk httpd-trunk

Committers should check out via https instead of http (so that they can commit their changes). For more info about Subversion, please read the ASF version control FAQ.

The developers continue to seek to maintain module compatibility between 2.4.1 and future 2.4 releases for administrators and end users, while continuing the forward progress that has made the 2.2 server faster and more scalable.

Maintaining the Sources

Almost all files relating to Apache, both the actual sources and the files that aren't part of the distribution, are now maintained in an SVN repository. Here is the way in which changes are applied:

  1. Developer checks out a copy of the files on which he wants to work (in this case, the trunk), into a private working directory called httpd-trunk:
% svn checkout http://svn.apache.org/repos/asf/httpd/httpd/trunk httpd-trunk

This step only needs to be performed once (unless the private working directory is tainted or deleted.) Committers should use a URL prefix of https on the checkout, to save themselves headaches later.

  1. Developer keeps his working directory synchronised with changes made to the repository:
% svn update httpd-trunk

This should probably be done daily or even more frequently during periods of high activity.

  1. Developer makes changes to his working copies, makes sure they work, and generates a patch so others can apply the changes to test them:
% svn diff httpd-trunk/modules/http/mod_mime.c > /tmp/foo

The /tmp/foo file is mailed to the developers list so they can consider the value/validity of the patch. It is worth making sure your code follows the Apache style, as described in the style guide.

  1. Once other developers have agreed that the change is a Good Thing, the developer checks the changes into the repository:
% svn commit httpd-trunk/modules/http/mod_mime.c

SVN Subtrees

There are several different branches under the httpd subtree in the Apache SVN repository that pertain to the different releases. The top level can be perused with the SVN ViewCVS pages. The main subtrees pertaining to the httpdserver source are:

httpd-2.2

To create a directory tree containing the 2.2 sources, and call it httpd-2.2, change your current directory to the parent of the tree and then check the 2.2 sources out as follows:

% cd /usr/local/apache
% svn checkout http://svn.apache.org/repos/asf/httpd/httpd/branches/2.2.x
   httpd-2.2

httpd-2.4

To create a directory tree containing the 2.4 sources, and call it httpd-2.4, change your current directory to the parent of the tree and then check the 2.4 sources out as follows:

% cd /usr/local/apache
% svn checkout http://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x
   httpd-2.4

httpd-2.5

If you want to check out the bleeding edge of development, the httpd-2.5 development tree (slated for a release 2.6), and call it httpd-trunk, checkout as follows:

% cd /usr/local/apache
% svn checkout http://svn.apache.org/repos/asf/httpd/httpd/trunk
httpd-trunk

httpd-site

This subtree contains the files that live at http://httpd.apache.org/. The directory on the host that maps to that URL is actually a set of checked-out working copies of the SVN files.

The SVN URL is https://svn.apache.org/repos/asf/httpd/site/trunk/docs. It is important that the files on the Web host not be modified directly. If you want or need to change one, check it out into a private working copy, modify that , commit the change into SVN, and then perform a svn updateto bring the host directory into sync with the SVN sources. The Web site directories (as opposed to files) are not maintained in synch with the SVN files automatically. They are manually updated from SVN by various people as they consider appropriate. This is usually not an issue, unless a group of files are being updated according to an ongoing group discussion.

httpd-dist

Like the httpd-sitesubtree, this one is used to maintain the files that comprise a website - in this case, http://www.apache.org/dist/httpd/. Also like the previous subtree, the directory on the server is a checked-out working copy of this subtree. However, since this is a distribution directory, we only have the surrounding documentation and control files checked into this subtree -- the actual tarballs are simply copied to www.apache.org.

The SVN URL is https://svn.apache.org/repos/asf/httpd/httpd/dist.

Committers will generally deal with this subtree when "rolling" a release. This is a series of steps taken to create a complete new release of the Apache httpd software. Amongst other things, the key to this subtree is the tools/directory, which contains the release.shshell script. More information on the policies and procedures relating to rolling releases can be found on the Release Guidelines page.

Setting Up Remote SVN

A brief overview of getting started with SVN committer access can be found here. One key change to note is that SSH is not used anymore for committer access, due to the functional differences with SVN.