Help us shape the future of Go! Take the 2026 Go Developer Survey

dataset

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Commits = bigquery.TableMetadata{
	Name: "commits",
	TimePartitioning: &bigquery.TimePartitioning{
		Type:  bigquery.MonthPartitioningType,
		Field: "date",
	},
	Schema: bigquery.Schema{
		{Name: "owner", Type: bigquery.StringFieldType, Required: true},
		{Name: "repository", Type: bigquery.StringFieldType, Required: true},
		{Name: "login", Type: bigquery.StringFieldType, Required: true},
		{Name: "sha", Type: bigquery.StringFieldType, Required: true},
		{Name: "date", Type: bigquery.TimestampFieldType, Required: true},
		{Name: "message", Type: bigquery.StringFieldType, Required: true},
	},
}
View Source
var Events = bigquery.TableMetadata{
	Name: "events",
	TimePartitioning: &bigquery.TimePartitioning{
		Type:  bigquery.MonthPartitioningType,
		Field: "created_at",
	},
	Schema: bigquery.Schema{
		{Name: "owner", Type: bigquery.StringFieldType, Required: true},
		{Name: "repository", Type: bigquery.StringFieldType, Required: true},
		{Name: "login", Type: bigquery.StringFieldType, Required: true},
		{Name: "id", Type: bigquery.StringFieldType, Required: true},
		{Name: "created_at", Type: bigquery.TimestampFieldType, Required: true},
		{Name: "type", Type: bigquery.StringFieldType, Required: true},
		{Name: "raw_payload", Type: bigquery.StringFieldType, Required: true},
	},
}
View Source
var EventsPush = bigquery.TableMetadata{
	Name: "events_push",
	TimePartitioning: &bigquery.TimePartitioning{
		Type:  bigquery.MonthPartitioningType,
		Field: "created_at",
	},
	Schema: bigquery.Schema{
		{Name: "owner", Type: bigquery.StringFieldType, Required: true},
		{Name: "repository", Type: bigquery.StringFieldType, Required: true},
		{Name: "login", Type: bigquery.StringFieldType, Required: true},
		{Name: "id", Type: bigquery.StringFieldType, Required: true},
		{Name: "created_at", Type: bigquery.TimestampFieldType, Required: true},
		{Name: "type", Type: bigquery.StringFieldType, Required: true},
		{Name: "head_sha", Type: bigquery.StringFieldType, Required: true},
		{Name: "sha", Type: bigquery.StringFieldType, Required: true},
		{Name: "message", Type: bigquery.StringFieldType, Required: true},
	},
}
View Source
var Incidents = bigquery.TableMetadata{
	Name: "incidents",
	TimePartitioning: &bigquery.TimePartitioning{
		Type:  bigquery.MonthPartitioningType,
		Field: "resolved_at",
	},
	Schema: bigquery.Schema{
		{Name: "owner", Type: bigquery.StringFieldType, Required: true},
		{Name: "repository", Type: bigquery.StringFieldType, Required: true},
		{Name: "description", Type: bigquery.StringFieldType, Required: true},
		{Name: "sha", Type: bigquery.StringFieldType, Required: true},
		{Name: "resolved_at", Type: bigquery.TimestampFieldType, Required: true},
	},
}
View Source
var PullReqCommits = bigquery.TableMetadata{
	Name: "pullreqs_commits",
	TimePartitioning: &bigquery.TimePartitioning{
		Type:  bigquery.MonthPartitioningType,
		Field: "date",
	},
	Schema: bigquery.Schema{
		{Name: "owner", Type: bigquery.StringFieldType, Required: true},
		{Name: "repository", Type: bigquery.StringFieldType, Required: true},
		{Name: "login", Type: bigquery.StringFieldType, Required: true},
		{Name: "id", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "number", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "sha", Type: bigquery.StringFieldType, Required: true},
		{Name: "date", Type: bigquery.TimestampFieldType, Required: true},
		{Name: "message", Type: bigquery.StringFieldType, Required: true},
	},
}
View Source
var PullReqs = bigquery.TableMetadata{
	Name: "pullreqs",
	TimePartitioning: &bigquery.TimePartitioning{
		Type:  bigquery.MonthPartitioningType,
		Field: "created_at",
	},
	Schema: bigquery.Schema{
		{Name: "owner", Type: bigquery.StringFieldType, Required: true},
		{Name: "repository", Type: bigquery.StringFieldType, Required: true},
		{Name: "login", Type: bigquery.StringFieldType, Required: true},
		{Name: "id", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "number", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "title", Type: bigquery.StringFieldType, Required: true},
		{Name: "state", Type: bigquery.StringFieldType, Required: true},
		{Name: "created_at", Type: bigquery.TimestampFieldType, Required: true},
		{Name: "updated_at", Type: bigquery.TimestampFieldType},
		{Name: "merged_at", Type: bigquery.TimestampFieldType},
		{Name: "closed_at", Type: bigquery.TimestampFieldType},
		{Name: "merge_commit_sha", Type: bigquery.StringFieldType, Required: true},
	},
}
View Source
var Releases = bigquery.TableMetadata{
	Name: "releases",
	TimePartitioning: &bigquery.TimePartitioning{
		Type:  bigquery.MonthPartitioningType,
		Field: "created_at",
	},
	Schema: bigquery.Schema{
		{Name: "owner", Type: bigquery.StringFieldType, Required: true},
		{Name: "repository", Type: bigquery.StringFieldType, Required: true},
		{Name: "login", Type: bigquery.StringFieldType, Required: true},
		{Name: "id", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "name", Type: bigquery.StringFieldType, Required: true},
		{Name: "tag_name", Type: bigquery.StringFieldType, Required: true},
		{Name: "tag_sha", Type: bigquery.StringFieldType, Required: true},
		{Name: "target_commitish", Type: bigquery.StringFieldType, Required: true},
		{Name: "created_at", Type: bigquery.TimestampFieldType, Required: true},
		{Name: "published_at", Type: bigquery.TimestampFieldType, Required: true},
	},
}
View Source
var WorkflowJobs = bigquery.TableMetadata{
	Name: "workflow_jobs",
	TimePartitioning: &bigquery.TimePartitioning{
		Type:  bigquery.MonthPartitioningType,
		Field: "started_at",
	},
	Schema: bigquery.Schema{
		{Name: "owner", Type: bigquery.StringFieldType, Required: true},
		{Name: "repository", Type: bigquery.StringFieldType, Required: true},
		{Name: "workflow_id", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "workflow_name", Type: bigquery.StringFieldType, Required: true},
		{Name: "run_id", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "run_number", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "job_id", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "job_name", Type: bigquery.StringFieldType, Required: true},
		{Name: "status", Type: bigquery.StringFieldType, Required: true},
		{Name: "conclusion", Type: bigquery.StringFieldType},
		{Name: "started_at", Type: bigquery.TimestampFieldType, Required: true},
		{Name: "completed_at", Type: bigquery.TimestampFieldType},
	},
}
View Source
var WorkflowRuns = bigquery.TableMetadata{
	Name: "workflow_runs",
	TimePartitioning: &bigquery.TimePartitioning{
		Type:  bigquery.MonthPartitioningType,
		Field: "created_at",
	},
	Schema: bigquery.Schema{
		{Name: "owner", Type: bigquery.StringFieldType, Required: true},
		{Name: "repository", Type: bigquery.StringFieldType, Required: true},
		{Name: "workflow_id", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "workflow_name", Type: bigquery.StringFieldType, Required: true},
		{Name: "run_id", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "run_number", Type: bigquery.IntegerFieldType, Required: true},
		{Name: "status", Type: bigquery.StringFieldType, Required: true},
		{Name: "conclusion", Type: bigquery.StringFieldType},
		{Name: "created_at", Type: bigquery.TimestampFieldType, Required: true},
		{Name: "updated_at", Type: bigquery.TimestampFieldType},
		{Name: "head_sha", Type: bigquery.StringFieldType, Required: true},
	},
}

