How Changes Migrate Through the Stream Hierarchy

AccuRev provides configuration-management capabilities that are sophisticated and robust, without sacrificing ease of use. What’s the secret? One main reason is that AccuRev sees the development environment in the same way as a typical development team:

  • Many development tasks are active concurrently, all using the same source base.
  • Tasks are often interrelated. They must share their changes with each other (integration) and weed out inconsistencies. Some tasks cannot be completed until one or more others have been completed.
  • Most tasks are accomplished by making changes to relatively few files.
  • A task is completed by delivering a set of changes to another task. For example, a development task might deliver its changes to an integration task, or to a testing task.
  • A developer’s next task may involve changing a completely different set of files from the previous task.

AccuRev streams neatly model all these aspects of development tasks. The (relatively few) files that a developer changes for a task become active in a particular stream. Typically, this occurs when the developer records new versions of the files. To complete the task, or to mark an intermediate milestone, the developer delivers the changes to the parent stream, using the promote command. The files become active in the parent stream, and inactive (not under active development) in the child stream.

In a multiple-level stream hierarchy, several promotions are required to propagate a set of changes all the way to the top level. Each promotion causes the file(s) to become active in the to stream, and inactive in the from stream.

AccuRev terminology: the set of elements (files and directories) that are currently active in a particular stream constitute the default group of that stream. When an element is active within the stream, it is considered a member of that stream.

You may have gotten the impression that a given file can be active in only one stream at a time. Not so, that would mean only one development task at a time could be actively working on the file. AccuRev allows each file to be active in any number of streams, even all of the streams at once. Typically, though, a file is active in just a few streams at any particular moment.

The diagram below uses contrasting colors to show how a particular file might be active in four different streams. That is, four different versions of the same file are in use at the same time, for various development tasks.