| advertise add site services publishers database health videos | ![]() | about toolbar stats live show health store more stuff JOIN/LOGIN |
Subversion (SVN) is a version control system initiated in 1999 by CollabNet Inc. It is used to maintain current and historical versions of files such as source code, web pages, and documentation. Its goal is to be a mostly-compatible successor to the widely used Concurrent Versions System (CVS). Subversion is well-known in the open source community, being used on projects including Apache Software Foundation, Free Pascal, FreeBSD, GCC, Django, Ruby, Mono, SourceForge.net, ExtJS, Tigris.org, and PHP. Google Code also provides Subversion hosting for their open source projects. BountySource systems use it exclusively. Codeplex offers access to both Subversion as well as other types of clients. Subversion is also being adopted in the corporate world. In a 2007 report by Forrester Research, Subversion was recognized as the sole leader in the Standalone Software Configuration Management (SCM) category and a strong performer in the Software Configuration and Change Management (SCCM) category.[1] Subversion is released under the Apache License, making it open source.
[edit] HistorySubversion was started in 2000 as an effort to write an open source version control system which operated much like CVS but which fixed the bugs and supplied the features missing in CVS. By 2001, Subversion was sufficiently developed to be capable of hosting its own source code.[2] In November 2009 Subversion was accepted into the Apache Incubator which is the beginning of the process to become a standard top-level Apache project. [3] [edit] Features
[edit] Repository typesSubversion offers two types of repository storage — FSFS (Fast Secure File System) and Berkeley DB. FSFS works faster on directories with a large number of files and takes less disk space, due to less logging.[4] Subversion has some limitations with Berkeley DB usage leading to repository corruption and data loss when a program that accesses the database crashes or was terminated forcibly. When using Berkeley DB repository, the only way to use it safely is on the dedicated server and by a single server process running as one user, according to Version Control with Subversion.[5] Existing tools for Berkeley DB repository recovery aren't completely reliable, so frequent repository backups are needed. [edit] Repository accessSubversion repositories can be accessed by the following means:
All three means can access both FSFS and Berkeley DB repositories. Any 1.x version of a client can work with any 1.x server. Newer clients and servers have additional features and performance capabilities, but have fallback support for older clients/servers. [7] [edit] LayersSubversion is composed internally of several libraries arranged as layers. Each performs a specific task and allows developers to create their own tools at the desired level of complexity and specificity.
[edit] FilesystemThe Subversion filesystem can be described as "three dimensional". In addition to the two dimensions of a standard directory tree (e.g., tree view), the Subversion filesystem's third dimension is revisions. Each revision in a Subversion filesystem has its own root, which is used to access contents at that revision. Files are stored as links to the most recent change; thus a Subversion repository is quite compact. The storage space used is proportional to the number of changes made, not to the number of revisions. The Subversion filesystem uses transactions to keep changes atomic. A transaction is begun from a specified revision of the filesystem, not necessarily the latest. The transaction has its own root, on which changes are made. It is then either committed and becomes the latest revision, or is aborted. The transaction is actually a long-lived filesystem object; a client does not need to commit or abort a transaction itself, rather it can also begin a transaction, exit, and then can re-open the transaction and continue using it. Multiple clients can access the same transaction and work together on an atomic change. [edit] PropertiesOne important feature of the Subversion filesystem is properties, simple name=value pairs of text. Properties are used in two different places in the Subversion filesystem. The first is on filesystem entries (i.e., files and directories). These are versioned just like other changes to the filesystem. Users can add any property they wish, and the Subversion client uses a set of properties, which it prefixes with 'svn:'.
The second place in Subversion where properties are used is on revisions themselves. Like the above properties on filesystem entries the names are completely arbitrary, with the Subversion client using certain properties prefixed with 'svn:'. However, these properties are not versioned and can be changed later.
[edit] Branching and taggingSubversion uses the interfile branching model from Perforce[8] to handle branches and tags. Branching is the ability to isolate changes onto a separate line of development.[9] Tagging is creating a snapshot of the repository's content, which, unlike a branch, is not expected to change in the future. A new branch or tag is created with the 'svn copy' command, which should be used in place of the native operating system mechanism. Subversion does not create an entire new file version in the repository with its copy. Instead, the old and new versions are linked together internally and the history is preserved for both. The copied versions take up only a little extra room in the repository because Subversion saves only the differences from the original versions. All the versions in each branch maintain the history of the file up to the point of the copy, plus any changes made since. Changes can be 'merged' back into the trunk or between branches. To Subversion, the only difference between tags and branches is that changes should not be checked into the tagged versions. Due to the differencing algorithm, creating a tag or a branch takes very little additional space in the repository. [edit] Current limitations and problemsThe current version of Subversion only allows directory access control and lacks more granular file access control. That problem dramatically restricts the use of Subversion in projects where directories are not structured to address the functional separation among various objects. For example, directories like lib, src, bin do not address security and access control in most cases. A known problem in Subversion is the implementation of the file and directory rename operation. Subversion currently implements the renaming of files and directories as a 'copy' to the new name followed by a 'delete' of the old name. Only the names are changed, all data relating to the edit history remains the same, and Subversion will still use the old name in older revisions of the "tree". However, Subversion may be confused when files are modified and moved in the same commit. This can also cause problems when a move conflicts with edits made elsewhere[10], for example during merging branches[11]. This problem was expected to be addressed in the Subversion 1.5 release, but only some use cases were addressed while the problems with some other use cases were postponed.[12] Subversion currently lacks some repository administration and management features. For instance, it is sometimes desired to make edits to the repository to permanently remove all historical records of certain data being in the repository. Subversion does not have built-in support to allow this to be done simply.[13] Subversion stores additional copies of data on the local machine, which can be an issue for very large projects or files, or if developers are working on multiple branches simultaneously. These .svn directories on the client side can become corrupted by ill-advised user activity[14], although a repair tool is provided ("svn cleanup"). Subversion does not store modification times of files. As such, a file checked out of a subversion repository will have the 'current' date (instead of the modification time in the repository), and a file checked into the repository will have the date of the checkin (instead of the modification time of the file being checked in). This might not always be what is wanted. [15] [edit] ReleasesMain article: Software that uses Subversion CollabNet is still involved with Subversion but the project is run as an independent open source community.[citation needed] The home of Subversion is on Tigris.org, an open-source community dedicated to software engineering tools[16]. The Subversion open-source community does not provide binaries but these can be downloaded from volunteers and from CollabNet, the initiator of the Subversion project. While the Subversion project does not include an official graphical user interface (GUI) for use with Subversion, a number of different GUIs have been developed, along with a wide variety of additional ancillary software. [edit] See also
[edit] Notes
[edit] References
[edit] Further reading
[edit] External links
| ||||||||||||||||||||||||||||||||||||||||||||||||||
| ↑ top of page ↑ | about thumbshots |