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

Batching of requests from KeyClaimManager.ensureSessionsForUsers() #4468

Open
hughns opened this issue Oct 22, 2024 · 0 comments
Open

Batching of requests from KeyClaimManager.ensureSessionsForUsers() #4468

hughns opened this issue Oct 22, 2024 · 0 comments
Labels
A-Element-R Issues affecting the port of Element's crypto layer to Rust T-Enhancement

Comments

@hughns
Copy link
Member

hughns commented Oct 22, 2024

Currently the rust crypto will do a single key claim request irrespective of the number of users and devices requested:

const claimRequest = await this.olmMachine.getMissingSessions(userList.map((u) => u.clone()));
if (claimRequest) {
logger.info("Making /keys/claim request");
await this.outgoingRequestProcessor.makeOutgoingRequest(claimRequest);
}

It would make sense to batch this at an appropriate batch size.

n.b. I don't know whether this should be done by making getMissingSessions() return multiple requests, or splitting the requests in KeyClaimManager. Presumably this behaviour might be of concern for the matrix-rust-sdk too.

@dosubot dosubot bot added the A-Element-R Issues affecting the port of Element's crypto layer to Rust label Oct 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Element-R Issues affecting the port of Element's crypto layer to Rust T-Enhancement
Projects
None yet
Development

No branches or pull requests

1 participant