Add PackagePtr::Start for FastTx package send - #515
Closed
NikolayChirkov wants to merge 2 commits into
Closed
Conversation
Bring prepared_packet encode/export foundation onto main and add Package / PackagePtr so EncodePacket output can be owned and started through an externally owned UDP send function, with would-block retry via the task scheduler. Co-authored-by: Nikolay Chirkov <NikolayChirkov@users.noreply.github.com>
Co-authored-by: Nikolay Chirkov <NikolayChirkov@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements the FastTx step after
EncodePacket:PackagePtr→Start().aether/prepared_packet/foundation fromprepared-packet-v0/ PR Add prepared send_message packet API #513 (PreparedSendMessageBlock,EncodePacket,PrepareSendMessage, export APIs).Package/PackagePtrowning encoded bytes + destination endpoint.Package::Start(SendFunc)sends through a caller-provided raw send function (external code owns the UDP socket), with would-block retry via the task scheduler andWriteActionstatus events.tests/test-prepared-packetcovering success, retry, fail, and stop.API sketch
Test plan
aetherandtest-prepared-packetctest . --progress -j -E "((sodium)|(hydro)|(bcrypt)).*" --output-on-failure— 23/23 passedtests/run/test-prepared-packet— 4/4 passed