springboot vue 前后端分离token刷新时效
时间: 2023-09-11 16:13:21 浏览: 145
在Spring Boot和Vue的前后端分离项目中,通常可以使用WebSocket来解决token过期后的刷新问题。当第一次access_token过期并且刷新token请求失败时,可以通过一个标识来标识当前正在刷新中,以避免后续请求因为token失效而重复刷新。这个标识可以是一个等待队列,称为waitQueue。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* [前后端分离,使用websocket刷新token](https://blog.csdn.net/qiuxinfa123/article/details/106484360)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
- *2* *3* [Spring Cloud实战 | 最八篇:Spring Cloud +Spring Security OAuth2+ Vue前后端分离模式下无感知刷新实现...](https://blog.csdn.net/u013737132/article/details/110109880)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文