postgres

package
v0.0.24 Latest Latest
Warning

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

Go to latest
Published: Jun 1, 2020 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 Store

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

store implements all interfaces in the vulnstore package

func NewVulnStore

func NewVulnStore(db *sqlx.DB, pool *pgxpool.Pool) *Store

func TestStore

func TestStore(ctx context.Context, t testing.TB) (*sqlx.DB, *Store, func())

func (*Store) DeleteUpdateOperations added in v0.0.18

func (s *Store) DeleteUpdateOperations(ctx context.Context, id ...uuid.UUID) error

DeleteUpdateOperations implements vulnstore.Updater.

func (*Store) Get

func (s *Store) Get(ctx context.Context, records []*claircore.IndexRecord, opts vulnstore.GetOpts) (map[string][]*claircore.Vulnerability, error)

Get implements vulnstore.Vulnerability.

func (*Store) GetLatestUpdateRef added in v0.0.18

func (s *Store) GetLatestUpdateRef(ctx context.Context) (uuid.UUID, error)

GetLatestUpdateRef implements driver.Updater.

func (*Store) GetLatestUpdateRefs added in v0.0.18

func (s *Store) GetLatestUpdateRefs(ctx context.Context) (map[string]uuid.UUID, error)

func (*Store) GetUpdateDiff added in v0.0.18

func (s *Store) GetUpdateDiff(ctx context.Context, a, b uuid.UUID) (*driver.UpdateDiff, error)

func (*Store) GetUpdateOperationDiff added in v0.0.18

func (s *Store) GetUpdateOperationDiff(ctx context.Context, a, b uuid.UUID) (*driver.UpdateDiff, error)

GetUpdateOperationDiff implements vulnstore.Updater.

func (*Store) GetUpdateOperations added in v0.0.18

func (s *Store) GetUpdateOperations(ctx context.Context, updater ...string) (map[string][]driver.UpdateOperation, error)

GetUpdateOperations implements vulnstore.Updater.

func (*Store) UpdateVulnerabilities added in v0.0.18

func (s *Store) UpdateVulnerabilities(ctx context.Context, updater string, fingerprint driver.Fingerprint, vulns []*claircore.Vulnerability) (uuid.UUID, error)

UpdateVulnerabilities implements vulnstore.Updater.

Jump to

Keyboard shortcuts

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