Opalis to Orchestrator Source Code Conversion Script
This PowerShell script can be used to covert existing source code written to the Opalis 6.3 (QIK 3.0) API to be compatible with Orchestrator 2012's SDK.
Migrating QIK API Custom Activities
NOTE: The following procedure will modify your source code. It is your responsibility to ensure that you maintain a backup copy of your source code in the event of an error in the script or other process!
- If your source code is maintained under a source control program, ensure that your latest versions are checked in and saved. If you are not using a source control program, make a backup copy of your source code and store it in a separate directory.
- Obtain the migration script (“QIKtoSCO-Migration.ps1”).
- Click Start > All Programs > Accessories > Windows PowerShell > Windows PowerShell ISE. The PowerShell script editor opens.
- Open the script in the editor by clicking File > Open and then browsing to and selecting the QIKtoSCO-Migration.ps1 file. The script should be displayed in a tab in the script pane.
- Run the script using the green arrow icon in the toolbar. This loads the functions of the script in memory.
- Locate the root directory of the source code project you wish to migrate and note the full path.
- In the Command Pane of the PowerShell editor, type: ReplaceSDKText –dirname “<dir>” (replacing <dir> with the full or relative path to the root of the project in step 6).
- As the script runs, it will display a list of all files scanned and the files that were changed.. Note that not all files that are scanned will have changes.
- When the process is complete, you should review the output window to ensure that no errors occurred. If any errors did occur, you may need to manually remediate those issues. If the errors were substantial, you may need to re-copy the source files into that location and re-run the script to migrate the code.
- When migration is complete and you have fixed any errors, close the PowerShell ISE application and return to your source code editor.
- Perform a build with the updated source code. Find and fix any errors in the code.
One issue you are likely to encounter is that while the script updated any references in .csproj files to the Opalis.QuickIntegrationKit.dll so it now points to the new Microsoft.SystemCenter.Orchestrator.Integration.dll file, the new file must physically exist in the directory where the previous assembly was located. Simply copy the new reference assembly to that directory, or you can update the reference to point to a different location.