Functions

func Create

func Create(ctx context.Context, dsn string, meta []bigquery.TableMetadata) error

func Delete

func Delete(ctx context.Context, dsn string, tables []bigquery.TableMetadata) error

func DeleteAllView

func DeleteAllView(ctx context.Context, dsn string) error

func Insert

func Insert(ctx context.Context, dsn, table string, items []interface{}) error

func Name

func Name(owner, repository string) string

func Query

func Query(ctx context.Context, query string, fn func(values []bigquery.Value)) error

Types

type Client

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

func New

func New(ctx context.Context) (*Client, error)

func (*Client) Close

func (c *Client) Close() error

func (*Client) Create

func (c *Client) Create(ctx context.Context, dsn string, meta []bigquery.TableMetadata) error

func (*Client) Delete

func (c *Client) Delete(ctx context.Context, dsn string, tables []bigquery.TableMetadata) error

func (*Client) DeleteAllView

func (c *Client) DeleteAllView(ctx context.Context, dsn string) error

func (*Client) Insert

func (c *Client) Insert(ctx context.Context, dsn, table string, items []interface{}) error

func (*Client) Query

func (c *Client) Query(ctx context.Context, query string, fn func(values []bigquery.Value)) error

type Commit

type Commit struct {
	Owner      string    `bigquery:"owner"`
	Repository string    `bigquery:"repository"`
	SHA        string    `bigquery:"sha"`
	Login      string    `bigquery:"login"`
	Date       time.Time `bigquery:"date"`
	Message    string    `bigquery:"message"`
}

type Event

type Event struct {
	Owner      string    `bigquery:"owner"`
	Repository string    `bigquery:"repository"`
	ID         string    `bigquery:"id"`
	CreatedAt  time.Time `bigquery:"created_at"`
	Login      string    `bigquery:"login"`
	Type       string    `bigquery:"type"`
	RawPayload string    `bigquery:"raw_payload"`
}

type Incident

type Incident struct {
	Owner       string    `bigquery:"owner" json:"owner"`
	Repository  string    `bigquery:"repository" json:"repository"`
	Description string    `bigquery:"description" json:"description"`
	SHA         string    `bigquery:"sha" json:"sha"`
	ResolvedAt  time.Time `bigquery:"resolved_at" json:"resolved_at"`
}

type PullReq

type PullReq struct {
	Owner          string    `bigquery:"owner"`
	Repository     string    `bigquery:"repository"`
	ID             int64     `bigquery:"id"`
	Number         int64     `bigquery:"number"`
	Login          string    `bigquery:"login"`
	Title          string    `bigquery:"title"`
	State          string    `bigquery:"state"`
	CreatedAt      time.Time `bigquery:"created_at"`
	UpdatedAt      time.Time `bigquery:"updated_at"`
	MergedAt       time.Time `bigquery:"merged_at"`
	ClosedAt       time.Time `bigquery:"closed_at"`
	MergeCommitSHA string    `bigquery:"merge_commit_sha"`
}

type PullReqCommit

type PullReqCommit struct {
	Owner      string    `bigquery:"owner"`
	Repository string    `bigquery:"repository"`
	ID         int64     `bigquery:"id"`
	Number     int64     `bigquery:"number"`
	SHA        string    `bigquery:"sha"`
	Login      string    `bigquery:"login"`
	Date       time.Time `bigquery:"date"`
	Message    string    `bigquery:"message"`
}

type PushEvent

type PushEvent struct {
	Owner      string    `bigquery:"owner"`
	Repository string    `bigquery:"repository"`
	ID         string    `bigquery:"id"`
	CreatedAt  time.Time `bigquery:"created_at"`
	Login      string    `bigquery:"login"`
	Type       string    `bigquery:"type"`
	HeadSHA    string    `bigquery:"head_sha"`
	SHA        string    `bigquery:"sha"`
	Message    string    `bigquery:"message"`
}

type Release

type Release struct {
	Owner           string    `bigquery:"owner"`
	Repository      string    `bigquery:"repository"`
	ID              int64     `bigquery:"id"`
	TagName         string    `bigquery:"tag_name"`
	TagSHA          string    `bigquery:"tag_sha"`
	Login           string    `bigquery:"login"`
	TargetCommitish string    `bigquery:"target_commitish"`
	Name            string    `bigquery:"name"`
	CreatedAt       time.Time `bigquery:"created_at"`
	PublishedAt     time.Time `bigquery:"published_at"`
}

type WorkflowJob

type WorkflowJob struct {
	Owner        string    `bigquery:"owner"`
	Repository   string    `bigquery:"repository"`
	WorkflowID   int64     `bigquery:"workflow_id"`
	WorkflowName string    `bigquery:"workflow_name"`
	RunID        int64     `bigquery:"run_id"`
	RunNumber    int64     `bigquery:"run_number"`
	JobID        int64     `bigquery:"job_id"`
	JobName      string    `bigquery:"job_name"`
	Status       string    `bigquery:"status"`
	Conclusion   string    `bigquery:"conclusion"`
	StartedAt    time.Time `bigquery:"started_at"`
	CompletedAt  time.Time `bigquery:"completed_at"`
}

type WorkflowRun

type WorkflowRun struct {
	Owner        string    `bigquery:"owner"`
	Repository   string    `bigquery:"repository"`
	WorkflowID   int64     `bigquery:"workflow_id"`
	WorkflowName string    `bigquery:"workflow_name"`
	RunID        int64     `bigquery:"run_id"`
	RunNumber    int64     `bigquery:"run_number"`
	Status       string    `bigquery:"status"`
	Conclusion   string    `bigquery:"conclusion"`
	CreatedAt    time.Time `bigquery:"created_at"`
	UpdatedAt    time.Time `bigquery:"updated_at"`
	HeadSHA      string    `bigquery:"head_sha"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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