Running an end-to-end flow (HelloWorld sample)

The HelloWorld sample is an IBM® Integration Bus (IIB) message flow and an analytic simulator in one. Instead of calling an analytic for a score and assessment, the sample simulates an analytic response.

Before you begin

Download the Hello World sample files to the client system's desktop. This sample is located on the Data server only in the /icfminstall/cfm20_install/installs/instance_name/cfm20/application/CFM/samples/HelloWorld directory.

Procedure

To verify your system configuration and connections:

  1. Log in as a member of the Administrator role and click Menu > Content Packs.
  2. In the Content Packs view, click System Status to ensure that your system is configured correctly and has a valid connection. System Status verifies that the system is set up for a successful deployments, including the HelloWorld sample and other content pack (.cfar) files.

    System Status displays a dialog that shows the connectivity to the components of IBM Counter Fraud Management. The system check for a component fails if the system properties or credentials are configured incorrectly, or if the system is not started.

  3. Review and fix any resulting error or warning messages and then click OK to close the window. To diagnose deployment issues, change to the icfmlog/WebSphere/AppServer/profiles/ICFMProfile/logs/ICFMServer directory to view the SystemOut.log file. If you enabled tracing to log additional information, see the trace.log file.

To deploy the HelloWorld sample:

  1. From the Content Packs view, select Counter Fraud Content Packs and click Add.
  2. Browse and select the HelloWorld.cfar file and click OK.
    Note: The Hello World content pack (HelloWorld.cfar) is located in the CFM/samples/HelloWorld directory in the ICFM distribution package.
  3. Expand the IBM Counter Fraud Content Packs folder and click HelloWorld.cfar. Then click the sample folder to display the HelloWorld object in the right pane.
  4. Select HelloWorld and then click Deploy UseCase.
  5. Click Close when the status displays that the deployment was successful. Deployment creates a queue that is named AF.HELLOWORLD, adds sample data to the Counter Fraud database, and registers an analysis flow with supporting initialization criteria and assessment action. The sample data consists of Party, Event, Account, and Transaction objects with IDs that range from -1001 to -1020. The analysis flow is created in the Submitted state with the name "Hello World."

To inspect and approve the analysis flow:

  1. Click Menu > Analysis Flows.
  2. Expand the Hello World folder and click Hello World 1.0.0 (Submitted).
  3. Click Assessment Actions to add actions for the assessment values.
    1. Click Add to display a new row in the table. Then click the areas in the columns to complete the following information:
      Table 1. Example Hello World Assessment Actions
      Assessment Value Action Type Action Name Action Description Action Stereotype Action Value
      High Create or Update Folio Any name, such as Name_createDescription Description text createDescription ${alertDescription}
      High Create or Update Folio Any name, such as Name_createName Description text createName High Hello World
      Medium Create or Update Folio Any name, such as Name_createDescription Description text createDescription ${alertDescription}
      Medium Create or Update Folio Any name, such as Name_createName Description text createName Medium Hello World
      Low Create or Update Folio Any name, such as Name_createDescription Description text createDescription ${alertDescription}
      Low Create or Update Folio Any name, such as Name_createName Description text createName Low Hello World
      Notes:

      The available Action Stereotypes include the following values:

      • createBasket generates an investigation in this in-basket. By default, the investigation is created in the Undefined in-basket which is not expose to the any of the Roles by default. You can add the property to specify the in-basket you want this investigation created in.
      • createDescription creates an investigation with this description. In the examples in the table, the ${alertDescription} variable is passed back by the analytic for substitution.
      • createName creates an investigation with this name. The analysis flow creates an investigation when the assessment value is "High", "Medium," or "Low."

      Example of Assessment Actions

  4. Verify the initialization criteria. The following initialization criteria is displayed.
    Table 2. Initialization criteria
    Field name Value
    Type All Party Lookup
    Description Initiates an analysis flow based on any party
    Notes:
    • The Hello World analysis flow triggers on all party input messages.
    • You can add other initialization criteria, for example, to test additional message content.
  5. After you complete all edits to the Assessment Actions and Initialization Criteria, set the lifecycle state to Approved..
    Important: After an analysis flow is approved, the Initialization Criteria and Assessment Actions values cannot be changed in the analysis flow.
    1. Click Set Lifecycle State.
    2. Click Approved.

To trigger the analysis flow:

  1. Use the content of the sample_party_lookup.xml file and add it as a test message to the CF.ANALYSIS.REQUEST queue.

    The message triggers the analysis flow and an investigation is created in the Undefined in-basket or in the basket that is defined for createBasket.

    You can repeat this step several times if needed. As a result of this test message, the Hello World analytic runs and posts assessment results to the database. New investigations are created as the input messages are received.

To expose custom properties:

  1. Optional: Expose custom properties in the investigation. By default, custom properties and properties that are added by an analytic are not listed in an investigation. The following example shows how to expose a custom property named VehicleColor.
    1. Click Menu > Code Tables.
    2. From the Code Type list, select CFFOLIO.FOLIO_PROPERTY_TYPE.
    3. Click Add. A row is added for the new property.
    4. In the column, enter the new stereotype, such as VehicleColor.
      Table 3. Custom Property Values
      Field Name Value
      Stereotype VehicleColor
      Name (Default) Vehicle Color
      Description Custom property
    5. Click Save.
    6. On the Data server, open a DB2® command prompt and enter the following command on a single line:
      INSERT INTO CFFOLIO.CONTEXT_AVAILABLE_PROPERTIES (FOLIO_PROPERTY_TYPE_ID,CONTEXT_ID,PROMINENCE,READ_ONLY) 
      VALUES ((SELECT FOLIO_PROPERTY_TYPE_ID from "CFFOLIO"."FOLIO_PROPERTY_TYPE" WHERE STEREOTYPE = 'VehicleColor'), 
      (SELECT CONTEXT_ID from "CFFACT"."FRAUD_ASSESSMENT_CONTEXT" WHERE STEREOTYPE = 'HWCONTEXT'), 1, 0);
      The Vehicle Property property is displayed in the Details page of the investigation.
    Attention: If you are unable to expose custom properties to the investigation, see HelloWorld sample fails when exposing custom properties on the IBM Support Portal.
    Notes:
    • When the HelloWorld CFAR file is deployed, the "Hello World" fraud context is created and the ICFM default business objects are associated to the fraud context. Therefore, any related objects are displayed when users view the investigation in the Details page.
    • The Hello World fraud context is not set up with workflow transition; therefore you cannot take action on an investigation, such as moving to another state by default. To create a workflow transition, it is recommended that you leverage the default workflow transition. This can be done by first retrieving the default workflow and then creating the new workflow, passing in the Hello World Context.
    • You can uninstall the HelloWorld sample after you complete your validation.