- Downloading the image
- Uploading the image to SDL Media Manager
- Creating a program and distribution in SDL Media Manager
- Putting the distribution Live
- Finding the "using components" in SDL Web and updating each one by replacing the relationship to the image in SDL Web with the relationship to the equivalent image in SDL Media Manager.
- SDL Web Core Service client
- SDL Web Stream Download client
- SDL Media Manager client
- ECL Service client
- A spreadsheet mapping the SDL Web (Tridion) folder structures to the equivalent folder structures in Media Manager.
- A directory used for storing the images downloaded from SDL Web for uploading to Media Manager.
- The tcmid of the schema (asset type) to be migrated. In the listing above, the tcm:5-33-8 corresponds to the Image multimedia schema.
- The name of the asset type (as defined in Media Manager) to be migrated.
- The named of the outlet (as defined in Media Manager) to be used when creating the distributions in Media Manager.
- The name of the tag (as defined in Media Manager) to be used when uploading and creating the assets in Media Manager.
The Media Manager API does not support the creation of folders. Therefore, before migration can take place, the folder structures in SDL Web must be replicated in Media Manager to accommodate the assets. The TridionToMediaManagerFolderMappingsFile configuration property specifies a spreadsheet containing the full mappings between the existing folder structures in SDL Web and the equivalent folders created in SDL Media Manager.
Downloading assets from SDL Web (Tridion)
The code for downloading assets from SDL Web is shown below.Uploading to SDL Media Manager
The code for uploading to SDL Media Manager is shown below. This code also creates the program, the distribution and puts the distribution live.Updating the relationships in SDL Web (Tridion)
The download and upload steps complete the process of migrating assets from SDL Web to SDL Media Manager. However, it is also important to update the components using the migrated asset by swapping the reference for the new asset in SDL Media Manager.This step relies on a SessionAwareEclServiceClient only available through a netTcpBinding which is not exposed. Therefore, a solution invoking this service can only run on the CME server itself.
The code below takes the core service and ECL clients, the migrated SDL Web multimedia component and a Dictionary object containing information gathered during the upload process. This information includes the distribution id, which is used to create or get the stub to the asset originating from Media Manager.