Asynchronus Data page loading - how and where to use it ?
I wanted to test Asynchronus Data page loading using Load-DataPage Method, please find screenshots of Activity steps(Steps 1-3 are inactive) and tracer events, i can see that only when i refer the D page in the property set method of Step 5 it is loading the Data for that D page not in step 4.
what am i doing wrong here, do i have to use a pool ID and Connect Wait combination ?
Also it will be helpful to know in which scenarios this Asynchronus load will be used and when to use Pool ID.
I have gone through the pega help, could not get the complete picture of this functionality.
***Edited by Moderator: Lochan to update platform capability tags***
Believe that the asynchronous loading of a data page is mainly used for user experience when loading data pages for sections when it's large data and not for activities. for example at the start of a flow you can begin to load a data page that will be used on a future screen, this way a user won't have to wait for it to load upon clicking the submit button.
So when you reference the data page in step 5 Pega won't of loaded it into memory yet and that's why it gets a fresh instance.
PoolID's are used with "Connect-Wait" methods to allow Pega to wait for those data pages to load. so for example in your activity if you had a "Connect-Wait" method after you load-datapage method and they both have the same PoolID and then referenced the data page page it shouldn't load it at step 5.
I was able to test the D page load with and without pool ID successfully.
Without pool ID: it takes few secs for the D page to load after step 4(in below image), so if you refer the D page in the immediate next step (step 5), The D page loading in the background thread will not be used(since it is still loading), if you trace the activity you will find that the D page is loaded again(synchronously) in the main thread when we reach step 5. so in situvation like this you can add a Connect-Wait method(add a pool ID in step 4) in between step 4 and 5, so that the activity will wait for the D page to load in the background thread.
If you are referrring the page at a later point of time(few secs/mins after step 4), then you won't need pool ID and Connect-Wait method since there is sufficient interval for the D page to load and become available.