Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Sivasamy 13 posts 33 karma points
    Apr 28, 2015 @ 08:52
    Sivasamy
    0

    Exporting as XML for upgrading to new version

    There are not much detail can be found on Export from uMirror hence raising this query. 

    We would like to export and synch all the nodes from version 1 of our site to version 2 using uMirror. our scenario is that doc types contain few new fields on version 2 and it is mentioned we could map the fields before import.

    When I tried to create a task on uMirror and try export, it is not creating the XML file on the folder (/App_Data/somefile.xml) as it is only about nodes being added from the date of uMirror package install.

    How can we achieve this export process and synch articles on version 2 of our site?

     

     

     

     

     

  • Antoine 176 posts 1494 karma points
    Apr 28, 2015 @ 11:32
    Antoine
    0

    Hi Sivasamy

    In this case, your datasource will be the version 1 umbraco.config, copy this file into version 2 /App_Data/Legacy/umbraco.config and set the path as your datasource in uMirror's setting.

    This process can be automated using proxy method, in this case you have to implement a proxy method with execute the same steps.

    Does it make sens?

  • Sivasamy 13 posts 33 karma points
    Apr 28, 2015 @ 11:50
    Sivasamy
    0

    Thanks for the reply.

    On the documentation I could only find limited information on the proxy, can you give some sample code/link that contains an import work?

  • Antoine 176 posts 1494 karma points
    Apr 28, 2015 @ 12:10
    Antoine
    0

    Can this help you:

    public class uMirrorProxy : uMirrorExtension
    {
        const string TargetFilePath = "\\App_Data\\legacy\\umbraco.config"; //(version 1)
        const string LegacyFilePath = "c:\\....\\App_Data\\umbraco.config"; //(version 2)
    
        [UMirrorProxy(TargetFilePath)]
        public static void uMirrorProxyMethod()
        {
            // Here, you have to copy the file LegacyFilePath (version 1) to TargetFilePath (version 2)
            // During this process, you can (if you need it) prepare or adapt data for your 
    // importation (media path, related content...) // Every time uMirror start a process, it will execute this first } }
  • Sivasamy 13 posts 33 karma points
    Apr 28, 2015 @ 12:17
    Sivasamy
    0

    This proxy imports data from 'TargetFilePath' using the commands we specify inside the method that we created? For example we have to create the node and place the data from legacy umbraco.config and publish?

  • Antoine 176 posts 1494 karma points
    Apr 28, 2015 @ 12:56
    Antoine
    0

    Once you have created the proxy method, create a new uMirror project, select the method, save and click on "test method", this will execute your method.

    Once the XML copied on 'TargetFilePath', you can create your mapping betwen your doctypes

  • Sivasamy 13 posts 33 karma points
    Apr 28, 2015 @ 15:11
    Sivasamy
    0

    The method that we create would be available part of the uMirror to select and run, I can understand. And my idea is that the mapping would be like creating a new node referring to the v2 doctype and transferring values from the XML. I would like to know if uMirror supports reducing the effort of doing this with plain C# code by having its own library methods?

  • Sivasamy 13 posts 33 karma points
    Apr 29, 2015 @ 08:40
    Sivasamy
    0

    I've raised this request because the sample given on uMirror document talks about transferring data from an RSS feed into an XML file not the Umbraco node with existing document type.

  • Antoine 176 posts 1494 karma points
    Apr 29, 2015 @ 09:28
    Antoine
    0

    You can transferring data from an RSS feed as well but through a proxy method, the current version doesn't have this feature out of the box.

    We add the task in our backlog but we didn't implemented it already, any PR is welcoming :)

Please Sign in or register to post replies

Write your reply to:

Draft