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

CP-52708: Avoid making Unix read/write calls for internal API calls: … #6178

Draft
wants to merge 1 commit into
base: feature/perf
Choose a base branch
from

Conversation

edwintorok
Copy link
Contributor

…forward the API call directly like we do with the CLI for calls to the coordinator when we are the coordinator

We might want to check that tracing still works with this, e.g. we might have to create a new span.

This avoids a lot of needless internal serialization, and a similar mechanism is already used by the CLI.

…forward the API call directly like we do with the CLI for calls to the coordinator when we are the coordinator

Signed-off-by: Edwin Török <[email protected]>

let () = Unix.close dummy_fd

let fake_rpc2 req rpc = Api_server.Server.dispatch_call req dummy_fd2 rpc
Copy link
Member

Choose a reason for hiding this comment

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

This makes dummy_fd2 slot into the origin type of ocaml/xapi/context.ml, which needs to be handled by all of its user, like the preauth, _client_of_origin, parent_of_origin, and others.

This needs a closer look, I doubt it can work as-is

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants