What is the simulation in pega?
Simulating integration connectors to see how the response is coming or when there is no data source is available/external system is not available. We will define our own data source and test the integration. Use simulations to unit test the integration connector. We can simulate any external service as long as we know that "what is the request it is expecting and what is the response it is going to return".
How to simulate an integration in pega?
We know that pega uses connectors to integrate with an external system to get some data, so we can simulate all integration connectors except SQL connector in pega. Any connector can be invoked from a data page or an activity.
Data page simulation in pega (Simulating data page source)
In the data page rule select the "Simulate data source" check box, once selected existing data source will be disabled and we can define new sources by using a data transform, report definition, or activity.
The data source is disabled after selecting the Simulate data source check box.
Let's use data transform to simulate data sources.
We can see simulated data types and data pages in both Dev and App studio.
Dev studio:
Configure -> Data Model -> View external data entities to open the External Data Entities landing page and get an overview of simulated data pages in your application.
Source systems marked with a green dot are production-ready. Source systems marked with an orange triangle are simulated.
App Studio:
Data Explorer -> Integration Designer. Select the Simulated icon in the system of record row to filter by the simulated data types and find all the simulated data pages quickly.
Simulation activity in pega
If the activity is an integrator activity where we used to invoke the Integration connector and the external source is not available or not ready, we can simulate the data by using a data transform.
Create a data transform and set the data like how we map response in a data transform by using request fields. Refer this data transform in Integration activity by using the "Apply-DataTransform" method.
Integration activity sets the data returned by the data transform on the integration page.
Once connector activity is ready with simulation data refer to the Connector rule to simulate the Integration connector.
Connector simulation in pega
We can simulate an integration connector when the external service is not yet ready or not yet deployed.
We can configure the Connector simulation in two ways.
1. Connector rule form
User Session -Select this option only for the current users to use this simulation.
2. Landing page -Dev studio - Configure > Integration > Connectors > Connector Definitions & Simulations, all existing Integration connectors and their simulations.
Configure Simulation activity for all connectors in the list by clicking "total simulations link".
Note: We can configure simulations for most of the connectors except SQL connectors.
Very useful information. Thanks for sharing. Please keep post.
ReplyDeleteThank you, hope you will like other topics as well.
DeleteThank For sharing Valuable Information
ReplyDeleteBest Pega Online Training
Pega Online Training Hyderabad