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

fix: the user sets the conversation timer cleanup timestamp unit incorrectly #3102

Merged
merged 56 commits into from
Feb 8, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
ddf8b73
pb
withchao Dec 12, 2024
d8f671d
Merge branch 'openimsdk:main' into main
withchao Dec 12, 2024
f1b1d71
Merge branch 'openimsdk:main' into main
withchao Dec 16, 2024
6f169ec
fix: Modifying other fields while setting IsPrivateChat does not take…
withchao Dec 17, 2024
94cb0c0
Merge remote-tracking branch 'origin/main'
withchao Dec 17, 2024
569b92b
Merge branch 'openimsdk:main' into main
withchao Dec 17, 2024
d15414d
fix: quote message error revoke
withchao Dec 17, 2024
2c6f974
Merge remote-tracking branch 'origin/main'
withchao Dec 17, 2024
3753b81
Merge branch 'openimsdk:main' into main
withchao Dec 18, 2024
f03cbec
refactoring scheduled tasks
withchao Dec 18, 2024
705bc37
refactoring scheduled tasks
withchao Dec 19, 2024
8807597
refactoring scheduled tasks
withchao Dec 19, 2024
1949d6c
refactoring scheduled tasks
withchao Dec 19, 2024
86d5825
refactoring scheduled tasks
withchao Dec 19, 2024
46a8d17
refactoring scheduled tasks
withchao Dec 20, 2024
277354b
Merge branch 'openimsdk:main' into main
withchao Dec 20, 2024
d274d65
Merge branch 'openimsdk:main' into main
withchao Dec 23, 2024
df0cd3c
Merge branch 'openimsdk:main' into main
withchao Dec 24, 2024
2e8ca5f
upgrading pkg tools
withchao Dec 24, 2024
8cb1772
Merge branch 'openimsdk:main' into main
withchao Dec 25, 2024
3cb487d
Merge branch 'openimsdk:main' into main
withchao Dec 26, 2024
9f1fff6
Merge branch 'openimsdk:main' into main
withchao Dec 27, 2024
df063d2
Merge branch 'openimsdk:main' into main
withchao Dec 27, 2024
030c449
fix
withchao Dec 27, 2024
d146e78
Merge branch 'openimsdk:main' into main
withchao Dec 27, 2024
f0d8882
fix
withchao Dec 29, 2024
ddfafcc
Merge branch 'openimsdk:main' into main
withchao Dec 29, 2024
f301b76
Merge branch 'openimsdk:main' into main
withchao Dec 29, 2024
d091d5f
optimize log output
withchao Dec 30, 2024
3c7a9bd
Merge branch 'openimsdk:main' into main
withchao Dec 30, 2024
4fe15e9
Merge branch 'openimsdk:main' into main
withchao Dec 31, 2024
3059436
feat: support GetLastMessage
withchao Dec 31, 2024
f3d5634
feat: support GetLastMessage
withchao Dec 31, 2024
819997a
feat: s3 switch
withchao Jan 2, 2025
755520a
feat: s3 switch
withchao Jan 2, 2025
1e9cd14
Merge branch 'openimsdk:main' into main
withchao Jan 2, 2025
65a9cfb
Merge branch 'openimsdk:main' into main
withchao Jan 6, 2025
7a8346b
fix: GetUsersOnline
withchao Jan 7, 2025
e6b21fa
Merge branch 'openimsdk:main' into main
withchao Jan 7, 2025
1e2b6f9
Merge branch 'openimsdk:main' into main
withchao Jan 7, 2025
6758661
feat: SendBusinessNotification supported configuration parameters
withchao Jan 9, 2025
05528af
feat: SendBusinessNotification supported configuration parameters
withchao Jan 9, 2025
e94ce82
feat: SendBusinessNotification supported configuration parameters
withchao Jan 9, 2025
b991c9c
Merge branch 'openimsdk:main' into main
withchao Jan 10, 2025
f31d196
feat: seq conversion failed without exiting
withchao Jan 10, 2025
327e4b7
Merge remote-tracking branch 'origin/main'
withchao Jan 10, 2025
3067db5
Merge branch 'openimsdk:main' into main
withchao Jan 19, 2025
961f43c
fix: DeleteDoc crash
withchao Jan 22, 2025
e6c57e0
Merge branch 'openimsdk:main' into main
withchao Jan 24, 2025
623335c
fix: fill send time
withchao Jan 24, 2025
29c7a40
fix: fill send time
withchao Jan 24, 2025
113e4ca
Merge branch 'openimsdk:main' into main
withchao Feb 5, 2025
8b752af
fix: crash caused by withdrawing messages from users who have left th…
withchao Feb 6, 2025
23976e4
fix: user msg timestamp
withchao Feb 7, 2025
c6e6dac
Merge branch 'openimsdk:main' into main
withchao Feb 7, 2025
bf06985
Merge remote-tracking branch 'origin/main'
withchao Feb 7, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions internal/rpc/conversation/conversation.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,11 @@ package conversation

import (
"context"
"github.com/openimsdk/open-im-server/v3/pkg/rpcli"
"sort"
"time"

"github.com/openimsdk/open-im-server/v3/pkg/rpcli"

"github.com/openimsdk/open-im-server/v3/pkg/common/config"
"github.com/openimsdk/open-im-server/v3/pkg/common/storage/cache/redis"
"github.com/openimsdk/open-im-server/v3/pkg/common/storage/database/mgo"
Expand Down Expand Up @@ -773,7 +774,7 @@ func (c *conversationServer) ClearUserConversationMsg(ctx context.Context, req *
if conversation.IsMsgDestruct == false || conversation.MsgDestructTime == 0 {
continue
}
seq, err := c.msgClient.GetLastMessageSeqByTime(ctx, conversation.ConversationID, req.Timestamp-conversation.MsgDestructTime)
seq, err := c.msgClient.GetLastMessageSeqByTime(ctx, conversation.ConversationID, req.Timestamp-(conversation.MsgDestructTime*1000))
if err != nil {
return nil, err
}
Expand Down
9 changes: 8 additions & 1 deletion pkg/common/storage/database/mgo/conversation.go
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,14 @@ func (c *ConversationMgo) FindRandConversation(ctx context.Context, ts int64, li
"$add": []any{
bson.M{
"$toLong": "$latest_msg_destruct_time",
}, "$msg_destruct_time"},
},
bson.M{
"$multiply": []any{
"$msg_destruct_time",
1000, // convert to milliseconds
},
},
},
},
},
},
Expand Down
Loading