Select to view content in your preferred language

JS App requires authentication every tab open

197
1
07-12-2024 09:15 AM
4andy
by
New Contributor

Hi, we have created a JS web app with the 4.x JS SDK. The app works great, however, we are prompted to log in every time the app loads in a new browser tab, even if we just authenticated in another open tab. 

In an Enterprise Portal app, once you authenticate, you can open any number of tabs and apps without authenticating again. We would like the JS app to replicate this behavior. 

Does anyone have any idea why it's prompting so much or how to resolve the issue? The only thing the app does regarding authentication is register the oauth info (below). The server services and the app are hosted on the same domain/server. 

esriConfig.portalUrl = oauth_portal_url
const info = new OAuthInfo({
appId: oauth_app_id,
portalUrl: oauth_portal_url,
popup: false
});
esriId.registerOAuthInfos([info]);

Tags (1)
1 Reply
FulcrumAdmin
New Contributor

We're seeing some similar issues with being logged out after 15-20 minutes just starting today. We're working on updating to the latest JS SDK version as well as updating our API tokens, but the issues we're seeing also include some extreme slowness in loading feature service layers lists as well as displaying the layers themselves on a map. The snapping tools seem to be unable to retrieve the correct list of layers as well.

Tags (2)
0 Kudos