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

Improved locking performance on .NET 9.0+ #62

Merged
merged 3 commits into from
Sep 2, 2024

Conversation

MarkCiliaVincenti
Copy link
Contributor

The new System.Threading.Lock offers greater performance, as independent benchmarks show (eg https://steven-giesel.com/blogPost/4cf6d48a-ec9d-4c68-961c-31fd8d8c1340)

@witskeeper
Copy link
Member

It looks like the CI is broken.

@MarkCiliaVincenti can you fix the CI error?

error CA2252: '_lock''s type contains the preview type 'Lock' and requires opting into preview features. See https://aka.ms/dotnet-warnings/preview-features for more information. (https://learn.microsoft.com/dotnet/fundamentals/code-analysis/quality-rules/ca2252)

@witskeeper witskeeper added this to the v2.0.x milestone Sep 2, 2024
@MarkCiliaVincenti
Copy link
Contributor Author

Interesting. This is happening because it's running under 9.0.100-preview.4.24267.66 instead of the latest (preview 7). I made a hopeful fix but given the workflow needs manual approval a trial-and-error approach is going to be tricky.

@MarkCiliaVincenti
Copy link
Contributor Author

@witskeeper

@witskeeper
Copy link
Member

witskeeper commented Sep 2, 2024

It seems that manual approval cannot be canceled.

@witskeeper
Copy link
Member

i will try to update sdk to preview 7

@MarkCiliaVincenti
Copy link
Contributor Author

But now the error is different. It is running on preview 7

The message timed out in the backlog attempting to send because no connection became available (5000ms)

@witskeeper
Copy link
Member

I improved the dependencies and test cases related to .NET 9 and specified using preview 7
It might work.

Copy link
Member

@witskeeper witskeeper left a comment

Choose a reason for hiding this comment

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

Done

@witskeeper
Copy link
Member

Thank you for your contribution. @MarkCiliaVincenti

@witskeeper witskeeper merged commit 06608c3 into netcorepal:main Sep 2, 2024
1 check 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.

2 participants