producer

package
v2.1.0+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 1, 2019 License: BSD-3-Clause Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertNetFlowDataSet

func ConvertNetFlowDataSet(version uint16, baseTime uint32, uptime uint32, record []netflow.DataField) *flowmessage.FlowMessage

func DecodeUNumber

func DecodeUNumber(b []byte, out interface{}) error

func GetSFlowFlowSamples

func GetSFlowFlowSamples(packet *sflow.Packet) []interface{}

func NetFlowLookFor

func NetFlowLookFor(dataFields []netflow.DataField, typeId uint16) (bool, interface{})

func NetFlowPopulate

func NetFlowPopulate(dataFields []netflow.DataField, typeId uint16, addr interface{}) bool

func ParseSampledHeader

func ParseSampledHeader(flowMessage *flowmessage.FlowMessage, sampledHeader *sflow.SampledHeader) error

func ProcessMessageNetFlow

func ProcessMessageNetFlow(msgDec interface{}, samplingRateSys SamplingRateSystem) ([]*flowmessage.FlowMessage, error)

Convert a NetFlow datastructure to a FlowMessage protobuf Does not put sampling rate

func ProcessMessageSFlow

func ProcessMessageSFlow(msgDec interface{}) ([]*flowmessage.FlowMessage, error)

func SearchNetFlowDataSets

func SearchNetFlowDataSets(version uint16, baseTime uint32, uptime uint32, dataFlowSet []netflow.DataFlowSet) []*flowmessage.FlowMessage

func SearchNetFlowDataSetsRecords

func SearchNetFlowDataSetsRecords(version uint16, baseTime uint32, uptime uint32, dataRecords []netflow.DataRecord) []*flowmessage.FlowMessage

func SearchNetFlowOptionDataSets

func SearchNetFlowOptionDataSets(dataFlowSet []netflow.OptionsDataFlowSet) (uint32, bool)

func SearchSFlowSamples

func SearchSFlowSamples(samples []interface{}) []*flowmessage.FlowMessage

Types

type SamplingRateSystem

type SamplingRateSystem interface {
	GetSamplingRate(version uint16, obsDomainId uint32) (uint32, error)
	AddSamplingRate(version uint16, obsDomainId uint32, samplingRate uint32)
}

func CreateSamplingSystem

func CreateSamplingSystem() SamplingRateSystem

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL