In this video, we’ll explore how to do lightweight branching using Task Streams.
Task Streams are sparse branches that work just like a regular stream, but are semi-private. They are lightweight branches ideally suited for short-term work that will only affect a small number of files within a full-project branch.
Branch creation typically generates permanent metadata and grows with each integration. An advantage of Task Streams is that most of the metadata is temporary – kept in a separate set of private tables. When Task Streams are deleted or unloaded, it’s metadata on unchanged files is also removed, thus having minimal impact on the Perforce service.
You isolate your work on a single task, until it’s ready to share. Some uses are for small-to-medium features and bug fixes.
To create a Task Stream, context-click a stream to Create a New Stream.
Select “task” from the Stream-type drop-down.
Give your Task Stream a unique name.
Verify the depot location and parent stream.
Task Streams have this icon and appear as a child of it’s parent. Integration indicators are present.
Task Streams are semi-private because only client workspaces associated with a Task Stream can see the files and activity in the stream. Only changed files submitted to the Task Stream are visible to other users.
Task Streams are intended to be unloaded or deleted after you’ve submitted your changed files. Only the submitted files remain in the depot after a Task Stream is removed, thus the data generated is lightweight.
Unloading allows a Task Stream to be restored. Your Admin needs to create a Depot with the Type defined as “unload” in order to enable unloading. See this blog for more information:
To delete a Task Stream, which is the permanent option, right-click on the Stream, and select, “Delete Stream (‘stream name’)”.
Note that Task Streams cannot have child streams and they cannot be reparented. You will have to convert your Task Stream to a Development Stream if you need to reparent or branch your stream.
To manually convert a Task Stream, context-click on the stream and select, “Edit Stream (‘stream name’)”. In the drop-down, select either release or Development as the stream type.
Thanks for watching.