改进代码注释的准确性和完整性
Co-authored-by: binarywang <1343140+binarywang@users.noreply.github.com>
This commit is contained in:
@@ -62,6 +62,8 @@ public class WxCpRedisConfigImpl implements WxCpConfigStorage {
|
||||
private volatile int msgAuditSdkRefCount;
|
||||
/**
|
||||
* 会话存档access token锁(本地锁,不支持分布式)
|
||||
* 注意:此实现使用本地ReentrantLock,在多实例部署时无法保证跨JVM的同步
|
||||
* 建议在生产环境中自行实现分布式锁机制,或使用其他支持分布式的配置存储实现
|
||||
*/
|
||||
private final Lock msgAuditAccessTokenLock = new ReentrantLock();
|
||||
|
||||
|
||||
@@ -141,7 +141,7 @@ public class WxCpServiceGetMsgAuditAccessTokenTest {
|
||||
throw new WxErrorException("会话存档secret未配置");
|
||||
}
|
||||
|
||||
// 模拟HTTP请求失败,实际测试中应该返回缓存的token
|
||||
// 返回缓存的token(用于测试缓存机制)
|
||||
return getWxCpConfigStorage().getMsgAuditAccessToken();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user