bigquery

package
v1.6.0-preview.1 Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2023 License: AGPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	GCPProjectID   = "project"
	GCPCredentials = "credentials"
	GCPLocation    = "location"
)

String constants for bigquery destination config

Variables

This section is empty.

Functions

func Connect

func Connect(context context.Context, cred *BQCredentialsT) (*bigquery.Client, error)

func Init

func Init()

Types

type BQCredentialsT

type BQCredentialsT struct {
	ProjectID   string
	Credentials string
}

type HandleT

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

func (*HandleT) AddColumns

func (bq *HandleT) AddColumns(tableName string, columnsInfo []warehouseutils.ColumnInfo) (err error)

func (*HandleT) AlterColumn

func (*HandleT) AlterColumn(_, _, _ string) (model.AlterTableResponse, error)

func (*HandleT) Cleanup

func (bq *HandleT) Cleanup()

func (*HandleT) Connect

func (bq *HandleT) Connect(warehouse warehouseutils.Warehouse) (client.Client, error)

func (*HandleT) CrashRecover

func (bq *HandleT) CrashRecover(warehouse warehouseutils.Warehouse) (err error)

func (*HandleT) CreateSchema

func (bq *HandleT) CreateSchema() (err error)

func (*HandleT) CreateTable

func (bq *HandleT) CreateTable(tableName string, columnMap map[string]string) (err error)

func (*HandleT) DeleteBy

func (bq *HandleT) DeleteBy(tableNames []string, params warehouseutils.DeleteByParams) error

func (*HandleT) DeleteTable

func (bq *HandleT) DeleteTable(tableName string) (err error)

func (*HandleT) DownloadIdentityRules

func (bq *HandleT) DownloadIdentityRules(gzWriter *misc.GZipWriter) (err error)

func (*HandleT) DropTable

func (bq *HandleT) DropTable(tableName string) (err error)

func (*HandleT) FetchSchema

func (bq *HandleT) FetchSchema(warehouse warehouseutils.Warehouse) (schema, unrecognizedSchema warehouseutils.SchemaT, err error)

FetchSchema queries bigquery and returns the schema associated with provided namespace

func (*HandleT) GetTotalCountInTable

func (bq *HandleT) GetTotalCountInTable(ctx context.Context, tableName string) (total int64, err error)

func (*HandleT) IsEmpty

func (bq *HandleT) IsEmpty(warehouse warehouseutils.Warehouse) (empty bool, err error)

func (*HandleT) LoadIdentityMappingsTable

func (bq *HandleT) LoadIdentityMappingsTable() (err error)

func (*HandleT) LoadIdentityMergeRulesTable

func (bq *HandleT) LoadIdentityMergeRulesTable() (err error)

func (*HandleT) LoadTable

func (bq *HandleT) LoadTable(tableName string) error

func (*HandleT) LoadTestTable

func (bq *HandleT) LoadTestTable(location, tableName string, _ map[string]interface{}, _ string) (err error)

func (*HandleT) LoadUserTables

func (bq *HandleT) LoadUserTables() (errorMap map[string]error)

func (*HandleT) SetConnectionTimeout

func (*HandleT) SetConnectionTimeout(_ time.Duration)

func (*HandleT) Setup

func (bq *HandleT) Setup(warehouse warehouseutils.Warehouse, uploader warehouseutils.UploaderI) (err error)

func (*HandleT) TestConnection

func (bq *HandleT) TestConnection(warehouse warehouseutils.Warehouse) (err error)

type StagingLoadTableT

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

Jump to

Keyboard shortcuts

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