Perforceis a commercial, proprietary revision controlsystem developed by Perforce Software, Inc.
Perforce is a
client/serversystem.The server manages a central databaseand a master repositoryof file versions. Users work on files in local client workspaces and exchange files with the server via any of a number of clients ( user interfaces) (see below).
Client and server communicate via
TCP/IPusing a proprietary RPC and streaming protocol.
The Perforce database is proprietary, preconfigured, and self-installed.It stores system-related
metadata(file state, file attributes, branching and merging history, changelists, change descriptions, users, groups, labels, etc.).Files are identified by namespace (i.e., by OS-neutral filenames).File content itself is not stored in the database. MD5hashes of file content are stored in the database,however, and can be used to verify repository file integrity.
Database tables are stored as binary files.
Checkpoints and journals are written as text filesthat can be compressed and offloaded.A database that has been corrupted by hardware failure or other catastrophecan be recovered from the most recent journal and checkpoint.Administrators must plan for disaster recovery by configuring database journaling and setting up regular checkpoints.
Versioned file content is stored in a master directory hierarchy whose top levels are called "depots".Text file revisions are stored as RCS deltas [Although text file revisions are stored as RCS deltas in the repository, Perforce does not use the RCS system to manage files.] and binary file revisions are stored in their entirety.The encoding used for text files in the repository is either
ASCIIor Unicode, depending on Perforce server configuration.Repository files are not encrypted.Revisions that are branches or copies of other revisions are virtual copieswithin the repository.All revisions are preserved by default; limits can be set on the number of revisions preserved.Obsolete revisions and files can be purged by the administrator.Repository files must be included in regular system backups.
Clients to the Perforce system fall into roughly four categories:
GUI, web, and plugin.
The basic command interface is P4, the command-line client. P4 can be used in any command shell or script. It produces
human-readableoutput by default, but can also produce tagged text output, marshalled Python output, and marshalled Ruby output.A C++ API to the Perforce client commands is also available, as are Perl, Python, and Ruby extensions built upon it.The command interfaces support the system's complete client functionality andcan be used with OS-native filenamesyntax as well as with Perforce's OS-neutral filename syntax.
A web interface is provided by P4Web, [ [http://www.perforce.com/perforce/doc.current/manuals/p4web/help/index.html P4Web User Guide] ] a program that is both a Perforce client and a stand-alone
HTTPdaemon. P4Web can be run as a shared web serverto provide read-only access to the Perforce file repository and metadata.It can also be run on a user's machine, enabling web browsers to becomethe interface to client operations on the local machine.
The plugin interfaces are behind-the-scenes programs thatintegrate Perforce client functionality into third-party software.Perforce plugins are available for
desktop environments, software developmenttools, digital assetdevelopment tools, software buildtools, code reviewsystems, defect trackingsystems, office automationtools, SQLclients, and FTPclients.
* Complete file and metadata history
* Full revision history for branched, renamed, moved, copied, and deleted files
* Three-way text file merging; merge tracking and re-merge prevention; common ancestor detection
diffing, merging, and offline/online reconciliation tools
* Graphical file content history and branch history viewers
* Graphical administrative interface
* Image thumbnails
* Centralized, access-controlled repository with support for distributed revision control (see below)
* "Changelists" -- changed files can be grouped together and tracked as logical changes [Perforce "changelists" are similar to what other revision control systems refer to as "changesets".]
Atomic commits -- the server assures that changelists are committed in their entirety
* Support for ASCII,
Unicode, binary, symbolic link(on Unix), Mac-specific, and UTF-16 files
* Support for
internationalization and localization
* Support for RCS-style keyword expansion
* File compression for repository storage and network transfer
* Multi-platform, cross-platform -- single Unix or Windows server can support clients on any OS
* Server-side event triggers
* Programmable command line client and API
* SDK for integrating with external systems (e.g., defect tracking)
* Change notification by RSS; support for email change notifications
The Perforce system offers a hybrid of "merge" and "lock" concurrency models. [
Comparison of revision control softwaredescribes concurrency models in these terms.] As with similar systems,users do not have to lock files in order to work on them and are required toresolve concurrent, committed changes before submitting their work.Users may optionally lock files to assure that they won't have to resolve concurrent changes.
However, the Perforce model is slightly different from those of similar systemsin that users are expected to let the system know in advance which files theyintend to change, even if they don't mean to lock them.Giving advanced notice puts files in a "pending changelist" thatcan be submitted to the server.It also enables the system to alert other users working on the same files. Thus users can tell when they are working in parallel and can take the opportunity to coordinate with one another before making changes that could otherwise be a nightmare to merge.
Perforce enforces this advanced notification requirement loosely bysetting read-only permission on workspace files as it fetches themfrom the repository, and making files writable as the user specifies thatthey want to edit them. Users can bypass the requirement, by choice or by necessity (when working offline, for example), simply by hijacking file permissions and modifying files as they see fit.It is up to the user, in these cases, to remember to use Perforceto reconcile offline work and put hijacked files in a pending changelistso they can be submitted.
It is also up to users to leave hijacked files "writable" afterchanging them. In this sense, Perforce sees write permissions the wrong way around:a "read-only" file is assumed to be allowed to be overwritten, buta "writable" file is considered untouchable.
Branching and merging
A file is uniquely identified by its complete filename, e.g.,
//depot/trunk/src/item.cpp. Any non-deleted revision of a file can be branched.Perforce uses "inter-file branching", [Christopher Seiwald (1996). "Inter-File Branching: A Practical Method for Representing Variants".In "Software Configuration Management: ICSE '96 SCM-6 Workshop, Berlin, Germany", ed. Ian Sommerville, Springer, ISBN 354061964X.] wherein branching creates a new file with a new name.For example,
my/index.phpmay be branched into
your/index.phpand each file may then evolve independently.Repository paths are typically designated as containers for branched sets of files.For example, files in the
//depot/trunkpath may be branched as a setinto a new
//depot/rel1.0path, resulting in two sets of filesevolving independently and between which changes can be merged.
In Perforce the operation that merges changes from one branchto another is called "integration".Integration propagates changes from a set of donor files into a set ofcorresponding target files; optional "branch views" can store customized donor-target mappings.By default, integration propagates all outstanding donor changes.Donor changes can be limited or cherry-picked by changelist, date, label, filename, or filename pattern-matching,The system records all integrations, uses them to select common ancestorsfor file merging, and does not by default perform redundant or unnecessary integrations.
Merging is actually only one of three possible outcomes of an integration.The others are "ignoring" (aka "blocking") and "copying" (aka "promoting").Merging is used to keep one set of files up to date with another.For example, a development branch may be kept up to date with itstrunk through repeated merging.Ignoring disqualifies changes in one set of files from future integrationinto another. It is often used when a development branch must beup to date with, and yet divergent from, its trunk.Copying is typically used to promote the content of an up-to-date development branch into a trunk.
Branching is also used to rename and move files. The user branches originals to new files, deletes the originals, and submits both the new files and the deletions together. A branched file is no different than an added file;branched files are peers, not offshoots, of their originals.The system keeps track of file origins, however,and refers to them when displaying the history of renamed files.
Distributed revision control
Perforce has two mechanisms for achieving distributed revision control;these mechanisms can be used independently or in combination.The first is a proxy server that caches frequently read versions in order to reduce file access times for remote users.This mechanism accommodates closed development organizations where a centrally controlled file repository and a universally accessible database are desired.
The second mechanism, known as "remote depots", lets users connected to one server access file versions managed by other servers.With remote depots, each organization has control of its own server and makes parts or all of its repository visible to other servers.This mechanism is used for loosely coupled development organizations where a
peer-to-peerapproach is desired.
Access control and security
File access is controlled by one or more
superusers.A range of file access permission levels can be granted.Permissions can be set for repository file paths,
users, groups, and
IP addresssubnets.The server can maintain an audit log of file access events for SOX and other compliance requirements.Perforce does not encrypt the file content or metadatait sends over the network.A tunneling protocollike VPNor SSH must be used to secure network transfers.
Security is controlled by the Perforce system administrator.
Password strengthis configurable; ticket-based authentication can be configured as well. Triggers (custom scripts or programs that run at predefined events) can be set on many but not all Perforce user commandsand used to extend user authentication (with LDAPor SSO, for example), to block or allow user commands, and to constrain or normalize file modifications.Triggers are run by the Perforce server and do not have access to client machines or workspaces.
Availability, release cycle and supported platforms
Free downloads of Perforce server, client, and plugin software are available from
Perforce Software's website.Server and client software is typically released twice a year [ [http://www.perforce.com/perforce/news.html Perforce Software Updates] ] as pre-built executables for Microsoft Windows, Mac OS X, Linux, Solaris, FreeBSD, and other operating systems.
Use of the Perforce server is unrestricted for up to two users and five workspaces without a license. A license must be purchased for more users or workspaces.Free licenses are available for
open sourcesoftware development, school or classroom projects, and trial/evaluation periods.Use of Perforce client and plugin software is unrestricted, as isonline access to Perforce technical documentation.
As of December 2007, Perforce is licensed to more than 250,000 users at 4,500 organizations. [ [http://www.perforce.com/perforce/customers.html Perforce Customer Spotlight] ]
List of revision control software
Comparison of revision control software
* [http://www.perforce.com/ Perforce Software, Inc. website]
Wikimedia Foundation. 2010.
Look at other dictionaries:
Perforce — Entwickler Perforce Software Inc. Aktuelle Version 2010.2 (August 2011) Betriebssystem GNU/Linux, Windows, Mac OS X Programmiersprache … Deutsch Wikipedia
Perforce — (сокр. P4) коммерческая система управления версиями. Доступна бесплатная лицензия для двадцати пользователей. Разработана компанией Perforce Software, основанной в 1995 году. Система имеет клиент серверную архитектуру. Сервер Perforce может … Википедия
Perforce — est un outil de gestion de configuration propriétaire utilisé dans le processus de développement logiciel. Il est développé par la société éponyme. Il s interface avec n importe quel éditeur de code respectant le protocole SCCS. Il propose une… … Wikipédia en Français
Perforce — Per*force , adv. [F. par (L. per) + force.] By force; of necessary; at any rate. Shak. [1913 Webster] … The Collaborative International Dictionary of English
Perforce — Per*force , v. t. To force; to compel. [Obs.] [1913 Webster] … The Collaborative International Dictionary of English
perforce — early 14c., par force, from O.Fr. par force (12c.), lit. by force (see FORCE (Cf. force)). With L. per substituted 17c. for French cognate par … Etymology dictionary
perforce — ► ADVERB formal ▪ necessarily; inevitably. ORIGIN from Old French par force by force … English terms dictionary
perforce — [pər fôrs′] adv. [ME par force < OFr: see PER1 & FORCE] by or through necessity; necessarily … English World dictionary
perforce — adverb /pəˈfɔːs,pɚˈfɔɹs/ a) By force. If ſhe denie, Lord Hastings goe with him,And from her iealous Armes pluck him perforce. b) Necessarily. So, bevelling around by Mulletts and the Signal House which they shortly reached, they proceeded… … Wiktionary
perforce — [[t]pə(r)fɔ͟ː(r)s[/t]] ADV: ADV with cl, ADV with v Perforce is used to indicate that something happens or is the case because it cannot be prevented or avoided. [OLD FASHIONED] The war in 1939 perforce ushered in an era of more grime and… … English dictionary