Documentation ¶
Overview ¶
Package flowaggregator defines tools for aggregating observed netflows.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WaitForFlowsToBeFlushed ¶
func WaitForFlowsToBeFlushed(aggregator *FlowAggregator, timeoutDuration time.Duration, minEvents uint64) (uint64, error)
WaitForFlowsToBeFlushed waits up to timeoutDuration for at least minEvents flows to be flushed by the aggregator. It is intended for testing.
Types ¶
type FlowAggregator ¶
type FlowAggregator struct { FlushFlowsToSendInterval time.Duration // interval for checking flows to flush and send them to EP Forwarder TimeNowFunction func() time.Time // Allows to mock time in tests // contains filtered or unexported fields }
FlowAggregator is used for space and time aggregation of NetFlow flows
func NewFlowAggregator ¶
func NewFlowAggregator(sender sender.Sender, epForwarder eventplatform.Forwarder, config *config.NetflowConfig, hostname string, logger log.Component, rdnsQuerier rdnsquerier.Component) *FlowAggregator
NewFlowAggregator returns a new FlowAggregator
func (*FlowAggregator) GetFlowInChan ¶
func (agg *FlowAggregator) GetFlowInChan() chan *common.Flow
GetFlowInChan returns flow input chan
func (*FlowAggregator) Start ¶
func (agg *FlowAggregator) Start()
Start will start the FlowAggregator worker
func (*FlowAggregator) Stop ¶
func (agg *FlowAggregator) Stop()
Stop will stop running FlowAggregator
Click to show internal directories.
Click to hide internal directories.