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

🔮[RFC ]: OpenIM Message Latency Testing #1280

Closed
skiffer-git opened this issue Oct 25, 2023 · 5 comments
Closed

🔮[RFC ]: OpenIM Message Latency Testing #1280

skiffer-git opened this issue Oct 25, 2023 · 5 comments
Labels
enhancement New feature or request feature Categorizes issue or PR as related to a new feature. RFC Project design proposal

Comments

@skiffer-git
Copy link
Member

Definition of Message Latency

The time it takes from the sender sending the message to the recipient triggering the onRecvNewMessage callback.

Test Program Design

Developers should integrate the OpenIMSDK into their own apps to implement instant messaging. The test program is based on OpenIMSDK, simulating real scenarios to test message latency.

The main features are:

(1) Simulate sending messages: Send a message to another user. After the message is successfully sent or fails, send the next one.

(2) Stay online after logging in: Consistently stay online without logging out.

(3) Upon receiving a command: Count the number of conversations and fetch the total number of messages for each conversation.

(4) Specify the number of OpenIMSDK instances.

Statistics

(1) After all messages are sent, the test client counts the number of messages sent successfully and unsuccessfully, as well as the msgID of failed messages.

(2) The server counts the message storage details, including seq and storage in redis/mongo.

(3) On command: Count the conversations and tally all the messages. Confirm if the received messages match the expected ones.

(4) For the onRecvNewMessage callback, record the latency of each message and output the overall statistical results.

Objectives

(1) For stress testing, the number of messages successfully and unsuccessfully sent by the client and server should match. For msgIDs where the client sending failed but the server succeeded, check if they were synchronized to the client through synchronization logic.

(2) All test client conversations and received messages should be consistent with expectations.

(3) Under certain stress conditions (e.g., the number of simultaneous online users, total messages sent per second) and specific server resources (CPU, memory, etc.), the message latency should be less than 2 seconds.

@skiffer-git skiffer-git added enhancement New feature or request feature Categorizes issue or PR as related to a new feature. RFC Project design proposal proposal labels Oct 25, 2023
@kubbot
Copy link
Contributor

kubbot commented Dec 25, 2023

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@cubxxw
Copy link
Contributor

cubxxw commented Dec 25, 2023

/active life cycle

@kubbot
Copy link
Contributor

kubbot commented Feb 28, 2024

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@cubxxw
Copy link
Contributor

cubxxw commented Mar 3, 2024

restart

@kubbot
Copy link
Contributor

kubbot commented May 13, 2024

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request feature Categorizes issue or PR as related to a new feature. RFC Project design proposal
Projects
None yet
Development

No branches or pull requests

3 participants