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

feat: update dummy plugin to handle concurrent queries #307

Merged
merged 1 commit into from
Aug 26, 2024

Conversation

j-lanson
Copy link
Collaborator

This PR updates the dummy_rand_data plugin binary to support multiple active queries (mostly mirroring what was done for hipcheck/plugin in #297 ) .

Key changes:
engine.rs - added async_query, an async version of the salsa memoized query() function. This does not memoize, its just a proof of concept that we would be able to perform recursive calls to an async function.
main.rs - updates cmd_plugin() to actually spawn multiple simultaneously queries (using async_query, with a commented-out version demonstrating how to do so with sync query())
hipcheck_transport.rs - does receiver multiplexing
main.rs - RandDataRunner now spawns off a task that handles the individual query, giving it a cloned version of the HcTransport object for communicating over the gRPC channel.

@j-lanson j-lanson added the type: enhancement New feature or request label Aug 26, 2024
@j-lanson j-lanson added this to the 3.6.0 milestone Aug 26, 2024
@j-lanson j-lanson self-assigned this Aug 26, 2024
@j-lanson j-lanson force-pushed the jlanson/test-plugin-engine branch from 4cb95a3 to 1849987 Compare August 26, 2024 17:35
@alilleybrinker alilleybrinker merged commit c999d29 into main Aug 26, 2024
9 checks passed
@alilleybrinker alilleybrinker deleted the jlanson/test-plugin-engine branch November 5, 2024 06:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement New feature or request
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants