Class InboundMessageFragments

java.lang.Object
net.i2p.router.transport.udp.InboundMessageFragments

class InboundMessageFragments extends Object
Organize the received data message fragments, feeding completed messages to the MessageReceiver and telling the PeerState to ACK. In addition, it drops failed fragments and keeps a minimal list of the most recently completed messages (even though higher up in the router we have full blown replay detection, its nice to have a basic line of defense here).
  • Constructor Details

  • Method Details

    • startup

      public void startup()
    • shutdown

      public void shutdown()
    • isAlive

      public boolean isAlive()
    • receiveData

      public void receiveData(PeerState from, UDPPacketReader.DataReader data)
      Pull the fragments and ACKs out of the authenticated data packet SSU 1 only.
    • messageReceived

      public boolean messageReceived(long messageID)
      This message was received. SSU 2 only. No stats updated here, caller should handle stats.
      Returns:
      true if this message was a duplicate
      Since:
      0.9.54
    • wasRecentlyReceived

      public boolean wasRecentlyReceived(long messageID)
      Was this message recently received? SSU 2 only. No stats updated here, caller should handle stats.
      Returns:
      true if this message was recently received.
      Since:
      0.9.54