Documentation
¶
Index ¶
- Constants
- type CHF
- func (s CHF) AppProtocol() uint32
- func (s CHF) Big() bool
- func (s CHF) Custom() (Custom_List, error)
- func (s CHF) DeviceId() uint32
- func (s CHF) DstAs() uint32
- func (s CHF) DstBgpAsPath() (string, error)
- func (s CHF) DstBgpAsPathBytes() ([]byte, error)
- func (s CHF) DstBgpCommunity() (string, error)
- func (s CHF) DstBgpCommunityBytes() ([]byte, error)
- func (s CHF) DstEthMac() uint64
- func (s CHF) DstFlowTags() (string, error)
- func (s CHF) DstFlowTagsBytes() ([]byte, error)
- func (s CHF) DstGeo() uint32
- func (s CHF) DstGeoCity() uint32
- func (s CHF) DstGeoRegion() uint32
- func (s CHF) DstMac() uint32
- func (s CHF) DstNextHopAs() uint32
- func (s CHF) DstRouteLength() uint8
- func (s CHF) DstRoutePrefix() uint32
- func (s CHF) DstSecondAsn() uint32
- func (s CHF) DstThirdAsn() uint32
- func (s CHF) FlowTags() (string, error)
- func (s CHF) FlowTagsBytes() ([]byte, error)
- func (s CHF) HasCustom() bool
- func (s CHF) HasDstBgpAsPath() bool
- func (s CHF) HasDstBgpCommunity() bool
- func (s CHF) HasDstFlowTags() bool
- func (s CHF) HasFlowTags() bool
- func (s CHF) HasIpv6DstAddr() bool
- func (s CHF) HasIpv6DstNextHop() bool
- func (s CHF) HasIpv6DstRoutePrefix() bool
- func (s CHF) HasIpv6SrcAddr() bool
- func (s CHF) HasIpv6SrcNextHop() bool
- func (s CHF) HasIpv6SrcRoutePrefix() bool
- func (s CHF) HasSrcBgpAsPath() bool
- func (s CHF) HasSrcBgpCommunity() bool
- func (s CHF) HasSrcFlowTags() bool
- func (s CHF) HeaderLen() uint32
- func (s CHF) InBytes() uint64
- func (s CHF) InPkts() uint64
- func (s CHF) InputPort() uint32
- func (s CHF) IpSize() uint32
- func (s CHF) Ipv4DstAddr() uint32
- func (s CHF) Ipv4DstNextHop() uint32
- func (s CHF) Ipv4NextHop() uint32
- func (s CHF) Ipv4SrcAddr() uint32
- func (s CHF) Ipv4SrcNextHop() uint32
- func (s CHF) Ipv6DstAddr() ([]byte, error)
- func (s CHF) Ipv6DstNextHop() ([]byte, error)
- func (s CHF) Ipv6DstRoutePrefix() ([]byte, error)
- func (s CHF) Ipv6SrcAddr() ([]byte, error)
- func (s CHF) Ipv6SrcNextHop() ([]byte, error)
- func (s CHF) Ipv6SrcRoutePrefix() ([]byte, error)
- func (s CHF) IsMetric() bool
- func (s CHF) L4DstPort() uint32
- func (s CHF) L4SrcPort() uint32
- func (s CHF) MplsType() uint32
- func (s CHF) NewCustom(n int32) (Custom_List, error)
- func (s CHF) OutBytes() uint64
- func (s CHF) OutPkts() uint64
- func (s CHF) OutputPort() uint32
- func (s CHF) Protocol() uint32
- func (s CHF) SampleAdj() bool
- func (s CHF) SampleRate() uint32
- func (s CHF) SampledPacketSize() uint32
- func (s CHF) SetAppProtocol(v uint32)
- func (s CHF) SetBig(v bool)
- func (s CHF) SetCustom(v Custom_List) error
- func (s CHF) SetDeviceId(v uint32)
- func (s CHF) SetDstAs(v uint32)
- func (s CHF) SetDstBgpAsPath(v string) error
- func (s CHF) SetDstBgpCommunity(v string) error
- func (s CHF) SetDstEthMac(v uint64)
- func (s CHF) SetDstFlowTags(v string) error
- func (s CHF) SetDstGeo(v uint32)
- func (s CHF) SetDstGeoCity(v uint32)
- func (s CHF) SetDstGeoRegion(v uint32)
- func (s CHF) SetDstMac(v uint32)
- func (s CHF) SetDstNextHopAs(v uint32)
- func (s CHF) SetDstRouteLength(v uint8)
- func (s CHF) SetDstRoutePrefix(v uint32)
- func (s CHF) SetDstSecondAsn(v uint32)
- func (s CHF) SetDstThirdAsn(v uint32)
- func (s CHF) SetFlowTags(v string) error
- func (s CHF) SetHeaderLen(v uint32)
- func (s CHF) SetInBytes(v uint64)
- func (s CHF) SetInPkts(v uint64)
- func (s CHF) SetInputPort(v uint32)
- func (s CHF) SetIpSize(v uint32)
- func (s CHF) SetIpv4DstAddr(v uint32)
- func (s CHF) SetIpv4DstNextHop(v uint32)
- func (s CHF) SetIpv4NextHop(v uint32)
- func (s CHF) SetIpv4SrcAddr(v uint32)
- func (s CHF) SetIpv4SrcNextHop(v uint32)
- func (s CHF) SetIpv6DstAddr(v []byte) error
- func (s CHF) SetIpv6DstNextHop(v []byte) error
- func (s CHF) SetIpv6DstRoutePrefix(v []byte) error
- func (s CHF) SetIpv6SrcAddr(v []byte) error
- func (s CHF) SetIpv6SrcNextHop(v []byte) error
- func (s CHF) SetIpv6SrcRoutePrefix(v []byte) error
- func (s CHF) SetIsMetric(v bool)
- func (s CHF) SetL4DstPort(v uint32)
- func (s CHF) SetL4SrcPort(v uint32)
- func (s CHF) SetMplsType(v uint32)
- func (s CHF) SetOutBytes(v uint64)
- func (s CHF) SetOutPkts(v uint64)
- func (s CHF) SetOutputPort(v uint32)
- func (s CHF) SetProtocol(v uint32)
- func (s CHF) SetSampleAdj(v bool)
- func (s CHF) SetSampleRate(v uint32)
- func (s CHF) SetSampledPacketSize(v uint32)
- func (s CHF) SetSrcAs(v uint32)
- func (s CHF) SetSrcBgpAsPath(v string) error
- func (s CHF) SetSrcBgpCommunity(v string) error
- func (s CHF) SetSrcEthMac(v uint64)
- func (s CHF) SetSrcFlowTags(v string) error
- func (s CHF) SetSrcGeo(v uint32)
- func (s CHF) SetSrcGeoCity(v uint32)
- func (s CHF) SetSrcGeoRegion(v uint32)
- func (s CHF) SetSrcMac(v uint32)
- func (s CHF) SetSrcNextHopAs(v uint32)
- func (s CHF) SetSrcRouteLength(v uint8)
- func (s CHF) SetSrcRoutePrefix(v uint32)
- func (s CHF) SetSrcSecondAsn(v uint32)
- func (s CHF) SetSrcThirdAsn(v uint32)
- func (s CHF) SetTcpFlags(v uint32)
- func (s CHF) SetTcpRetransmit(v uint32)
- func (s CHF) SetTimestamp(v int64)
- func (s CHF) SetTimestampNano(v int64)
- func (s CHF) SetTos(v uint32)
- func (s CHF) SetVlanIn(v uint32)
- func (s CHF) SetVlanOut(v uint32)
- func (s CHF) SrcAs() uint32
- func (s CHF) SrcBgpAsPath() (string, error)
- func (s CHF) SrcBgpAsPathBytes() ([]byte, error)
- func (s CHF) SrcBgpCommunity() (string, error)
- func (s CHF) SrcBgpCommunityBytes() ([]byte, error)
- func (s CHF) SrcEthMac() uint64
- func (s CHF) SrcFlowTags() (string, error)
- func (s CHF) SrcFlowTagsBytes() ([]byte, error)
- func (s CHF) SrcGeo() uint32
- func (s CHF) SrcGeoCity() uint32
- func (s CHF) SrcGeoRegion() uint32
- func (s CHF) SrcMac() uint32
- func (s CHF) SrcNextHopAs() uint32
- func (s CHF) SrcRouteLength() uint8
- func (s CHF) SrcRoutePrefix() uint32
- func (s CHF) SrcSecondAsn() uint32
- func (s CHF) SrcThirdAsn() uint32
- func (s CHF) String() string
- func (s CHF) TcpFlags() uint32
- func (s CHF) TcpRetransmit() uint32
- func (s CHF) Timestamp() int64
- func (s CHF) TimestampNano() int64
- func (s CHF) Tos() uint32
- func (s CHF) VlanIn() uint32
- func (s CHF) VlanOut() uint32
- type CHF_List
- type CHF_Promise
- type Custom
- type Custom_List
- type Custom_Promise
- type Custom_value
- func (s Custom_value) AddrVal() ([]byte, error)
- func (s Custom_value) Float32Val() float32
- func (s Custom_value) HasAddrVal() bool
- func (s Custom_value) HasStrVal() bool
- func (s Custom_value) SetAddrVal(v []byte) error
- func (s Custom_value) SetFloat32Val(v float32)
- func (s Custom_value) SetStrVal(v string) error
- func (s Custom_value) SetUint16Val(v uint16)
- func (s Custom_value) SetUint32Val(v uint32)
- func (s Custom_value) SetUint64Val(v uint64)
- func (s Custom_value) SetUint8Val(v uint8)
- func (s Custom_value) StrVal() (string, error)
- func (s Custom_value) StrValBytes() ([]byte, error)
- func (s Custom_value) Uint16Val() uint16
- func (s Custom_value) Uint32Val() uint32
- func (s Custom_value) Uint64Val() uint64
- func (s Custom_value) Uint8Val() uint8
- func (s Custom_value) Which() Custom_value_Which
- type Custom_value_Promise
- type Custom_value_Which
- type CustomsIndex
- type PackedCHF
- type PackedCHF_List
- type PackedCHF_Promise
- type Uint32Slice
Constants ¶
const CHF_TypeID = 0xa7ab5c68e4bc7b62
CHF_TypeID is the unique identifier for the type CHF.
const Custom_TypeID = 0xed5d37861203d027
Custom_TypeID is the unique identifier for the type Custom.
const PackedCHF_TypeID = 0xb158a6a28e2d29c2
PackedCHF_TypeID is the unique identifier for the type PackedCHF.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CHF ¶
func (CHF) AppProtocol ¶
func (CHF) Custom ¶
func (s CHF) Custom() (Custom_List, error)
func (CHF) DstBgpAsPath ¶
func (CHF) DstBgpAsPathBytes ¶
func (CHF) DstBgpCommunity ¶
func (CHF) DstBgpCommunityBytes ¶
func (CHF) DstFlowTags ¶
func (CHF) DstFlowTagsBytes ¶
func (CHF) DstGeoCity ¶
func (CHF) DstGeoRegion ¶
func (CHF) DstNextHopAs ¶
func (CHF) DstRouteLength ¶
func (CHF) DstRoutePrefix ¶
func (CHF) DstSecondAsn ¶
func (CHF) DstThirdAsn ¶
func (CHF) FlowTagsBytes ¶
func (CHF) HasDstBgpAsPath ¶
func (CHF) HasDstBgpCommunity ¶
func (CHF) HasDstFlowTags ¶
func (CHF) HasFlowTags ¶
func (CHF) HasIpv6DstAddr ¶
func (CHF) HasIpv6DstNextHop ¶
func (CHF) HasIpv6DstRoutePrefix ¶
func (CHF) HasIpv6SrcAddr ¶
func (CHF) HasIpv6SrcNextHop ¶
func (CHF) HasIpv6SrcRoutePrefix ¶
func (CHF) HasSrcBgpAsPath ¶
func (CHF) HasSrcBgpCommunity ¶
func (CHF) HasSrcFlowTags ¶
func (CHF) Ipv4DstAddr ¶
func (CHF) Ipv4DstNextHop ¶
func (CHF) Ipv4NextHop ¶
func (CHF) Ipv4SrcAddr ¶
func (CHF) Ipv4SrcNextHop ¶
func (CHF) Ipv6DstAddr ¶
func (CHF) Ipv6DstNextHop ¶
func (CHF) Ipv6DstRoutePrefix ¶
func (CHF) Ipv6SrcAddr ¶
func (CHF) Ipv6SrcNextHop ¶
func (CHF) Ipv6SrcRoutePrefix ¶
func (CHF) NewCustom ¶
func (s CHF) NewCustom(n int32) (Custom_List, error)
NewCustom sets the custom field to a newly allocated Custom_List, preferring placement in s's segment.
func (CHF) OutputPort ¶
func (CHF) SampleRate ¶
func (CHF) SampledPacketSize ¶
func (CHF) SetAppProtocol ¶
func (CHF) SetCustom ¶
func (s CHF) SetCustom(v Custom_List) error
func (CHF) SetDeviceId ¶
func (CHF) SetDstBgpAsPath ¶
func (CHF) SetDstBgpCommunity ¶
func (CHF) SetDstEthMac ¶
func (CHF) SetDstFlowTags ¶
func (CHF) SetDstGeoCity ¶
func (CHF) SetDstGeoRegion ¶
func (CHF) SetDstNextHopAs ¶
func (CHF) SetDstRouteLength ¶
func (CHF) SetDstRoutePrefix ¶
func (CHF) SetDstSecondAsn ¶
func (CHF) SetDstThirdAsn ¶
func (CHF) SetFlowTags ¶
func (CHF) SetHeaderLen ¶
func (CHF) SetInBytes ¶
func (CHF) SetInputPort ¶
func (CHF) SetIpv4DstAddr ¶
func (CHF) SetIpv4DstNextHop ¶
func (CHF) SetIpv4NextHop ¶
func (CHF) SetIpv4SrcAddr ¶
func (CHF) SetIpv4SrcNextHop ¶
func (CHF) SetIpv6DstAddr ¶
func (CHF) SetIpv6DstNextHop ¶
func (CHF) SetIpv6DstRoutePrefix ¶
func (CHF) SetIpv6SrcAddr ¶
func (CHF) SetIpv6SrcNextHop ¶
func (CHF) SetIpv6SrcRoutePrefix ¶
func (CHF) SetIsMetric ¶
func (CHF) SetL4DstPort ¶
func (CHF) SetL4SrcPort ¶
func (CHF) SetMplsType ¶
func (CHF) SetOutBytes ¶
func (CHF) SetOutPkts ¶
func (CHF) SetOutputPort ¶
func (CHF) SetProtocol ¶
func (CHF) SetSampleAdj ¶
func (CHF) SetSampleRate ¶
func (CHF) SetSampledPacketSize ¶
func (CHF) SetSrcBgpAsPath ¶
func (CHF) SetSrcBgpCommunity ¶
func (CHF) SetSrcEthMac ¶
func (CHF) SetSrcFlowTags ¶
func (CHF) SetSrcGeoCity ¶
func (CHF) SetSrcGeoRegion ¶
func (CHF) SetSrcNextHopAs ¶
func (CHF) SetSrcRouteLength ¶
func (CHF) SetSrcRoutePrefix ¶
func (CHF) SetSrcSecondAsn ¶
func (CHF) SetSrcThirdAsn ¶
func (CHF) SetTcpFlags ¶
func (CHF) SetTcpRetransmit ¶
func (CHF) SetTimestamp ¶
func (CHF) SetTimestampNano ¶
func (CHF) SetVlanOut ¶
func (CHF) SrcBgpAsPath ¶
func (CHF) SrcBgpAsPathBytes ¶
func (CHF) SrcBgpCommunity ¶
func (CHF) SrcBgpCommunityBytes ¶
func (CHF) SrcFlowTags ¶
func (CHF) SrcFlowTagsBytes ¶
func (CHF) SrcGeoCity ¶
func (CHF) SrcGeoRegion ¶
func (CHF) SrcNextHopAs ¶
func (CHF) SrcRouteLength ¶
func (CHF) SrcRoutePrefix ¶
func (CHF) SrcSecondAsn ¶
func (CHF) SrcThirdAsn ¶
func (CHF) TcpRetransmit ¶
func (CHF) TimestampNano ¶
type CHF_Promise ¶
CHF_Promise is a wrapper for a CHF promised by a client call.
func (CHF_Promise) Struct ¶
func (p CHF_Promise) Struct() (CHF, error)
type Custom ¶
func (Custom) IsDimension ¶
func (Custom) SetIsDimension ¶
func (Custom) Value ¶
func (s Custom) Value() Custom_value
type Custom_List ¶
Custom_List is a list of Custom.
func NewCustom_List ¶
func NewCustom_List(s *capnp.Segment, sz int32) (Custom_List, error)
NewCustom creates a new list of Custom.
func (Custom_List) At ¶
func (s Custom_List) At(i int) Custom
func (Custom_List) String ¶
func (s Custom_List) String() string
type Custom_Promise ¶
Custom_Promise is a wrapper for a Custom promised by a client call.
func (Custom_Promise) Struct ¶
func (p Custom_Promise) Struct() (Custom, error)
func (Custom_Promise) Value ¶
func (p Custom_Promise) Value() Custom_value_Promise
type Custom_value ¶
type Custom_value Custom
func (Custom_value) AddrVal ¶
func (s Custom_value) AddrVal() ([]byte, error)
func (Custom_value) Float32Val ¶
func (s Custom_value) Float32Val() float32
func (Custom_value) HasAddrVal ¶
func (s Custom_value) HasAddrVal() bool
func (Custom_value) HasStrVal ¶
func (s Custom_value) HasStrVal() bool
func (Custom_value) SetAddrVal ¶
func (s Custom_value) SetAddrVal(v []byte) error
func (Custom_value) SetFloat32Val ¶
func (s Custom_value) SetFloat32Val(v float32)
func (Custom_value) SetStrVal ¶
func (s Custom_value) SetStrVal(v string) error
func (Custom_value) SetUint16Val ¶
func (s Custom_value) SetUint16Val(v uint16)
func (Custom_value) SetUint32Val ¶
func (s Custom_value) SetUint32Val(v uint32)
func (Custom_value) SetUint64Val ¶
func (s Custom_value) SetUint64Val(v uint64)
func (Custom_value) SetUint8Val ¶
func (s Custom_value) SetUint8Val(v uint8)
func (Custom_value) StrVal ¶
func (s Custom_value) StrVal() (string, error)
func (Custom_value) StrValBytes ¶
func (s Custom_value) StrValBytes() ([]byte, error)
func (Custom_value) Uint16Val ¶
func (s Custom_value) Uint16Val() uint16
func (Custom_value) Uint32Val ¶
func (s Custom_value) Uint32Val() uint32
func (Custom_value) Uint64Val ¶
func (s Custom_value) Uint64Val() uint64
func (Custom_value) Uint8Val ¶
func (s Custom_value) Uint8Val() uint8
func (Custom_value) Which ¶
func (s Custom_value) Which() Custom_value_Which
type Custom_value_Promise ¶
Custom_value_Promise is a wrapper for a Custom_value promised by a client call.
func (Custom_value_Promise) Struct ¶
func (p Custom_value_Promise) Struct() (Custom_value, error)
type Custom_value_Which ¶
type Custom_value_Which uint16
const ( Custom_value_Which_uint32Val Custom_value_Which = 0 Custom_value_Which_float32Val Custom_value_Which = 1 Custom_value_Which_strVal Custom_value_Which = 2 Custom_value_Which_uint64Val Custom_value_Which = 3 Custom_value_Which_addrVal Custom_value_Which = 4 Custom_value_Which_uint16Val Custom_value_Which = 5 Custom_value_Which_uint8Val Custom_value_Which = 6 )
func (Custom_value_Which) String ¶
func (w Custom_value_Which) String() string
type CustomsIndex ¶
type CustomsIndex struct {
// contains filtered or unexported fields
}
CustomsIndex indexes a company's custom column values for a single flow record at a time in a performant way, using a few slices (two []uint32 and one []Custom_value), no maps, no clean-up processing when finished with a flow. The only allocations made are three slices at initialization.
Performance: - when indexing a flow, we scan its Customs list once, read once from a []uint32, write to two slices - when fetching a Custom by custom dimension ID, we read from 3 slices
func NewCustomsIndex ¶
func NewCustomsIndex(companyCIDs []uint32) *CustomsIndex
NewCustomsIndex builds a new CustomsIndex for a company, with all of the custom dimension IDs that will be considered.
func (*CustomsIndex) CustomColumnWithID ¶
func (c *CustomsIndex) CustomColumnWithID(customDimensionID uint32) (Custom_value, bool)
CustomColumnWithID returns custom column for the input ID - make sure to check the second "found" return value. If false, you'll likely get dangerous garbage you shouldn't mess with.
func (*CustomsIndex) IndexFlow ¶
func (c *CustomsIndex) IndexFlow(flow CHF)
IndexFlow indexes the input flow - the flow's customs will only ever be scanned once
type PackedCHF ¶
type PackedCHF_List ¶
PackedCHF_List is a list of PackedCHF.
func NewPackedCHF_List ¶
func NewPackedCHF_List(s *capnp.Segment, sz int32) (PackedCHF_List, error)
NewPackedCHF creates a new list of PackedCHF.
func (PackedCHF_List) At ¶
func (s PackedCHF_List) At(i int) PackedCHF
func (PackedCHF_List) String ¶
func (s PackedCHF_List) String() string
type PackedCHF_Promise ¶
PackedCHF_Promise is a wrapper for a PackedCHF promised by a client call.
func (PackedCHF_Promise) Struct ¶
func (p PackedCHF_Promise) Struct() (PackedCHF, error)
type Uint32Slice ¶
type Uint32Slice []uint32
Uint32Slice attaches the methods of sort.Interface to []uint32, sorting in increasing order.
func (Uint32Slice) Len ¶
func (s Uint32Slice) Len() int
func (Uint32Slice) Less ¶
func (s Uint32Slice) Less(i, j int) bool
func (Uint32Slice) Swap ¶
func (s Uint32Slice) Swap(i, j int)