gcp

package
v0.10.0 Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2021 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AllProjects

func AllProjects(ctx context.Context) (list []string)

func IsBigQueryEnabled

func IsBigQueryEnabled(client *asset.Client, ctx context.Context, projectID string) bool

IsBigQueryEnabled returns wheter a GCP project has bigquery.googleapis.com enabled.

func RunBigQuery

func RunBigQuery(ctx context.Context, p model.Params, query string) (model.CostComputation, error)

func ServiceUsageIsBigQueryEnabled added in v0.9.2

func ServiceUsageIsBigQueryEnabled(ctx context.Context, project string) bool

ServiceUsageIsBigQueryEnabled returns wheter a GCP project has bigquery.googleapis.com enabled.

Types

type StackDriver

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

StackDriver provides the api to send a moneypenny result

func NewStackDriver

func NewStackDriver(projectID string) (*StackDriver, error)

NewStackDriver create a connected StackDriver for a given project for which metrics are created.

func (*StackDriver) Close

func (s *StackDriver) Close() error

Close closes the metrics client

func (*StackDriver) SendMetrics

func (s *StackDriver) SendMetrics(opex string, lines []model.LabeledCost, dryrun bool) error

SendReport will sends metrics to StackDriver using measurements of a samples.

Jump to

Keyboard shortcuts

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