Documentation ¶
Index ¶
- type PacketAssembly
- func (pa *PacketAssembly) AsConn() net.Conn
- func (pa *PacketAssembly) Close() error
- func (pa *PacketAssembly) GetProcess(slot int) float64
- func (pa *PacketAssembly) GetReleasedShard(slot int) int
- func (pa *PacketAssembly) GetRemainingShard(slot int) int
- func (pa *PacketAssembly) GetSentShard(slot int) int
- func (pa *PacketAssembly) GetTotalShard(slot int) int
- func (pa *PacketAssembly) Report()
- func (pa *PacketAssembly) Rx()
- func (pa *PacketAssembly) SelectPacketToSend(quota int) []int
- func (pa *PacketAssembly) TrafficShapingFunc(process float64) float64
- func (pa *PacketAssembly) Tx()
- func (pa *PacketAssembly) TxWithoutFEC(pack []byte) bool
- type PacketWireHead
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PacketAssembly ¶
type PacketAssembly struct { RxReassembleBuffer *cache.Cache TxNextSeq uint32 TxRingBuffer []packetAssemblyTxChunkHolder TxRingBufferSize int RxChan chan []byte TxChan chan []byte TxNoFECChan chan []byte MaxDataShardPerChunk int RxMaxTimeInSecond int FECEnabled uint32 TxEpochTimeInMs int TxFECSoftPacketSoftLimitPerEpoch int TxEpocSeq uint64 RxShardOriginalNoFEC uint64 RxShardOriginal uint64 RxShardRecovered uint64 TxShardOriginal uint64 TxShardFEC uint64 TxShardOriginalNoFEC uint64 RxBytes uint64 TxBytes uint64 // contains filtered or unexported fields }
func NewPacketAssembly ¶
func NewPacketAssembly(ctx context.Context, conn net.Conn) *PacketAssembly
func (*PacketAssembly) AsConn ¶
func (pa *PacketAssembly) AsConn() net.Conn
func (*PacketAssembly) Close ¶
func (pa *PacketAssembly) Close() error
func (*PacketAssembly) GetProcess ¶
func (pa *PacketAssembly) GetProcess(slot int) float64
func (*PacketAssembly) GetReleasedShard ¶
func (pa *PacketAssembly) GetReleasedShard(slot int) int
func (*PacketAssembly) GetRemainingShard ¶
func (pa *PacketAssembly) GetRemainingShard(slot int) int
func (*PacketAssembly) GetSentShard ¶
func (pa *PacketAssembly) GetSentShard(slot int) int
func (*PacketAssembly) GetTotalShard ¶
func (pa *PacketAssembly) GetTotalShard(slot int) int
func (*PacketAssembly) Report ¶
func (pa *PacketAssembly) Report()
func (*PacketAssembly) Rx ¶
func (pa *PacketAssembly) Rx()
func (*PacketAssembly) SelectPacketToSend ¶
func (pa *PacketAssembly) SelectPacketToSend(quota int) []int
Return number of packet to send for each slot
func (*PacketAssembly) TrafficShapingFunc ¶
func (pa *PacketAssembly) TrafficShapingFunc(process float64) float64
func (*PacketAssembly) Tx ¶
func (pa *PacketAssembly) Tx()
func (*PacketAssembly) TxWithoutFEC ¶
func (pa *PacketAssembly) TxWithoutFEC(pack []byte) bool
type PacketWireHead ¶
Click to show internal directories.
Click to hide internal directories.