Willy's Reflections - Visual Studio ALM Rangers

| Willy-Peter Schaub | Visual Studio ALM Rangers | In search of IT simplicity, quality and tranquility |

TFS Integration Platform – How to enable or disable migrating history for source files: Question & Answer 19

TFS Integration Platform – How to enable or disable migrating history for source files: Question & Answer 19

  • Comments 6

Question

The question we received was “how to enable or disable migrating history for source files”, using the TFS Integration Platform.Blue Person Using A Paintbrush On A Flat Screen Computer Monitor To Create An Image, Or This Could Be A Designer Designing A Website Clipart Illustration Graphic

Thanks to Hyung we have a quick overview and configuration example to share.

Overview (Answer)

TFS Integration Platform supports migrating VC Changesets after a Changeset X, known as snapshot mode. The starting point is configurable and instructs the VC Provider to:

  1. Do a recursive get at the snapshot point on the mapped path
  2. Check-in everything as "add" to the target system (IMPORTANT: history before snapshot point will not be migrated)
  3. Continue migration after the snapshot point

Snapshot point

TFS Integration Platform supports a global snapshot point as well as path-level snapshot point.

Global snapshot point

A global snapshot point, it will be used for all mapped paths (FilterPairs) except the ones that have path-level snapshot points configured.

   1: <CustomSettings>
   2: <SettingXml>
   3:   <VCSessionCustomSetting>
   4:  <Settings>
   5:    <Setting SettingKey="SnapshotStartPoint" SettingValue="&lt;reference to MigrationSourceGUID>;<changeset number where history starts>" />
   6:  </Settings>
   7:   </VCSessionCustomSetting>
   8: </SettingXml>
   9: </CustomSettings>

Example:

<Setting SettingKey="SnapshotStartPoint" SettingValue="1F87FF05-2E09-49c8-9E9B-0AC6DB9DD595;100000" />

Path level snapshot point

This is the most common use of the VC snapshot feature.

   1: <xs:element minOccurs="2" maxOccurs="2" name="FilterItem">
   2: <xs:complexType>
   3: <xs:attribute name="MigrationSourceUniqueId" type="GUID" use="required" /> 
   4: <xs:attribute name="FilterString" type="xs:string" use="required" />       
   5: <xs:attribute name="SnapshotStartPoint" type="xs:string" use="optional" /> 
   6: <xs:attribute name="MergeScope" type="xs:string" use="optional" /> 
   7: </xs:complexType>
   8: </xs:element>

Example:

<FilterPair>
  <FilterItem MigrationSourceUniqueId="1F87FF05-2E09-49c8-9E9B-0AC6DB9DD595" 
                    FilterString="$/test1/feature1" 
                    SnapshotStartPoint="200000" />
  <FilterItem MigrationSourceUniqueId="8C85D8EB-F3B3-4f05-B8DC-C0AB823F1A44" 
                    FilterString="$/test1/feature1" />
</FilterPair>

We are planning two new guidance documents, focused on configuration and conflict resolution, which will address a lot of the questions we have received to date. Keep an eye on our blog for information in this regard.

  • Is this the same process that would be used for a 2008 to 2012 migration?

  • Where can I find the "reference to MigrationSourceGUID"?

  • Kerry, yes the snapshot feature is the same for 2008/2010/2012 migrations.

  • Kerry, the MigrationSourceUniqueId defines the source and target sessions. See blogs.msdn.com/.../tfs-integration-platform-configuration-question-answer-9.aspx which shows a more complete configuration file and refer to line (2) which define a Left (source) and Right (target) session, which are the GUIDs you would be using.

  • Willy, Kerry's question was *where* does one find the Guid for the MigrationSourceGUID? Which is what i'm curious about too...

  • @John/@Kerry, the GUID is generated when you create a session using the administration tool and you can find it in the session configuration XML.

Page 1 of 1 (6 items)
Leave a Comment
  • Please add 5 and 3 and type the answer here:
  • Post