Forum Discussion

Stalsy's avatar
Stalsy
Contributor
4 years ago

-Doauth2.access.token.retrieval.timeout= in .vmotions not working

I've been managing my own OAuth2 token renewals via code but since upgrading to 3.10 I get a compilation error "unable to resolve class" for import com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2AzureClientFacade  which is the main class used for getting a new token.  However in the new features for 3.10 I noticed the new -Doauth2.access.token.retrieval.timeout vm setting.  So I set -Doauth2.access.token.retrieval.timeout=300000 (300 seconds) and restarted ReadyApi.  Soon after my tests started failing so I don't know if  -Doauth2.access.token.retrieval.timeout works or not.

My main question is, how do I get the first access token before my test starts running?

Till now I used code in TestRunListener.beforeRun Event but this code does not work any more as it uses the com.eviware.soapui.impl.rest.actions.oauth.OltuOAuth2AzureClientFacade  class.

No RepliesBe the first to reply