gitlab

package
v0.0.0-...-8b3eb0f Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Commits

type Commits []*gitlab.Commit

Commits is a slice of git commits

func GetCommitsInRange

func GetCommitsInRange(ctx context.Context, client *gitlab.Client, opts models.ListCommitsOptions, from time.Time, to time.Time) (Commits, error)

GetCommitsInRange lists all commits in a repository within a time range.

func (Commits) Frames

func (c Commits) Frames() data.Frames

Frames converts the list of commits to a Grafana DataFrame

type Datasource

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

Datasource handles requests to GitLab.

func NewDatasource

func NewDatasource(ctx context.Context, settings models.Settings) *Datasource

NewDatasource creates a new datasource for handling queries.

func (*Datasource) CheckHealth

func (d *Datasource) CheckHealth(ctx context.Context) error

CheckHealth calls frequently used endpoints to determine if the client has sufficient privileges.

func (*Datasource) HandleCommitsQuery

func (d *Datasource) HandleCommitsQuery(ctx context.Context, query *models.CommitsQuery, req backend.DataQuery) (dfutil.Framer, error)

HandleCommitsQuery is the query handler for listing GitLab Commits

Jump to

Keyboard shortcuts

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