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

perf(rpc server): Measure benefit of queuing snapshot & pipe opening as well #515

Open
InKryption opened this issue Jan 24, 2025 · 0 comments
Labels
enhancement New feature or request feature rpc

Comments

@InKryption
Copy link
Contributor

Right now in the io_uring Workpool backend, when we begin processing a snapshot request, we inline open the relevant file and create the splicing pipe:

const archive_name_bounded = snap_info.snapshotArchiveName();
const archive_name = archive_name_bounded.constSlice();
const snapshot_dir = server_ctx.snapshot_dir;
const archive_file = try snapshot_dir.openFile(archive_name, .{});
errdefer archive_file.close();
const file_size = try archive_file.getEndPos();
const pipe_r, const pipe_w = try std.posix.pipe();
errdefer std.posix.close(pipe_w);
errdefer std.posix.close(pipe_r);

This issue can be closed when a PR is created which refactors this into a set of SQE submissions and CQEs for opening the file and creating the pipe; after it's created, the complexity increase should be weighed against the performance benefit, and then it should be either merged or closed based on that evaluation.

@InKryption InKryption added enhancement New feature or request feature rpc labels Jan 24, 2025
@0xNineteen 0xNineteen moved this to 📋 Backlog in Sig Jan 31, 2025
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 rpc
Projects
Status: 📋 Backlog
Development

No branches or pull requests

1 participant