Skip to main content

Reusing the standard queue processor

5 Tasks

1 hr

Visible to: All users
Advanced Pega Platform '23 English

Scenario

When the city manager updates the delivery status of a truck, the associated delivery request Processes should also move forward in the flow.

When the accountant reviews and finalizes the invoice, the delivery request should move forward in the flow to collect payment from the business partner.

When the accountant completes payment to the truck vendor, the city manager should receive the request to collect feedback on the individual truck.

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

Role User name Password
Admin admin@deliveryservice rules
CityManager SpringfieldCityManager@MDC rules
CityManager BostonCityManager@MDC rules
CityManager WorcesterCityManager@MDC rules

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 Identify design options

Option 1: Standard queue processor

Your application can resume the Processes of other Cases as required by reusing the standard queue processor. This option allows for optimal use of resources and enables Case processing to continue asynchronously in the background.

Option 2: Job scheduler

Create a job scheduler and set it to run at frequent intervals to process the waiting assignments.

Option 3: Advanced agents

Create an advanced agent to resume the waiting assignments and update the agent schedule to run at a recurring periodic interval.

2 Evaluate design options

The following table provides the pros and cons of each design option:

Design Pros Cons

Standard queue processor

  • The design is low maintenance.
  • The design uses the out-of-the-box queue processor.
  • The design runs messages from the topic directly.
  • The design requires at least one stream node to be running.

Job scheduler

  • The design delivers better performance, monitoring, and diagnostics of each run.
  • The design cannot run immediately; it runs at a scheduled time.
  • The design needs to build logic for transactional processing.
Advanced agents
  • Agent activity is again responsible for both transactional and business processing.
  • Agent run time can update without any code migration.
  • The design needs to build logic for transactional processing.
  • The design cannot run immediately; it runs at a scheduled time.
  • It is not best practice to use agents for any new requirements.

3 Recommend the best design option

Use a standard queue processor to process the waiting Assignments of sibling Cases.

4 Review solution details

The system invokes the standard queue processor by using a reusable utility called ResumeProcess, which you configure in the enterprise Ruleset, as shown in the following figure:

Resume-Process

The activity to run through the Queue-For-Processing method is the standard resumeWorkProcess utility, as shown in the following figure:

Resume-Process-Utility

5 Perform the following tasks

To complete the assignment, accomplish the following tasks.

  1. Create a Delivery Request Case and assign a truck for the delivery.
  2. Log in as the city manager corresponding to the city in the delivery request.
  3. Update the delivery status of the truck request from Pickup to Delivery. This action resume the delivery request to the Delivery status.

Confirm your work

      



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