Skip to content

Commit

Permalink
small docs for writer
Browse files Browse the repository at this point in the history
  • Loading branch information
Frank Lee committed Dec 31, 2024
1 parent 6442d41 commit 415ab3f
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/worker/writer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,18 @@ use crate::{
utils::common::BluefinResult,
};

/// Internal representation of an ack. These fields will be used to build a Bluefin ack packet.
#[derive(Clone, Copy)]
struct AckData {
base_packet_num: u64,
num_packets_consumed: usize,
}

/// [WriterHandler] is a handle for all write operations to the network. The writer handler is
/// responsible for accepting bytes, dividing them into Bluefin packets and then eventually sending
/// them on to the network. The handler ensures that the order in which the sends arrive at are
/// preserved and that we fit at most [MAX_BLUEFIN_BYTES_IN_UDP_DATAGRAM] bytes of bluefin packets
/// into a single UDP datagram.
#[derive(Clone)]
pub(crate) struct WriterHandler {
socket: Arc<UdpSocket>,
Expand Down

0 comments on commit 415ab3f

Please sign in to comment.