Deprecated feature

Join the custom process groups to the connector

In this lesson, you join the custom processor groups to your connector.

About this task

Use the following link for NiFi: http://ElasticSearchHostname:30600/nifi/

Note: This lesson uses the connector name "custom". Ensure that you replace "custom" with the name of the connector that you created in the previous step.

Procedure

To join the custom connector to the database, complete the following steps. Join the custom connector to your auth.reindex after the respective PriceStage. You can use either of the following options.
  • Option 1: Manually copy the custom process groups and attach them for both the toolkit and runtime environments.
    1. Select both the “custom.auth – ProfitMarginSchemaUpdateConnector” and “custom.auth – ProfitMarginDatabaseConnectorPipe” process groups.
    2. Right-click any one of the selected process groups and click Copy.

    3. To join the process groups to your auth.reindex or live.reindex, search for the respective PriceStage.

      HCL Commerce Version 9.1.9.0 or laterIn this example, the PriceStage Connectors are “auth.reindex - Price Stage 1b (Find Bundle Prices)” followed by “auth.reindex - WaitLink - Price Stage 1a”.

      HCL Commerce Version 9.1.11.0 or laterIn this example, the PriceStage process groups are “auth.reindex - Price Stage 1a (Find Product Prices)” followed by “auth.reindex - WaitLink - Price Stage 1a”.

      9.1.9+ 9.1.11+
    4. Paste the process groups that you copied in Step 2 in front of “auth.reindex - WaitLink - Price Stage 1a”.
      9.1.9+ 9.1.11+
    5. To establish a connection from the custom process groups to the existing pipeline, stop all the process groups with which the connection is to be established. To stop the process groups, select all the required process groups by pressing the Shift key and clicking all the process groups. Right-click any one of them and click Stop.

      HCL Commerce Version 9.1.9.0 or laterIn this example, you must stop “auth.reindex - WaitLink - Price Stage 1a” and “auth.reindex - CopyLink - Price (Copy To Product)”.

      HCL Commerce Version 9.1.11.0 or laterIn this example, you must stop “auth.reindex - WaitLink - Price Stage 1a” and “auth.reindex - Price Stage 1b (Find Bundle Prices)”.

      9.1.9+ 9.1.11+
    6. Delete all existing connections between the process groups.
      Table 1.
      9.1.9+ 9.1.11+

      After deleting the connection, the process groups appear as follows:

      Table 2.
      9.1.9+ 9.1.11+
    7. Move the mouse pointer over “auth.reindex - WaitLink - Price Stage 1a” and drag the arrow towards a process group to establish a connection. The Create Connection window opens.

      In this example, establish a connection from “auth.reindex - WaitLink - Price Stage 1a” to “custom.auth - ProfitMarginSchemaUpdateConnector”.

    8. In the Create Connection window, keep all the default values and click Add.

      A connection between WaitLink and the process group is now established.

      Table 3.
      9.1.9+ 9.1.11+
    9. Repeat steps 7 and 8 to establish connections between all the process groups:
      HCL Commerce Version 9.1.9.0 or later
      • Between custom.auth – ProfitMarginSchemaUpdateConnector and custom.auth - ProfitMarginDatabaseConnectorPipe.

      • Between custom.auth - ProfitMarginDatabaseConnectorPipe and auth.reindex - CopyLink - Price (Copy To Product).

      HCL Commerce Version 9.1.11.0 or later
      • Between custom.auth – ProfitMarginSchemaUpdateConnector and custom.auth - ProfitMarginDatabaseConnectorPipe.

      •  Between custom.auth - ProfitMarginDatabaseConnectorPipe and auth.reindex - Price Stage 1b (Find Bundle Prices).

    10. After all the connections are completed, start the process groups. To start the process groups, select all the required process groups by pressing the Shift key and clicking all the process groups. Right-click any one of them and click Start.
      9.1.9+ 9.1.11+

      The process groups are now started.

      9.1.9+ 9.1.11+
    11. After you manually copy and attach the process group, ensure that they point to the correct database.
      1. Right-click “custom.auth - ProfitMarginDatabaseConnectorPipe" and click Configure.
      2. Go to the Controller Services tab.

      3. If the controller service is enabled, disable Database Connection Pool by clicking the "cancelled lightning bolt" button.

      4. Click Configure (gear icon).
      5. Navigate to NiFi Flow » custom.auth - ProfitMarginDatabaseConnectorPipe > Custom Connector Pipe > Execute SQL and start Execute SQL and Split into single Json if required.

        • Update the following properties by replacing “AUTH” or “LIVE” as required:
          • Database Connection URL
          • Database Driver Location(s)
          • Database User
          • Database Driver Location(s)
      6. Set the value of the property Password and click Apply.
      7. Enable Database Connection Pool (lightning bolt button). Ensure that there are no errors when the controller services are enabled. If a red icon is displayed in the first column of the controller service, you might need to review and fix the errors.
      8. On the Controller Services tab, enable Json Record Set Writer and Json Tree Reader.
      After this step, the connections between the custom connector are as follows:
      9.1.9+ 9.1.11+
  • Option 2: Upgrade connector descriptor of the existing connector using Ingest API, as described in Upgrade connector descriptor of the existing connector.
    After this step, the connections between the custom connector are as follows for the Runtime environment.
    9.1.9+ 9.1.11+

Results

Now, the custom process groups are added to the connector.