26 #ifndef NFD_DAEMON_FACE_GENERIC_LINK_SERVICE_HPP
27 #define NFD_DAEMON_FACE_GENERIC_LINK_SERVICE_HPP
217 sendLpPacket(lp::Packet&& pkt);
231 assignSequences(std::vector<lp::Packet>& pkts);
239 encodeLpFields(const
ndn::PacketBase& netPkt, lp::Packet& lpPacket);
246 sendNetPacket(lp::Packet&& pkt,
bool isInterest);
253 checkCongestionLevel(lp::Packet& pkt);
268 decodeNetPacket(const Block& netPkt, const lp::Packet& firstPkt, const
EndpointId& endpointId);
281 decodeInterest(const Block& netPkt, const lp::Packet& firstPkt, const
EndpointId& endpointId);
294 decodeData(const Block& netPkt, const lp::Packet& firstPkt, const
EndpointId& endpointId);
307 decodeNack(const Block& netPkt, const lp::Packet& firstPkt, const
EndpointId& endpointId);
314 lp::Sequence m_lastSeqNo = static_cast<lp::Sequence>(-2);
318 time::steady_clock::time_point m_nextMarkTime = time::steady_clock::time_point::max();
320 size_t m_nMarkedSinceInMarkingState = 0;
Represents a counter of number of packets.
Provides a counter that observes the size of a table.
Counters provided by GenericLinkService.
PacketCounter nRetxExhausted
Count of network-layer packets dropped because a fragment reached the maximum number of retransmissio...
PacketCounter nAcknowledged
Count of network-layer packets that did not require retransmission of a fragment.
PacketCounter nInNetInvalid
Count of invalid reassembled network-layer packets dropped.
PacketCounter nDuplicateSequence
Count of LpPackets dropped due to duplicate Sequence numbers.
SizeCounter< LpReassembler > nReassembling
Count of network-layer packets currently being reassembled.
PacketCounter nFragmentationErrors
Count of failed fragmentations.
PacketCounter nRetransmitted
Count of network-layer packets that had at least one fragment retransmitted, but were eventually rece...
PacketCounter nCongestionMarked
Count of outgoing LpPackets that were marked with congestion marks.
PacketCounter nOutOverMtu
Count of outgoing LpPackets dropped due to exceeding MTU limit.
PacketCounter nInLpInvalid
Count of invalid LpPackets dropped before reassembly.
PacketCounter nReassemblyTimeouts
Count of dropped partial network-layer packets due to reassembly timeout.
GenericLinkService is a LinkService that implements the NDNLPv2 protocol.
const Options & getOptions() const
Get the options used by GenericLinkService.
GenericLinkServiceCounters Counters
Counters provided by GenericLinkService.
GenericLinkServiceOptions Options
Options for GenericLinkService.
ssize_t getEffectiveMtu() const final
void setOptions(const Options &options)
Sets the options used by GenericLinkService.
GenericLinkService(const Options &options={})
const Counters & getCounters() const final
bool canOverrideMtuTo(ssize_t mtu) const
Whether MTU can be overridden to the specified value.
Counters provided by LinkService.
The upper half of a Face.
Fragments network-layer packets into NDNLPv2 link-layer packets.
Reassembles fragmented network-layer packets.
Provides for reliable sending and receiving of link-layer packets.
#define NFD_OVERRIDE_WITH_TESTS_ELSE_FINAL
#define NFD_PUBLIC_WITH_TESTS_ELSE_PRIVATE
#define NFD_FINAL_UNLESS_WITH_TESTS
#define NFD_PROTECTED_WITH_TESTS_ELSE_PRIVATE
std::variant< std::monostate, ethernet::Address, udp::Endpoint > EndpointId
Identifies a remote endpoint on the link.
Options that control the behavior of GenericLinkService.
bool allowReassembly
Enables reassembly.
LpReassembler::Options reassemblerOptions
Options for reassembly.
LpFragmenter::Options fragmenterOptions
Options for fragmentation.
bool allowCongestionMarking
Enables send queue congestion detection and marking.
bool allowFragmentation
Enables fragmentation.
LpReliability::Options reliabilityOptions
Options for reliability.
bool allowSelfLearning
Enables self-learning forwarding support.
size_t defaultCongestionThreshold
Default congestion threshold in bytes.
time::nanoseconds baseCongestionMarkingInterval
Starting value for congestion marking interval.
ssize_t overrideMtu
Overrides the MTU provided by Transport.
bool allowLocalFields
Enables encoding of IncomingFaceId, and decoding of NextHopFaceId and CachePolicy.
Options that control the behavior of LpFragmenter.
Options that control the behavior of LpReassembler.