Skip to content

Conversation

@milesj
Copy link
Contributor

@milesj milesj commented Dec 1, 2024

I wrap the Plugin instance in a RwLock and because function_exists requires &mut self, I have to acquire a write lock everytime to just check if a function exists, which causes lock contention.

This changes it to &self since it doesn't need to mutate.

@milesj milesj requested a review from zshipko as a code owner December 1, 2024 00:37
@bhelx
Copy link
Contributor

bhelx commented Dec 1, 2024

Thank you :)

Will have @zshipko peek at it on Monday

Copy link
Contributor

@zshipko zshipko left a comment

Choose a reason for hiding this comment

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

Thanks! Test failures are clippy related, I will fix those in a follow up PR.

@zshipko zshipko merged commit 4f599d4 into extism:main Dec 2, 2024
3 of 5 checks passed
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.

3 participants