英文:
Teams SDK initialisation gets timed out sometimes when redirecting to a URL which is in the pattern of given valid domain with wildcard
问题
流程:我们的产品有多个客户端。每个客户端在同一个域中有不同的应用程序URL(例如abc.getnspace.com,def.getnspace.com等)。为了适应所有客户端,我们已将我们的默认URL设置为个人应用程序的初始URL。我们根据用户的租户ID计算登录的用户实际需要重定向到的URL。
问题:我们在有效域中提供了*.getnspace.com。在重定向后,所有符合此模式的URL都被初始化得很好,除了少数几个。对于那些重定向的URL中的少数几个,SDK初始化超时(没有找到SDK初始化超时的URL模式)。
但是,如果我们将该URL单独包含在有效域列表中,同时包括通配符URL,那么SDK初始化就能正常工作。由于仅允许有16个有效域的限制,我们无法添加所有客户端,这也不是一个好选择,因为每次需要添加或删除客户端时,我们都需要提交新版本的应用程序。
注意:这不会发生在所有客户端身上。即使某些URL没有在有效域列表中明确提及,它们仍然会被加载。
使用的包和版本:teams-js@2.4.2
错误日志的图像
英文:
Process: Our product has multiple clients. Each client has different URL for the application in the same domain. (ex. abc.getnspace.com, def.getnspace.com etc). To accommodate all clients, we have given our default URL as the initial URL of the personal app. We compute the actual URL that the logged in person has to be redirected to, based on user's tenant id.
Issue: We have given *.getnspace.com in the valid domains. All the URLs in this pattern after getting redirected are being initialised just fine except a few. For those few redirected URL's, the SDK initialisation is getting timed out (no pattern found for which URLs the SDK initialising gets timed out).
But the SDK initialisation is working fine, if we include that URL separately in the valid domains list along with the wildcard URL. We couldn't add all our clients as there is a restriction for only 16 valid domains, and it wouldn't be a good option as well because we need to submit a new version of our app every time we need to add or remove a client.
Note:This is not happening with all the clients. Some URLs are getting loaded even if they are not explicitly mentioned in the valid domains list.
Package and version used: teams-js@2.4.2
Image of the error logged
答案1
得分: 0
我之前也遇到过这个问题,使用团队的 SDK2.X版本会出现这个问题。后来,我将SDK包替换为"@ Microsoft/teams js"的"1.10.0"版本来解决这个问题。你可以试一试,但我也期待着使用2.X版本来找到一个有效的解决方案。
英文:
I have also encountered this issue before, and using the team's SDK2. X version will have this issue. Then, I replaced the SDK package with "@ Microsoft/teams js": "1.10.0" version to solve this problem. You can try it out, but I am also looking forward to using the 2. X version to have an effective solution
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论