共享token
continuous-integration/drone/push Build is passing Details

沃森川job同步飞书
YXY 1 year ago
parent 5a053a3546
commit b79aa66dce

@ -76,7 +76,7 @@ public class EdiController extends BaseController {
String appTicket = bizContent.getString("appTicket"); String appTicket = bizContent.getString("appTicket");
if (StringUtils.isNotBlank(appTicket)) { if (StringUtils.isNotBlank(appTicket)) {
redisCache.setCacheObject(RedisConstants.CJT_TICKET_CACHE_KEY,appTicket,10, TimeUnit.MINUTES); redisCache.setCacheObject(RedisConstants.CJT_TICKET_CACHE_KEY,appTicket,10, TimeUnit.MINUTES);
redisCache.deleteObject(CJT_TOKEN_CACHE_KEY); redisCache.deleteObject(RedisConstants.CJT_TOKEN_CACHE_KEY);
} }
}catch (Exception e){ }catch (Exception e){
log.error("receiveWscTicket error request:{}",JSONObject.toJSONString(request),e); log.error("receiveWscTicket error request:{}",JSONObject.toJSONString(request),e);

@ -339,6 +339,8 @@ public abstract class SyncAccountsJobAbstract {
String token = value.getString("accessToken"); String token = value.getString("accessToken");
context.setOpenToken(token); context.setOpenToken(token);
redisCache.setCacheObject(RedisConstants.CJT_TOKEN_CACHE_KEY,token,10, TimeUnit.MINUTES); redisCache.setCacheObject(RedisConstants.CJT_TOKEN_CACHE_KEY,token,10, TimeUnit.MINUTES);
}else{
context.setOpenToken(openToken);
} }
} }

Loading…
Cancel
Save