Converting Extracted Data to Control-M

This procedure describes how to create a new conversion project in Self-Conversion, load the extracted data, define the conversion rules, convert the data to Control-M, and load it to the Control-M environment.

Before You Begin

Ensure the following:

  • Successful extraction of an XML file containing the extracted data you want to import to Control-M.

  • Successful completion of Setting Up Self-Conversion .

  • Successful completion of setting up a Control-M environment.

Begin

  1. From the Self-Conversion tool, in the Project Name field, type the name of the project.

  2. Do the following:

    • In the Description field, type a project description.

    • In the Load input Data field, select a file or folder.

    • In the Convert from field, type the vendor name of the scheduler you are converting from.

  3. From the Use Existing Conversion Rules drop-down list, select the required conversion rule.

    If the rule you require is not listed, you can import it using the Import button in the Conversion Rules tab. This enables you to import from your file system or from rules available in GitHub. For more information, see the Control-M Self-Conversion API community solutions GitHub repository.

  4. Click Create Project.

    The loaded data appears in the Conversion Rules Editor.

  5. In the Rules Category tabs, select the first tab (Folder).

  6. In the Conversion Rule for pane, select one of the specified rules, such as Create Folder or Folder Name.

  7. In the Conversion Rules Editor pane, define conversion rules using one or more of the following:

    • Script Mode: View the script template and click Edit Script to edit the rule logic.

    • Graphical Mode: Select the element in the source data, then select the operator, and then type in the required value of the converted element.

      If you edit the script rule, the Graphical Mode for the specific rule is disabled. If you want to enable the Graphical Mode for the specific rule, click Discard Changes.

    • General Script Mode: Select the General Script tab located in the upper right corner of the window, and then define Groovy scripts using the provided API. For more information, see Self-Conversion API.

      All Conversion Rule tabs are disabled when you edit script rules in General Script Mode,. To enable Conversion Rule tabs, click Discard Changes.

      You must insert @ConversionRule(<name of rule>) at the beginning of each rule. For example, @ConversionRule(Folder Name).

  8. Click Test and then from the drop-down list, do one or more of the following:

    • To verify that the script syntax is valid, click Test Rule Syntax .

    • To verify that the functionality works as expected, click Test Rule Functionality.

  9. Define conversion rules in the Job, Hierarchy, Job Types, and Events).

  10. After you have defined the conversion rules, click Run to convert the extracted source data to Control-M data.

    Alternatively, you can run the conversion using CLI. For more information, see Converting Control-M Self-Conversion in the CLI.

  11. Review the conversion results in the Conversion Results tab and view the Conversion Warnings.

  12. Click the Results tab and select Copy Folder Path to Clipboard.

  13. Load the converted file to the Control-M environment as described in Workspaces.

    If the converted data does not meet requirements, return to an earlier step in the Self-Conversion flow and try again (see Helix Control-M Self-Conversion).

Converting Control-M Self-Conversion in the CLI

This procedure describes how to convert your data to Control-M data using the Self-Conversion CLI utilty on Windows.

The Self-Conversion in the CLI enables you to automate the conversion process. The CLI utility converts the XML data input file using the JSON rules file that you created in the Self-Conversion GUI and returns the data result in XML format.

Before You Begin

Ensure the following:

  • Your input data is in XML format.

  • You have created a conversion rules file using the Control-M Self-Conversion GUI in JSON file format.

Begin

  1. From a command prompt, navigate the <conversion home>\SelfConversion\cli directory.

  2. Type the following command:

    SelfConversionCLI -inputData <input data in XML format> -convRules <conversion rules json file> --convResultFile <conversion result name> [-targetCtmversion <name of the Control-M version>]

    For more information, see the Self-Conversion CLI Parameters.

    Type the following command:

    selfconversioncli -inputData "C:\Conversion\New folder\sample_project\data\sample_input_2.xml" -convRules "C:\Conversion\New folder\sample_project\rules1.json" -convResultFile "C:\Conversion\New folder\sample_project\results.xml"

    The following text appears:

    Running SelfConversion from CLI

    Parameters used:

    inputData: C:\Conversion\New folder\sample_project\data\sample_input_2.xml

    convRules: C:\Conversion\New folder\sample_project\rules1.json

    convResultFile: C:\Conversion\New folder\sample_project\results.xml

    targetCtmVersion: 18

    Conversion completed successfully

    C:\Conversion\New folder\sample_project\results.xml created.

    Entities created:

    ----------------

    Control-M Folders: 1

    Control-M Sub Folders: 0

    Control-M Jobs: 6

    Job Types distribution:

    ------------------------

    OS: 3

    SAP R3: 1

    File Transfer: 2

Self-Conversion CLI Parameters

The following table describes the Self-Conversion CLI parameters:

Parameter

Description

inputData

Defines the full path of the input data that you are converting to Control-M.

convRules

Defines the full path of the conversion rules JSON file that was defined using the Control-M Self-Conversion GUI.

convResultFile

Contains the full path of the conversion results file.

targetCtmversion

Defines the name of the Control-M version that you want to convert to.

Default: The same version as the Self-Conversion GUI.