v1

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2019 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package v1 is a container for endpoints that are used to power the v1 of the service.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CloudAssetChanges

type CloudAssetChanges struct {
	Changes      []NetworkChanges  `json:"changes"`
	ChangeTime   string            `json:"changeTime"`
	ResourceType string            `json:"resourceType"`
	AccountID    string            `json:"accountId"`
	Region       string            `json:"region"`
	ARN          string            `json:"arn"`
	Tags         map[string]string `json:"tags"`
}

CloudAssetChanges represents the incoming payload

type CloudAssetDetails

type CloudAssetDetails struct {
	PrivateIPAddresses []string          `json:"privateIpAddresses"`
	PublicIPAddresses  []string          `json:"publicIpAddresses"`
	Hostnames          []string          `json:"hostnames"`
	ResourceType       string            `json:"resourceType"`
	AccountID          string            `json:"accountId"`
	Region             string            `json:"region"`
	ARN                string            `json:"arn"`
	Tags               map[string]string `json:"tags"`
}

CloudAssetDetails represent an asset and associated attributes

type CloudAssetFetchByHostnameParameters

type CloudAssetFetchByHostnameParameters struct {
	Hostname  string `json:"hostname"`
	Timestamp string `json:"time"`
}

CloudAssetFetchByHostnameParameters represents the incoming payload for fetching cloud assets by hostname

type CloudAssetFetchByIPParameters

type CloudAssetFetchByIPParameters struct {
	IPAddress string `json:"ipAddress"`
	Timestamp string `json:"time"`
}

CloudAssetFetchByIPParameters represents the incoming payload for fetching cloud assets by IP address

type CloudAssets

type CloudAssets struct {
	Assets []CloudAssetDetails `json:"assets"`
}

CloudAssets represents a list of assets

type CloudFetchByHostnameHandler

type CloudFetchByHostnameHandler struct {
	LogFn   domain.LogFn
	StatFn  domain.StatFn
	Fetcher domain.CloudAssetByHostnameFetcher
}

CloudFetchByHostnameHandler defines a lambda handler for fetching cloud assets with a given hostname

func (*CloudFetchByHostnameHandler) Handle

Handle handles fetching cloud assets by hostname

type CloudFetchByIPHandler

type CloudFetchByIPHandler struct {
	LogFn   domain.LogFn
	StatFn  domain.StatFn
	Fetcher domain.CloudAssetByIPFetcher
}

CloudFetchByIPHandler defines a lambda handler for fetching cloud assets with a given IP address

func (*CloudFetchByIPHandler) Handle

Handle handles fetching cloud assets by IP address

type CloudInsertHandler

type CloudInsertHandler struct {
	LogFn            domain.LogFn
	StatFn           domain.StatFn
	CloudAssetStorer domain.CloudAssetStorer
}

CloudInsertHandler defines a lambda handler for inserting new cloud asset or changes to existing cloud assets

func (*CloudInsertHandler) Handle

Handle handles the insert operation for cloud assets

type CreatePartitionHandler added in v0.2.0

type CreatePartitionHandler struct {
	LogFn     domain.LogFn
	Generator domain.PartitionGenerator
}

CreatePartitionHandler handles requests for creating the next time-based partition

func (*CreatePartitionHandler) Handle added in v0.2.0

Handle handles the partition creation request

type CreatePartitionInput added in v0.2.0

type CreatePartitionInput struct {
	Begin time.Time `json:"begin"`
	Days  int       `json:"days"`
}

CreatePartitionInput has two optional values begin - the start date for the partition days - the duration in number of days for which the partition will capture data

type DeletePartitionsHandler added in v0.4.0

type DeletePartitionsHandler struct {
	LogFn   domain.LogFn
	Deleter domain.PartitionsDeleter
}

DeletePartitionsHandler handles requests for deleting partitions

func (*DeletePartitionsHandler) Handle added in v0.4.0

Handle handles the partition creation request

type DeletePartitionsInput added in v0.4.0

type DeletePartitionsInput struct {
	Name string `json:"name"`
}

DeletePartitionsInput contains the partition name to delete.

type GetPartitionsHandler added in v0.3.0

type GetPartitionsHandler struct {
	LogFn  domain.LogFn
	Getter domain.PartitionsGetter
}

GetPartitionsHandler handles requests for getting the time based partitions

func (*GetPartitionsHandler) Handle added in v0.3.0

Handle handles the partition creation request

type GetPartitionsOutput added in v0.3.0

type GetPartitionsOutput struct {
	Results []Partition `json:"results"`
}

GetPartitionsOutput returns the list of current partitions

type InvalidInput

type InvalidInput struct {
	Field string
	Cause error
}

InvalidInput is an error indicating the request was malformed

func (InvalidInput) Error

func (i InvalidInput) Error() string

type NetworkChanges

type NetworkChanges struct {
	PrivateIPAddresses []string `json:"privateIpAddresses"`
	PublicIPAddresses  []string `json:"publicIpAddresses"`
	Hostnames          []string `json:"hostnames"`
	ChangeType         string   `json:"changeType"`
}

NetworkChanges detail the changes in ip addresses and host names for an asset

type NotFound

type NotFound struct {
	ID string
}

NotFound is an error indicating no assets with the given ID were found

func (NotFound) Error

func (n NotFound) Error() string

type Partition added in v0.3.0

type Partition struct {
	Name      string    `json:"name"`
	CreatedAt time.Time `json:"createdAt"`
	Begin     time.Time `json:"begin"`
	End       time.Time `json:"end"`
	Count     int       `json:"count"`
}

Partition represents a created database partition

Jump to

Keyboard shortcuts

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