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: reduce overhead to process incoming questions #1244

Merged
merged 1 commit into from Sep 2, 2023
Merged

Conversation

bdraco
Copy link
Member

@bdraco bdraco commented Sep 2, 2023

When the mac discovery app is open, the number of questions goes up almost 10x. We can reduce a bit of the overhead by cythonizing the time functions and cimporting it into the hot path

When the mac discovery app is open, the number of questions goes up almost
10x. We can reduce a bit of the overhead by cythonizing the time functions
and cimporting it into the hot path
@codecov
Copy link

codecov bot commented Sep 2, 2023

Codecov Report

Patch coverage is 100.00% of modified lines.

Files Changed Coverage
src/zeroconf/__init__.py 100.00%
src/zeroconf/_utils/time.py 100.00%

📢 Thoughts on this report? Let us know!.

Comment on lines +4 to +5
from ._protocol.incoming cimport DNSIncoming
from ._utils.time cimport current_time_millis, millis_to_seconds
Copy link
Member Author

Choose a reason for hiding this comment

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

We still have a lot of float conversions from the constants that we can't patch because it breaks the tests

@bdraco bdraco marked this pull request as ready for review September 2, 2023 00:09
@bdraco bdraco merged commit 18b65d1 into master Sep 2, 2023
34 checks passed
@bdraco bdraco deleted the discovery_app branch September 2, 2023 00:09
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.

None yet

1 participant