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

Easier modifiction of incoming message handlers #165

Open
bobveringa opened this issue Jan 30, 2025 · 1 comment
Open

Easier modifiction of incoming message handlers #165

bobveringa opened this issue Jan 30, 2025 · 1 comment

Comments

@bobveringa
Copy link
Contributor

We are looking to track additional statistics related to the connection, with a primary focus on measuring latency.

This requires calculating the time difference between PING and PINGRESP. However, it seems unlikely that many others would have a similar need for latency measurement on the connection.

Additionally, it is not possible to simply override the PINGRESP handler, as all messages are processed within the wait_msg function. For our use case, it would be beneficial if the PINGRESP handler here were separated into its own function, allowing us to override it more easily.

I understand if you prefer not to make this change, as it introduces a modification that very few others are likely interested in. If you are interested, I can submit a PR with the changes.

@peterhinch
Copy link
Owner

I don't have a problem with this.

I've been working on some bugfixes and refactoring. I've pushed a branch protocol_tests which I'll detail in our other thread #164.

If you submit a PR you may need to give me some guidance on how to deal with it while working on a branch.

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

No branches or pull requests

2 participants