Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

try to fix #249 #500

Closed
wants to merge 1 commit into from
Closed

try to fix #249 #500

wants to merge 1 commit into from

Conversation

Yiffyi
Copy link

@Yiffyi Yiffyi commented Aug 17, 2020

No description provided.

@Him188
Copy link
Member

Him188 commented Aug 17, 2020

请问是否有测试过?

@Him188 Him188 added x:protocol 属性: 协议相关 t:bug 类型: bug labels Aug 17, 2020
@Him188 Him188 linked an issue Aug 17, 2020 that may be closed by this pull request
@Yiffyi
Copy link
Author

Yiffyi commented Aug 17, 2020

测试过了
多端交替发送、分享卡片均可修复
在消息被吞时调试查看seq均确认不递增
如需复现问题,已知通过网易云音乐分享卡片时发送的 seq 与聊天不同,可测试

@@ -78,7 +74,7 @@ internal class FriendImpl(
override val coroutineContext: CoroutineContext = coroutineContext + SupervisorJob(coroutineContext[Job])

@Suppress("unused") // bug
val lastMessageSequence: AtomicInt = atomic(-1)
val lastMessageSeqCacheList: AtomicResizeCacheList<Int> = AtomicResizeCacheList(15.minutesToMillis)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个list只会增大不会变小, 15分钟保留时间过长, 请考虑 15 秒左右

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

使用 AtomicResizeCacheList 无法解决问题
简单测试重复时间会长于1分钟

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
t:bug 类型: bug x:protocol 属性: 协议相关
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants