Rest method call using a Datapage manually(unit testing) works fine when our REST connector uses OAuth tokens thru Auth Profile
Same Rest method call using same Datapage being loaded from asynchronous call i.e. loading the Datapage(REST connector) fails due to token refresh issue as apparently we assume that the Auth Profile which uses and refreshes OAuth Token (if stale) fails when we invoke it on asynchronous thread.
Is there any reason why this would be happening? Any help/advise please from community members, Pega Experts?