bq

package
v1.1.2 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DatasetNameDefault = "disco"
)

Variables

This section is empty.

Functions

func ImportLicenses

func ImportLicenses(ctx context.Context, req *types.ImportRequest, in ...*types.LicenseReport) error

func ImportPackages added in v0.8.1

func ImportPackages(ctx context.Context, req *types.ImportRequest, in ...*types.PackageReport) error

func ImportVulnerabilities

func ImportVulnerabilities(ctx context.Context, req *types.ImportRequest, in ...*types.VulnerabilityReport) error

func ParseImportRequest added in v0.9.5

func ParseImportRequest(k types.DiscoKind, v string) (*types.ImportRequest, error)

ParseImportRequest parses import request. e.g. bq://cloudy-demos.disco.packages

Types

type LicenseRow

type LicenseRow struct {
	BatchID int64
	Image   string
	Sha     string
	Name    string
	Package string
	Updated string
}

func MakeLicenseRows

func MakeLicenseRows(in ...*types.LicenseReport) []*LicenseRow

func (*LicenseRow) Save

func (i *LicenseRow) Save() (map[string]bigquery.Value, string, error)

type PackageRow added in v0.8.1

type PackageRow struct {
	BatchID        int64
	Image          string
	Sha            string
	Format         string
	Provider       string
	Package        string
	PackageVersion string
	Source         string
	License        string
	Updated        string
}

func MakePackageRows added in v0.9.5

func MakePackageRows(in ...*types.PackageReport) []*PackageRow

func (*PackageRow) Save added in v0.8.1

func (i *PackageRow) Save() (map[string]bigquery.Value, string, error)

type VulnerabilityRow

type VulnerabilityRow struct {
	BatchID        int64
	Image          string
	Sha            string
	CVE            string
	Severity       string
	Package        string
	PackageVersion string
	Title          string
	Description    string
	URL            string
	Updated        string
}

func MakeVulnerabilityRows

func MakeVulnerabilityRows(in ...*types.VulnerabilityReport) []*VulnerabilityRow

func (*VulnerabilityRow) Save

func (i *VulnerabilityRow) Save() (map[string]bigquery.Value, string, error)

Jump to

Keyboard shortcuts

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