-
Notifications
You must be signed in to change notification settings - Fork 2
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
Telemetry Packet Extraction #80
Conversation
This code currently has a bug where the rust server will send 2 packets back to back very quickly. This is because the front end is making 2 connections. This should be fixed in the Rocket Monitoring Refactor PR (#76). |
if (int_bytes_read > 0) { | ||
buffer.extend_from_slice(&readbuf[..value]); | ||
// Check for two successive newlines | ||
if let Some(pos) = buffer.windows(2).position(|window| window == b"\n\n") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
when I run the code it couldn't find two consecutive new lines. We should test this with the brb on Thursday
I did this before the if statement and it worked fine with the mock data
extract_packets(Arc::clone(&state_ref), buffer.clone()).await;
buffer.clear();
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@JackCotter Could we add a Locked
attribute to the packet so we can more easily tell on the frontend if we've got a lock or not
@PokeyOne Can you test this in your environment. WSL couldn't pick up |
Telemetry now extracts all info from packets including: