Skip to content

Conversation

tombriden
Copy link
Contributor

when under load it's possible that a metafile gets updated by rtpengine while it's still being read by the recording daemon. this can result in a WARNING being logged and the loop breaking. That section ends up unprocessed and any changes in it don't get applied. This change only updates the offset after a successful section read. Therefore, if a section is incomplete and the loop breaks, the next inotify event will retry that incomplete section and it should succeed

@tombriden
Copy link
Contributor Author

tombriden commented Oct 3, 2025

we're using tls-send-to, and enable forwarding of one channel after offer and the other after answer. Under load, we've found this can result in only one channel being forwarded and Content truncated in section... being logged due to the metafile change that adds STREAM 0 FORWARD 1 not being processed.

@tombriden
Copy link
Contributor Author

thinking about this, the 2 cases to check for an unexpected NUL char shouldn't be handled in the same way or it'll never finish processing the file

… change

when under load it's possible that a metafile gets updated by rtpengine
while it's still being read by the recording daemon. this can result
in a WARNING being logged and the loop breaking. That section ends up
unprocessed and any changes in it don't get applied.
This change only updates the offset after a successful section read.
Therefore, if a section is incomplete and the loop breaks, the next
inotify event will retry that incomplete section and it should succeed
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.

1 participant