Migrate TFS in different Culture

Dec 9, 2008 at 7:39 PM
Is it possible to migrate a french single TFS 2008 server to a english TFS 2008 single server ? How ?
Coordinator
Dec 9, 2008 at 10:22 PM

The TFS to TFS migration tool uses the public TFS API's that are language independent. However, all of our testing has been on English servers. 

We always recommend doing a test migration before migrating to the production target server, and I think this is particularly important for your situation.  A few others have asked about cross-language migrations were possible in the past and I told them the same thing I’m telling you.   To the best of my knowledge they never updated their status as to whether they were successful or not. 

Thanks
Curtis

 

Jan 13, 2009 at 7:33 AM

The source code migration seems to run, but we have problems with Work Item. Mapping between French properties and English ones is not done. So we have these kind of errors : 

Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ProvisionValidationException: TF26177: The field System.Title cannot be renamed from 'Title' to 'Titre'.
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ImporterField.Update(XmlElement fieldElement)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ImporterFields..ctor(ImporterData sharedData, XmlNodeList fieldNodes)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.WITImporter.ImportFieldDefinitions(XmlElement root)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.WITImporter.Translate(XmlElement element)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ProvisionClass.ImportValidateWorkItemTypeInternal(Int32 projectId, String methodologyName, XmlElement typeElement, ActionType action)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ProvisionClass.ImportWorkItemType(WorkItemStore ws, Int32 projectId, String methodologyName, XmlElement typeElement, ImportEventHandler handler)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.WorkItemTypeCollection.Import(XmlElement definitionElement)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.TfsMigrationWorkItemStore.SyncWorkItemTypes(Project p)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.TfsMigrationWorkItemStore.SynchronizeMetadata(Project project)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.SyncProcess.SynchronizeMetadata()
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.SyncProcess.ItemsSyncPass(IEnumerable`1 items)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.SyncProcess.SinglePass()
   at Microsoft.TeamFoundation.Migration.Toolkit.WorkItemTrackingSession.Synchronize(SystemType primarySystem)

System.Xml.Schema.XmlSchemaValidationException: The 'WHENNOTCHANGED' element is not declared.
   at System.Xml.Schema.XmlSchemaValidator.SendValidationEvent(XmlSchemaValidationException e, XmlSeverityType severity)
   at System.Xml.Schema.XmlSchemaValidator.SendValidationEvent(String code, String arg)
   at System.Xml.Schema.XmlSchemaValidator.ThrowDeclNotFoundWarningOrError(Boolean declFound)
   at System.Xml.Schema.XmlSchemaValidator.ValidateElement(String localName, String namespaceUri, XmlSchemaInfo schemaInfo, String xsiType, String xsiNil, String xsiSchemaLocation, String xsiNoNamespaceSchemaLocation)
   at System.Xml.XsdValidatingReader.ProcessElementEvent()
   at System.Xml.XsdValidatingReader.ProcessReaderEvent()
   at System.Xml.XsdValidatingReader.Read()
   at System.Xml.XmlLoader.LoadNode(Boolean skipOverWhitespace)
   at System.Xml.XmlLoader.LoadDocSequence(XmlDocument parentDoc)
   at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
   at System.Xml.XmlDocument.Load(XmlReader reader)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ProvisionClass.GetXml(XmlReader reader, SchemaType schema)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ProvisionClass.GetXml(XmlElement element, SchemaType schema)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ProvisionClass.ImportWorkItemType(WorkItemStore ws, Int32 projectId, String methodologyName, XmlElement typeElement, ImportEventHandler handler)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.WorkItemTypeCollection.Import(XmlElement definitionElement)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.TfsMigrationWorkItemStore.SyncWorkItemTypes(Project p)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.TfsMigrationWorkItemStore.SynchronizeMetadata(Project project)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.SyncProcess.SynchronizeMetadata()
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.SyncProcess.ItemsSyncPass(IEnumerable`1 items)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.SyncProcess.SinglePass()
   at Microsoft.TeamFoundation.Migration.Toolkit.WorkItemTrackingSession.Synchronize(SystemType primarySystem)

System.Xml.Schema.XmlSchemaValidationException: The 'FIELD' element is not declared.
   at System.Xml.Schema.XmlSchemaValidator.SendValidationEvent(XmlSchemaValidationException e, XmlSeverityType severity)
   at System.Xml.Schema.XmlSchemaValidator.SendValidationEvent(String code, String arg)
   at System.Xml.Schema.XmlSchemaValidator.ThrowDeclNotFoundWarningOrError(Boolean declFound)
   at System.Xml.Schema.XmlSchemaValidator.ValidateElement(String localName, String namespaceUri, XmlSchemaInfo schemaInfo, String xsiType, String xsiNil, String xsiSchemaLocation, String xsiNoNamespaceSchemaLocation)
   at System.Xml.XsdValidatingReader.ProcessElementEvent()
   at System.Xml.XsdValidatingReader.ProcessReaderEvent()
   at System.Xml.XsdValidatingReader.Read()
   at System.Xml.XmlLoader.LoadNode(Boolean skipOverWhitespace)
   at System.Xml.XmlLoader.LoadDocSequence(XmlDocument parentDoc)
   at System.Xml.XmlLoader.Load(XmlDocument doc, XmlReader reader, Boolean preserveWhitespace)
   at System.Xml.XmlDocument.Load(XmlReader reader)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ProvisionClass.GetXml(XmlReader reader, SchemaType schema)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ProvisionClass.GetXml(XmlElement element, SchemaType schema)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.Provision.ProvisionClass.ImportWorkItemType(WorkItemStore ws, Int32 projectId, String methodologyName, XmlElement typeElement, ImportEventHandler handler)
   at Microsoft.TeamFoundation.WorkItemTracking.Client.WorkItemTypeCollection.Import(XmlElement definitionElement)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.TfsMigrationWorkItemStore.SyncWorkItemTypes(Project p)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.TfsMigrationWorkItemStore.SynchronizeMetadata(Project project)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.SyncProcess.SynchronizeMetadata()
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.SyncProcess.ItemsSyncPass(IEnumerable`1 items)
   at Microsoft.TeamFoundation.Migration.Toolkit.Wit.SyncProcess.SinglePass()
   at Microsoft.TeamFoundation.Migration.Toolkit.WorkItemTrackingSession.Synchronize(SystemType primarySystem)

Is it possible in your tool to implement a mapping between English Fied like Reason, Title, CreatedBy... to the equivalent in other culture like TFSLocalize.exe do or that example in this link http://www.sch0.org/blog/TFSLocalizeMapping.xml ?

Apr 15, 2009 at 4:23 PM
Hi!

I try to synchronize work items between TFS 2008 SP1 Russian and TFS 2008 SP1 English.

I cant see errrors in log file

TfsMigrationWindowsServiceHost.exe Information: 0 : Connecting to 'http://server-rus:8080/'
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:37.7326457Z
TfsMigrationWindowsServiceHost.exe Information: 0 : Connected to 'http://server-rus:8080/'
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:38.9983193Z
TfsMigrationWindowsServiceHost.exe Information: 0 : Connecting to 'http://server:8080/'
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:39.3108313Z
TfsMigrationWindowsServiceHost.exe Information: 0 : Connected to 'http://server:8080/'
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:39.5608409Z
TfsMigrationWindowsServiceHost.exe Information: 0 : Connecting to 'http://server-rus:8080/'
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:39.5764665Z
TfsMigrationWindowsServiceHost.exe Information: 0 : Connected to 'http://server-rus:8080/'
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:39.5764665Z
TfsMigrationWindowsServiceHost.exe Information: 0 : Getting modified items from 'TFS!http://server-rus:8080/ (ПР hgf JHG ро РПА 5)'
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:39.6233433Z
TfsMigrationWindowsServiceHost.exe Information: 0 : TFS Query: SELECT [System.Id], [System.Rev] FROM WorkItems WHERE ([System.TeamProject]=@Project AND ([System.WorkItemType]='Ошибка')) ORDER BY [System.Id]
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:39.6233433Z
TfsMigrationWindowsServiceHost.exe Information: 0 : TFS Query: returned 1 item(s)
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:39.7483481Z
TfsMigrationWindowsServiceHost.exe Information: 0 : Received modified items from 'TFS!http://server-rus:8080/ (ПР hgf JHG ро РПА 5)'
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:39.7639737Z
TfsMigrationWindowsServiceHost.exe Information: 0 : Connecting to 'http://server:8080/'
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:39.7795993Z
TfsMigrationWindowsServiceHost.exe Information: 0 : Connected to 'http://server:8080/'
    LogicalOperationStack=
    ThreadId=4
    DateTime=2009-04-15T15:10:39.7795993Z
Update package was fully optimized - no changes to the existing data!
TfsMigrationWindowsServiceHost.exe Information: 0 : Getting modified items from 'TFS!http://server-rus:8080/ (ПР hgf JHG ро РПА 5)'
    LogicalOperationStack=
    ThreadId=3
    DateTime=2009-04-15T15:10:43.4047385Z
TfsMigrationWindowsServiceHost.exe Information: 0 : TFS Query: SELECT [System.Id], [System.Rev] FROM WorkItems WHERE ([System.TeamProject]=@Project AND ([System.WorkItemType]='Ошибка')) ORDER BY [System.Id]
    LogicalOperationStack=
    ThreadId=3
    DateTime=2009-04-15T15:10:43.4047385Z
TfsMigrationWindowsServiceHost.exe Information: 0 : TFS Query: returned 1 item(s)
    LogicalOperationStack=
    ThreadId=3
    DateTime=2009-04-15T15:10:43.4359897Z
TfsMigrationWindowsServiceHost.exe Information: 0 : Received modified items from 'TFS!http://server-rus:8080/ (ПР hgf JHG ро РПА 5)'
    LogicalOperationStack=
    ThreadId=3
    DateTime=2009-04-15T15:10:43.4359897Z
Update package was fully optimized - no changes to the existing data!

But there is no Sync WI and in UI (Migration Activity) tells what "Synchronazation engine has crashed"

By the way

TFS to TFS Migration Toolkit setup and run on 'server' and migration between 'server' and 'server' works fine.
Migration between 'server-rus' and 'server-rus' works fine too.

What happand when i try to sync 'server'  and 'server-rus'?
Any ideas?
Apr 15, 2009 at 11:45 PM
HOTDOC,

The trace information isn't enough to tell what went wrong. I suspect that the failure was a result of similar problem mentioned in previous post on this thread.

Here is my guess. Tfs2Tfs Migration Tool generates a configuration without specific setting on the Work Item Type Definition (WITD) syncing. The Tfs Migration Toolkit takes default action by importing whatever WITD is exported from the source server (say, English version) to the targer server (say, Russion version). This causes the target server to fail as the English WITD from source server contains English field name, which is not compatible on the target server. So, if you know that you are migrating betwee two compatible Work Item Type, e.g. Agile Bugs, you may want to disable WITD sync and then retry the session. Please take a look of the config file schema defined in the Toolkit source code (Toolkit/Configuration/Schema.xsd). The element type of your interest is called "MetadataSynchronizationElement".

Additionally, you will need to modify the configuration file to provide explicit mapping between fields. Please take a look of the "WITFieldMappingElement".

As Curtis pointed out, migration cross cultured TFS servers are not tested. I do wish you good luck and success.

Terry
Apr 16, 2009 at 9:49 AM
Edited Apr 16, 2009 at 10:02 AM
Hi! teyang!

Tanks for advice!

I found "Toolkit/Configuration/Schema.xsd" and "MetadataSynchronizationElement"

<xs:complexType name="MetadataSynchronizationElement">
    <xs:all>
      <xs:element name="IgnoredTypes" type="NamesCollection" minOccurs="0">
        <xs:unique name="UniqueIgnoredTypeName">
          <xs:selector xpath="Name"/>
          <xs:field xpath="@value"/>
        </xs:unique>
      </xs:element>
      <xs:element name="IgnoredLists" type="NamesCollection" minOccurs="0">
        <xs:unique name="UniqueIgnoredListName">
          <xs:selector xpath="Name"/>
          <xs:field xpath="@value"/>
        </xs:unique>
      </xs:element>
    </xs:all>
    <xs:attribute name="types" use="optional" default="all">
      <xs:simpleType>
        <xs:list>
          <xs:simpleType>
            <xs:restriction base="xs:string">
              <xs:enumeration value="accounts"/>
              <xs:enumeration value="lists"/>
              <xs:enumeration value="types"/>
              <xs:enumeration value="all"/>
            </xs:restriction>
          </xs:simpleType>
        </xs:list>
      </xs:simpleType>
    </xs:attribute>
  </xs:complexType>

and "WITFieldMappingElement"

  <xs:complexType name="WITFieldMappingElement">
    <xs:attribute name="tfs" type="NonEmptyString" use="required"/>
    <xs:attribute name="other" type="NonEmptyString" use="required"/>
    <xs:attribute name="fieldMap" type="NonEmptyString" use="optional"/>
  </xs:complexType>

But i have no idea how must i change "Schema.xsd" to make TFS understend field "Название" (from TFS-RUS)

Could you try to write example to map WorKItemType ("Ошибка" to "Bug") and WorkItemField ("Название" to "Title")

Tanx A lot.

By the way I create two empty project based on Agile 4.2. I use English template on TFS, and Russian template on TFS-RUS

After a run sync all WorkItem Types (Bug, Risk and so on) excape from Project on TFS.

Now i try to import Russian version of WorkItem in English TFS.
Apr 16, 2009 at 4:38 PM
HOTDOC,

The schema file is for your reference. What you need to modify is the configuration xml file generated by the Tfs2Tfs Migration Tool. After you create a session, the tool saves this config file to your working directory.
The default Metadata Sync setting is "all". To achieve what I mentioned earlier, you can make "lists" and "accounts" explicit, to suppress syncing "types" (Work Item Types). Please also refer to this page (http://migrationsynctoolkit.codeplex.com/Wiki/View.aspx?title=Configuration%20Files) for detailed documentation on the configuration. A more detailed sample config can also be found here: [YourInstallDir]\Source\Docs\SampleConfig.xml

Thanks,
Terry