Skip to main content

Debugging application errors

3 Tasks

20 mins

Visible to: All users
Beginner Pega Platform '24.2 Low-Code App Development Enterprise Application Development Dev/Designer Studio English

Scenario

As part of processing an assistance request Case, the Roadside Assistance application copies the service totals from the child Service Case to the Assistance Request Case. While testing the configuration of this feature, you notice that the Assistance Request Case has different service totals that are not indicated on the child Case, as shown in the following screenshot. Use the Tracer tool to debug and resolve the issue. 

Invoice values comparison shown between the parent and child cases.

The following table provides the credentials you need to complete the challenge.

Role User name Password
Application Developer author@gogoroad pega123!
Note: The challenge walkthrough is coming soon.

You must initiate your own Pega instance to complete this Challenge.

Initialization may take up to 5 minutes so please be patient.

Detailed Tasks

1 Configure Tracer settings

  1. In the footer of Dev Studio, in the Developer Toolbar, click the Tracer icon to display the Tracer window.
    Tracer icon in the bottom the Devstudio
  2. In the Tracer window, in the toolbar, click Settings to check the Tracer tool settings. The Tracer Settings window is displayed.
    Settings button in the Tracer toolbar
  3. In the Tracer Settings window, verify that the following events to trace and break Conditions are selected.
    tracer_settings
  4. In the Rulesets to Trace section, click Deselect All.
  5. Select the GoGoRoad check box to trace Rules in the GoGoRoad Ruleset.
    rules_to_race
  6. Click OK to dismiss the Tracer Settings window.

2 Start the Tracer tool and identify candidate events

  1. In the Tracer window, in the toolbar, click Clear to clear any previous logs.
    Clear button on the Tracer toolbar
  2. Click Pause to pause the Tracer tool.
    Tip: To reduce the number of irrelevant events the Tracer records, play the Tracer before you encounter the error.
  3. Minimize the Tracer window.
  4. Create a new Assistance Request Case.
  5. Advance the Case to the Select services View.

    Note: In the Enter customer information Step, select an account ID with Standard coverage so that the start Condition does not skip the Review service summary Step.
  6. Open the Tracer window, and then click Play to start the Tracer tool.
  7. Minimize the Tracer window.
  8. Select the Tow vehicle check box, in the Vehicle type select Sedan, in the Miles field, enter a value of 20.
  9. In the Service list, select Tire repair, in the Quantity field, enter a value of 1.
    Select services view in the Service Case.
  10. Click Submit. The Review service summary View is displayed.
    Note: If the Case does not automatically proceed to the Review service summary Step, click the pulldown next to the Service Case ID and then click the Assistance Request Case ID to be redirected to the parent Case. To the right of Review service summary, click Go to proceed to the Review service summary View.
  11. Open the Tracer window, and then click Pause to pause the Tracer tool. In the Tracer results, the following events set the values of Tow cost and Service total
    Tracer showing the set values for the towcost and servicestotal
    Note: Your line numbers may differ.
  12. In the Tracer results, click a line of interest in the STEP METHOD column to view more details. The Properties on Page TraceEvent window is displayed. The Event Key row shows the class and Rule name, which is TESTVALUESFORINVOICING
    Properties on Page TraceEvent
  13. Close the Properties on Page TraceEvent window.
  14. Close the Tracer window.

3 Locate and correct the source of the error

  1. In the header of Dev Studio, in the search bar, enter TestValuesforInvoicing, and then press the Enter key. The search results are displayed.
    Search results for testvaluesforinvoicing
    Note: If the system fails to return a search result, use either the App Explorer to locate the Rule in the AssistanceRequest class, or the Records Explorer to locate the Rule in the Data Transform Rule category.
  2. Click the TestValuesForInvoicing Data Transform. The Test values for Invoicing Data Transform have hard-coded values for the tow cost and service total items. The Data Transform was included for testing purposes and should be removed. 
    TestValuesForInvoicing data transform
  3. Click Actions > View references to see where the Rule is referenced. In the pane on the right, in the Referencing Rules tab, the InvoiceCustomer flow is displayed.
    Data transform testvaluesforinvoicing referencing rules
  4. Hover over GoGo-GoGoRoad-Work-AssistanceRequest-InvoiceCustomer, and then click the Edit icon to open the Flow Rule
  5. Between the start shape and the Review service summary Assignment, right-click the connector, and then click View properties.
    View properties in the first connector of the Invoice Customer flow rule
  6. In the Connector properties window, in the Set properties section, verify that the TestValueForInvoicing Data Transform is executed from this connector.
    Connector properties with test values for invoicing data transform applied
  7. Clear the Data Transform field, and then click Submit to dismiss the window.
  8. Click Save to save the Flow Rule.

Confirm your work

  1. Create a new Assistance Request Case.
  2. In the Enter customer information View, select [email protected] as the Account ID.
  3. Advance the Case to the Select services View.
  4. Select the Tow vehicle check box, in the Vehicle type select Sedan, in the Miles field, enter a value of 20.
  5. In the Service list, select Tire repair, in the Quantity field, enter a value of 1.
    Select services view in the Service Case.
  6. Click Submit. The Review service summary View is displayed.
  7. Verify that the correct services are displayed.
    Review service summary showing the correct tow cost and service total values
    Note: This challenge does not have autograding validations.

This Challenge is to practice what you learned in the following Module:


Available in the following mission:

If you are having problems with your training, please review the Pega Academy Support FAQs.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Academy has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice