flow

package
v0.0.0-...-87dde2e Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2019 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ReleaseIP

func ReleaseIP(vrf uint64, ip *bnet.IP)

ReleaseIP releases an ip

func ReleasePrefix

func ReleasePrefix(agent *bnet.IP, vrf uint64, p *bnet.Prefix)

ReleasePrefix releases a prefix

Types

type ASN

type ASN struct {
	Asn                  uint32            `protobuf:"varint,1,opt,name=asn,proto3" json:"asn,omitempty"`
	Metadata             map[string]string `` /* 157-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*ASN) Descriptor

func (*ASN) Descriptor() ([]byte, []int)

func (*ASN) GetAsn

func (m *ASN) GetAsn() uint32

func (*ASN) GetMetadata

func (m *ASN) GetMetadata() map[string]string

func (*ASN) ProtoMessage

func (*ASN) ProtoMessage()

func (*ASN) Reset

func (m *ASN) Reset()

func (*ASN) String

func (m *ASN) String() string

func (*ASN) XXX_DiscardUnknown

func (m *ASN) XXX_DiscardUnknown()

func (*ASN) XXX_Marshal

func (m *ASN) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ASN) XXX_Merge

func (m *ASN) XXX_Merge(src proto.Message)

func (*ASN) XXX_Size

func (m *ASN) XXX_Size() int

func (*ASN) XXX_Unmarshal

func (m *ASN) XXX_Unmarshal(b []byte) error

type Flow

type Flow struct {
	Agent                *IPAddress `protobuf:"bytes,1,opt,name=agent,proto3" json:"agent,omitempty"`
	Vrf                  *VRF       `protobuf:"bytes,2,opt,name=vrf,proto3" json:"vrf,omitempty"`
	IntIn                *Interface `protobuf:"bytes,3,opt,name=int_in,json=intIn,proto3" json:"int_in,omitempty"`
	IntOut               *Interface `protobuf:"bytes,4,opt,name=int_out,json=intOut,proto3" json:"int_out,omitempty"`
	IpFlow               *IPFlow    `protobuf:"bytes,5,opt,name=ip_flow,json=ipFlow,proto3" json:"ip_flow,omitempty"`
	NextHopIp            *IPAddress `protobuf:"bytes,7,opt,name=next_hop_ip,json=nextHopIp,proto3" json:"next_hop_ip,omitempty"`
	SrcPrefix            *Prefix    `protobuf:"bytes,8,opt,name=src_prefix,json=srcPrefix,proto3" json:"src_prefix,omitempty"`
	DstPrefix            *Prefix    `protobuf:"bytes,9,opt,name=dst_prefix,json=dstPrefix,proto3" json:"dst_prefix,omitempty"`
	PacketsCount         uint64     `protobuf:"varint,13,opt,name=packets_count,json=packetsCount,proto3" json:"packets_count,omitempty"`
	BytesCount           uint64     `protobuf:"varint,14,opt,name=bytes_count,json=bytesCount,proto3" json:"bytes_count,omitempty"`
	XXX_NoUnkeyedLiteral struct{}   `json:"-"`
	XXX_unrecognized     []byte     `json:"-"`
	XXX_sizecache        int32      `json:"-"`
}

func (*Flow) Descriptor

func (*Flow) Descriptor() ([]byte, []int)

func (*Flow) GetAgent

func (m *Flow) GetAgent() *IPAddress

func (*Flow) GetBytesCount

func (m *Flow) GetBytesCount() uint64

func (*Flow) GetDstPrefix

func (m *Flow) GetDstPrefix() *Prefix

func (*Flow) GetIntIn

func (m *Flow) GetIntIn() *Interface

func (*Flow) GetIntOut

func (m *Flow) GetIntOut() *Interface

func (*Flow) GetIpFlow

func (m *Flow) GetIpFlow() *IPFlow

func (*Flow) GetNextHopIp

func (m *Flow) GetNextHopIp() *IPAddress

func (*Flow) GetPacketsCount

func (m *Flow) GetPacketsCount() uint64

func (*Flow) GetSrcPrefix

func (m *Flow) GetSrcPrefix() *Prefix

func (*Flow) GetVrf

func (m *Flow) GetVrf() *VRF

func (*Flow) ProtoMessage

func (*Flow) ProtoMessage()

func (*Flow) Reset

func (m *Flow) Reset()

func (*Flow) String

func (m *Flow) String() string

func (*Flow) XXX_DiscardUnknown

func (m *Flow) XXX_DiscardUnknown()

func (*Flow) XXX_Marshal

func (m *Flow) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Flow) XXX_Merge

func (m *Flow) XXX_Merge(src proto.Message)

func (*Flow) XXX_Size

func (m *Flow) XXX_Size() int

func (*Flow) XXX_Unmarshal

func (m *Flow) XXX_Unmarshal(b []byte) error

type FlowFile

type FlowFile struct {
	IpAddresses          []*IPAddress  `protobuf:"bytes,1,rep,name=ip_addresses,json=ipAddresses,proto3" json:"ip_addresses,omitempty"`
	Prefixes             []*Prefix     `protobuf:"bytes,2,rep,name=prefixes,proto3" json:"prefixes,omitempty"`
	Asns                 []*ASN        `protobuf:"bytes,3,rep,name=asns,proto3" json:"asns,omitempty"`
	Vrfs                 []*VRF        `protobuf:"bytes,4,rep,name=vrfs,proto3" json:"vrfs,omitempty"`
	Ports                []*Port       `protobuf:"bytes,5,rep,name=ports,proto3" json:"ports,omitempty"`
	Protocols            []*Protocol   `protobuf:"bytes,6,rep,name=protocols,proto3" json:"protocols,omitempty"`
	Interfaces           []*Interface  `protobuf:"bytes,7,rep,name=interfaces,proto3" json:"interfaces,omitempty"`
	FlowRecords          []*FlowRecord `protobuf:"bytes,8,rep,name=flow_records,json=flowRecords,proto3" json:"flow_records,omitempty"`
	XXX_NoUnkeyedLiteral struct{}      `json:"-"`
	XXX_unrecognized     []byte        `json:"-"`
	XXX_sizecache        int32         `json:"-"`
}

func (*FlowFile) Descriptor

func (*FlowFile) Descriptor() ([]byte, []int)

func (*FlowFile) GetAsns

func (m *FlowFile) GetAsns() []*ASN

func (*FlowFile) GetFlowRecords

func (m *FlowFile) GetFlowRecords() []*FlowRecord

func (*FlowFile) GetInterfaces

func (m *FlowFile) GetInterfaces() []*Interface

func (*FlowFile) GetIpAddresses

func (m *FlowFile) GetIpAddresses() []*IPAddress

func (*FlowFile) GetPorts

func (m *FlowFile) GetPorts() []*Port

func (*FlowFile) GetPrefixes

func (m *FlowFile) GetPrefixes() []*Prefix

func (*FlowFile) GetProtocols

func (m *FlowFile) GetProtocols() []*Protocol

func (*FlowFile) GetVrfs

func (m *FlowFile) GetVrfs() []*VRF

func (*FlowFile) ProtoMessage

func (*FlowFile) ProtoMessage()

func (*FlowFile) Reset

func (m *FlowFile) Reset()

func (*FlowFile) String

func (m *FlowFile) String() string

func (*FlowFile) XXX_DiscardUnknown

func (m *FlowFile) XXX_DiscardUnknown()

func (*FlowFile) XXX_Marshal

func (m *FlowFile) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*FlowFile) XXX_Merge

func (m *FlowFile) XXX_Merge(src proto.Message)

func (*FlowFile) XXX_Size

func (m *FlowFile) XXX_Size() int

func (*FlowFile) XXX_Unmarshal

func (m *FlowFile) XXX_Unmarshal(b []byte) error

type FlowRecord

type FlowRecord struct {
	Agent                uint32   `protobuf:"varint,1,opt,name=agent,proto3" json:"agent,omitempty"`
	Vrf                  uint32   `protobuf:"varint,2,opt,name=vrf,proto3" json:"vrf,omitempty"`
	IntIn                uint32   `protobuf:"varint,3,opt,name=int_in,json=intIn,proto3" json:"int_in,omitempty"`
	IntOut               uint32   `protobuf:"varint,4,opt,name=int_out,json=intOut,proto3" json:"int_out,omitempty"`
	SrcIp                uint32   `protobuf:"varint,5,opt,name=src_ip,json=srcIp,proto3" json:"src_ip,omitempty"`
	DstIp                uint32   `protobuf:"varint,6,opt,name=dst_ip,json=dstIp,proto3" json:"dst_ip,omitempty"`
	NextHopIp            uint32   `protobuf:"varint,7,opt,name=next_hop_ip,json=nextHopIp,proto3" json:"next_hop_ip,omitempty"`
	SrcPrefix            uint32   `protobuf:"varint,8,opt,name=src_prefix,json=srcPrefix,proto3" json:"src_prefix,omitempty"`
	DstPrefix            uint32   `protobuf:"varint,9,opt,name=dst_prefix,json=dstPrefix,proto3" json:"dst_prefix,omitempty"`
	Protocol             uint32   `protobuf:"varint,10,opt,name=protocol,proto3" json:"protocol,omitempty"`
	SrcPort              uint32   `protobuf:"varint,11,opt,name=src_port,json=srcPort,proto3" json:"src_port,omitempty"`
	DstPort              uint32   `protobuf:"varint,12,opt,name=dst_port,json=dstPort,proto3" json:"dst_port,omitempty"`
	PacketsCount         uint64   `protobuf:"varint,13,opt,name=packets_count,json=packetsCount,proto3" json:"packets_count,omitempty"`
	BytesCount           uint64   `protobuf:"varint,14,opt,name=bytes_count,json=bytesCount,proto3" json:"bytes_count,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*FlowRecord) Descriptor

func (*FlowRecord) Descriptor() ([]byte, []int)

func (*FlowRecord) GetAgent

func (m *FlowRecord) GetAgent() uint32

func (*FlowRecord) GetBytesCount

func (m *FlowRecord) GetBytesCount() uint64

func (*FlowRecord) GetDstIp

func (m *FlowRecord) GetDstIp() uint32

func (*FlowRecord) GetDstPort

func (m *FlowRecord) GetDstPort() uint32

func (*FlowRecord) GetDstPrefix

func (m *FlowRecord) GetDstPrefix() uint32

func (*FlowRecord) GetIntIn

func (m *FlowRecord) GetIntIn() uint32

func (*FlowRecord) GetIntOut

func (m *FlowRecord) GetIntOut() uint32

func (*FlowRecord) GetNextHopIp

func (m *FlowRecord) GetNextHopIp() uint32

func (*FlowRecord) GetPacketsCount

func (m *FlowRecord) GetPacketsCount() uint64

func (*FlowRecord) GetProtocol

func (m *FlowRecord) GetProtocol() uint32

func (*FlowRecord) GetSrcIp

func (m *FlowRecord) GetSrcIp() uint32

func (*FlowRecord) GetSrcPort

func (m *FlowRecord) GetSrcPort() uint32

func (*FlowRecord) GetSrcPrefix

func (m *FlowRecord) GetSrcPrefix() uint32

func (*FlowRecord) GetVrf

func (m *FlowRecord) GetVrf() uint32

func (*FlowRecord) ProtoMessage

func (*FlowRecord) ProtoMessage()

func (*FlowRecord) Reset

func (m *FlowRecord) Reset()

func (*FlowRecord) String

func (m *FlowRecord) String() string

func (*FlowRecord) XXX_DiscardUnknown

func (m *FlowRecord) XXX_DiscardUnknown()

func (*FlowRecord) XXX_Marshal

func (m *FlowRecord) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*FlowRecord) XXX_Merge

func (m *FlowRecord) XXX_Merge(src proto.Message)

func (*FlowRecord) XXX_Size

func (m *FlowRecord) XXX_Size() int

func (*FlowRecord) XXX_Unmarshal

func (m *FlowRecord) XXX_Unmarshal(b []byte) error

type IPAddress

type IPAddress struct {
	Addr                 *api.IP           `protobuf:"bytes,1,opt,name=addr,proto3" json:"addr,omitempty"`
	Metadata             map[string]string `` /* 157-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func GetIP

func GetIP(vrf uint64, ip *bnet.IP) *IPAddress

GetIP gets an IP

func (*IPAddress) Descriptor

func (*IPAddress) Descriptor() ([]byte, []int)

func (*IPAddress) GetAddr

func (m *IPAddress) GetAddr() *api.IP

func (*IPAddress) GetMetadata

func (m *IPAddress) GetMetadata() map[string]string

func (*IPAddress) ProtoMessage

func (*IPAddress) ProtoMessage()

func (*IPAddress) Reset

func (m *IPAddress) Reset()

func (*IPAddress) String

func (m *IPAddress) String() string

func (*IPAddress) XXX_DiscardUnknown

func (m *IPAddress) XXX_DiscardUnknown()

func (*IPAddress) XXX_Marshal

func (m *IPAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*IPAddress) XXX_Merge

func (m *IPAddress) XXX_Merge(src proto.Message)

func (*IPAddress) XXX_Size

func (m *IPAddress) XXX_Size() int

func (*IPAddress) XXX_Unmarshal

func (m *IPAddress) XXX_Unmarshal(b []byte) error

type IPFlow

type IPFlow struct {
	SrcIp                *IPAddress `protobuf:"bytes,5,opt,name=src_ip,json=srcIp,proto3" json:"src_ip,omitempty"`
	DstIp                *IPAddress `protobuf:"bytes,6,opt,name=dst_ip,json=dstIp,proto3" json:"dst_ip,omitempty"`
	Protocol             *Protocol  `protobuf:"bytes,10,opt,name=protocol,proto3" json:"protocol,omitempty"`
	SrcPort              *Port      `protobuf:"bytes,11,opt,name=src_port,json=srcPort,proto3" json:"src_port,omitempty"`
	DstPort              *Port      `protobuf:"bytes,12,opt,name=dst_port,json=dstPort,proto3" json:"dst_port,omitempty"`
	XXX_NoUnkeyedLiteral struct{}   `json:"-"`
	XXX_unrecognized     []byte     `json:"-"`
	XXX_sizecache        int32      `json:"-"`
}

func (*IPFlow) Descriptor

func (*IPFlow) Descriptor() ([]byte, []int)

func (*IPFlow) GetDstIp

func (m *IPFlow) GetDstIp() *IPAddress

func (*IPFlow) GetDstPort

func (m *IPFlow) GetDstPort() *Port

func (*IPFlow) GetProtocol

func (m *IPFlow) GetProtocol() *Protocol

func (*IPFlow) GetSrcIp

func (m *IPFlow) GetSrcIp() *IPAddress

func (*IPFlow) GetSrcPort

func (m *IPFlow) GetSrcPort() *Port

func (*IPFlow) ProtoMessage

func (*IPFlow) ProtoMessage()

func (*IPFlow) Reset

func (m *IPFlow) Reset()

func (*IPFlow) String

func (m *IPFlow) String() string

func (*IPFlow) XXX_DiscardUnknown

func (m *IPFlow) XXX_DiscardUnknown()

func (*IPFlow) XXX_Marshal

func (m *IPFlow) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*IPFlow) XXX_Merge

func (m *IPFlow) XXX_Merge(src proto.Message)

func (*IPFlow) XXX_Size

func (m *IPFlow) XXX_Size() int

func (*IPFlow) XXX_Unmarshal

func (m *IPFlow) XXX_Unmarshal(b []byte) error

type Interface

type Interface struct {
	Id                   uint32            `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Name                 string            `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	Metadata             map[string]string `` /* 157-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*Interface) Descriptor

func (*Interface) Descriptor() ([]byte, []int)

func (*Interface) GetId

func (m *Interface) GetId() uint32

func (*Interface) GetMetadata

func (m *Interface) GetMetadata() map[string]string

func (*Interface) GetName

func (m *Interface) GetName() string

func (*Interface) ProtoMessage

func (*Interface) ProtoMessage()

func (*Interface) Reset

func (m *Interface) Reset()

func (*Interface) String

func (m *Interface) String() string

func (*Interface) XXX_DiscardUnknown

func (m *Interface) XXX_DiscardUnknown()

func (*Interface) XXX_Marshal

func (m *Interface) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Interface) XXX_Merge

func (m *Interface) XXX_Merge(src proto.Message)

func (*Interface) XXX_Size

func (m *Interface) XXX_Size() int

func (*Interface) XXX_Unmarshal

func (m *Interface) XXX_Unmarshal(b []byte) error

type Port

type Port struct {
	Port                 uint32            `protobuf:"varint,1,opt,name=port,proto3" json:"port,omitempty"`
	Metadata             map[string]string `` /* 157-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*Port) Descriptor

func (*Port) Descriptor() ([]byte, []int)

func (*Port) GetMetadata

func (m *Port) GetMetadata() map[string]string

func (*Port) GetPort

func (m *Port) GetPort() uint32

func (*Port) ProtoMessage

func (*Port) ProtoMessage()

func (*Port) Reset

func (m *Port) Reset()

func (*Port) String

func (m *Port) String() string

func (*Port) XXX_DiscardUnknown

func (m *Port) XXX_DiscardUnknown()

func (*Port) XXX_Marshal

func (m *Port) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Port) XXX_Merge

func (m *Port) XXX_Merge(src proto.Message)

func (*Port) XXX_Size

func (m *Port) XXX_Size() int

func (*Port) XXX_Unmarshal

func (m *Port) XXX_Unmarshal(b []byte) error

type Prefix

type Prefix struct {
	Pfx                  *api.Prefix       `protobuf:"bytes,1,opt,name=pfx,proto3" json:"pfx,omitempty"`
	OriginAsn            uint32            `protobuf:"varint,2,opt,name=origin_asn,json=originAsn,proto3" json:"origin_asn,omitempty"`
	NextAsn              uint32            `protobuf:"varint,3,opt,name=next_asn,json=nextAsn,proto3" json:"next_asn,omitempty"`
	Metadata             map[string]string `` /* 157-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func GetPrefix

func GetPrefix(agent *bnet.IP, vrf uint64, p *bnet.Prefix) *Prefix

GetPrefix gets a prefix

func (*Prefix) Descriptor

func (*Prefix) Descriptor() ([]byte, []int)

func (*Prefix) GetMetadata

func (m *Prefix) GetMetadata() map[string]string

func (*Prefix) GetNextAsn

func (m *Prefix) GetNextAsn() uint32

func (*Prefix) GetOriginAsn

func (m *Prefix) GetOriginAsn() uint32

func (*Prefix) GetPfx

func (m *Prefix) GetPfx() *api.Prefix

func (*Prefix) ProtoMessage

func (*Prefix) ProtoMessage()

func (*Prefix) Reset

func (m *Prefix) Reset()

func (*Prefix) String

func (m *Prefix) String() string

func (*Prefix) XXX_DiscardUnknown

func (m *Prefix) XXX_DiscardUnknown()

func (*Prefix) XXX_Marshal

func (m *Prefix) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Prefix) XXX_Merge

func (m *Prefix) XXX_Merge(src proto.Message)

func (*Prefix) XXX_Size

func (m *Prefix) XXX_Size() int

func (*Prefix) XXX_Unmarshal

func (m *Prefix) XXX_Unmarshal(b []byte) error

type Protocol

type Protocol struct {
	Protocol             uint32            `protobuf:"varint,1,opt,name=protocol,proto3" json:"protocol,omitempty"`
	Metadata             map[string]string `` /* 157-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*Protocol) Descriptor

func (*Protocol) Descriptor() ([]byte, []int)

func (*Protocol) GetMetadata

func (m *Protocol) GetMetadata() map[string]string

func (*Protocol) GetProtocol

func (m *Protocol) GetProtocol() uint32

func (*Protocol) ProtoMessage

func (*Protocol) ProtoMessage()

func (*Protocol) Reset

func (m *Protocol) Reset()

func (*Protocol) String

func (m *Protocol) String() string

func (*Protocol) XXX_DiscardUnknown

func (m *Protocol) XXX_DiscardUnknown()

func (*Protocol) XXX_Marshal

func (m *Protocol) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Protocol) XXX_Merge

func (m *Protocol) XXX_Merge(src proto.Message)

func (*Protocol) XXX_Size

func (m *Protocol) XXX_Size() int

func (*Protocol) XXX_Unmarshal

func (m *Protocol) XXX_Unmarshal(b []byte) error

type VRF

type VRF struct {
	VrfId                uint64            `protobuf:"varint,1,opt,name=vrf_id,json=vrfId,proto3" json:"vrf_id,omitempty"`
	Metadata             map[string]string `` /* 157-byte string literal not displayed */
	XXX_NoUnkeyedLiteral struct{}          `json:"-"`
	XXX_unrecognized     []byte            `json:"-"`
	XXX_sizecache        int32             `json:"-"`
}

func (*VRF) Descriptor

func (*VRF) Descriptor() ([]byte, []int)

func (*VRF) GetMetadata

func (m *VRF) GetMetadata() map[string]string

func (*VRF) GetVrfId

func (m *VRF) GetVrfId() uint64

func (*VRF) ProtoMessage

func (*VRF) ProtoMessage()

func (*VRF) Reset

func (m *VRF) Reset()

func (*VRF) String

func (m *VRF) String() string

func (*VRF) XXX_DiscardUnknown

func (m *VRF) XXX_DiscardUnknown()

func (*VRF) XXX_Marshal

func (m *VRF) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*VRF) XXX_Merge

func (m *VRF) XXX_Merge(src proto.Message)

func (*VRF) XXX_Size

func (m *VRF) XXX_Size() int

func (*VRF) XXX_Unmarshal

func (m *VRF) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

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