subscriber

package
v0.23.0 Latest Latest
Warning

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

Go to latest
Published: May 17, 2019 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SecurityAdvisorFlow added in v0.23.0

type SecurityAdvisorFlow struct {
	UUID             string                    `json:"UUID,omitempty"`
	LayersPath       string                    `json:"LayersPath,omitempty"`
	Version          string                    `json:"Version,omitempty"`
	Status           string                    `json:"Status,omitempty"`
	FinishType       string                    `json:"FinishType,omitempty"`
	Network          *SecurityAdvisorFlowLayer `json:"Network,omitempty"`
	Transport        *SecurityAdvisorFlowLayer `json:"Transport,omitempty"`
	LastUpdateMetric *flow.FlowMetric          `json:"LastUpdateMetric,omitempty"`
	Metric           *flow.FlowMetric          `json:"Metric,omitempty"`
	Start            int64                     `json:"Start"`
	Last             int64                     `json:"Last"`
	UpdateCount      int64                     `json:"UpdateCount"`
	NodeType         string                    `json:"NodeType,omitempty"`
}

SecurityAdvisorFlow represents a security advisor flow

type SecurityAdvisorFlowLayer added in v0.23.0

type SecurityAdvisorFlowLayer struct {
	Protocol string `json:"Protocol,omitempty"`
	A        string `json:"A,omitempty"`
	B        string `json:"B,omitempty"`
	AName    string `json:"A_Name,omitempty"`
	BName    string `json:"B_Name,omitempty"`
}

SecurityAdvisorFlowLayer is the flow layer for a security advisor flow

type Storage added in v0.23.0

type Storage struct {
	// contains filtered or unexported fields
}

Storage allows writing flows to an object storage service

func (*Storage) DeleteObject added in v0.23.0

func (s *Storage) DeleteObject(objectKey *string) error

DeleteObject deletes an object

func (*Storage) ListObjects added in v0.23.0

func (s *Storage) ListObjects() ([]*string, error)

ListObjects lists all stored objects

func (*Storage) OnStructMessage added in v0.23.0

func (s *Storage) OnStructMessage(c ws.Speaker, msg *ws.StructMessage)

OnStructMessage is triggered when WS server sends us a message.

func (*Storage) ReadObjectFlows added in v0.23.0

func (s *Storage) ReadObjectFlows(objectKey *string, objectFlows interface{}) error

ReadObjectFlows reads flows from object

func (*Storage) StoreFlows added in v0.23.0

func (s *Storage) StoreFlows(flows []*flow.Flow) error

StoreFlows store flows in memory, before being written to the object store

type Subscriber

type Subscriber struct {
	// contains filtered or unexported fields
}

Subscriber represents a flow subscriber writing to object store

func NewSubscriberFromConfig added in v0.23.0

func NewSubscriberFromConfig(cfg *viper.Viper) (*Subscriber, error)

NewSubscriberFromConfig returns a new flow subscriber writing to object store

func (*Subscriber) GetStorage added in v0.23.0

func (s *Subscriber) GetStorage() *Storage

GetStorage returns the backing storage client

func (*Subscriber) Start added in v0.23.0

func (s *Subscriber) Start()

Start starts the object store flow subscriber

func (*Subscriber) Stop added in v0.23.0

func (s *Subscriber) Stop()

Stop stops the object store flow subscriber

Jump to

Keyboard shortcuts

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