api

package
v0.31.0 Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2021 License: BSD-3-Clause Imports: 8 Imported by: 4

Documentation

Index

Constants

View Source
const (
	MediaTypeAny    = "*/*"
	MediaTypeCSV    = "text/csv"
	MediaTypeJSON   = "application/json"
	MediaTypeNDJSON = "application/x-ndjson"
	MediaTypeZJSON  = "application/x-zjson"
	MediaTypeZNG    = "application/x-zng"
	MediaTypeZSON   = "application/x-zson"
)
View Source
const RequestIDHeader = "X-Request-ID"

Variables

View Source
var ErrMediaTypeUnspecified = errors.New("media type unspecified")

Functions

func IsAmbiguousMediaType

func IsAmbiguousMediaType(s string) bool

func MediaTypeToFormat

func MediaTypeToFormat(s string) (string, error)

func RequestIDFromContext

func RequestIDFromContext(ctx context.Context) string

Types

type AuthIdentityResponse

type AuthIdentityResponse struct {
	TenantID string `json:"tenant_id" zed:"tenant_id"`
	UserID   string `json:"user_id" zed:"user_id"`
}

type AuthMethod

type AuthMethod string
const (
	AuthMethodNone  AuthMethod = ""
	AuthMethodAuth0 AuthMethod = "auth0"
)

type AuthMethodAuth0Details

type AuthMethodAuth0Details struct {
	// Audience is the value to use for the "aud" standard claim when
	// requesting an access token for this service.
	Audience string `json:"audience"`
	// ClientID is the public client id to use when interacting with
	// the above Auth0 domain.
	ClientID string `json:"client_id"`
	// Domain is the Auth0 domain (in url form) to use as the endpoint
	// for any oauth flows.
	Domain string `json:"domain"`
}

type AuthMethodResponse

type AuthMethodResponse struct {
	Kind  AuthMethod              `json:"kind" zed:"kind"`
	Auth0 *AuthMethodAuth0Details `json:"auth0,omitempty" zed:"auth0,omitempty"`
}

type BranchMergeRequest

type BranchMergeRequest struct {
	At string `json:"at"`
}

type BranchPostRequest

type BranchPostRequest struct {
	Name   string `json:"name"`
	Commit string `json:"commit"`
}

type CommitMessage

type CommitMessage struct {
	Author string `zed:"author"`
	Body   string `zed:"body"`
}

type CommitResponse

type CommitResponse struct {
	Commit   ksuid.KSUID `zed:"commit"`
	Warnings []string    `zed:"warnings"`
}

type Error

type Error struct {
	Type    string      `json:"type"`
	Kind    string      `json:"kind"`
	Message string      `json:"error"`
	Info    interface{} `json:"info,omitempty"`
}

func (Error) Error

func (e Error) Error() string

type EventBranch

type EventBranch struct {
	PoolID string `json:"pool_id"`
	Branch string `json:"branch"`
}

type EventBranchCommit

type EventBranchCommit struct {
	CommitID string `json:"commit_id"`
	PoolID   string `json:"pool_id"`
	Branch   string `json:"branch"`
	Parent   string `json:"parent"`
}

type EventPool

type EventPool struct {
	PoolID string `json:"pool_id"`
}

type IndexPostRequest

type IndexPostRequest struct {
	Keys     []string `json:"keys"`
	Name     string   `json:"name"`
	Patterns []string `json:"patterns"`
	Zed      string   `json:"zed,omitempty"`
}

type KSUID

type KSUID ksuid.KSUID

func (KSUID) MarshalText

func (k KSUID) MarshalText() ([]byte, error)

func (*KSUID) UnmarshalText

func (k *KSUID) UnmarshalText(text []byte) error

type PoolPostRequest

type PoolPostRequest struct {
	Name   string       `json:"name"`
	Layout order.Layout `json:"layout"`
	Thresh int64        `json:"thresh"`
}

type PoolPutRequest

type PoolPutRequest struct {
	Name string `json:"name"`
}

type QueryChannelEnd

type QueryChannelEnd struct {
	ChannelID int `json:"channel_id" zed:"channel_id"`
}

type QueryChannelSet

type QueryChannelSet struct {
	ChannelID int `json:"channel_id" zed:"channel_id"`
}

type QueryError

type QueryError struct {
	Error string `json:"error" zed:"error"`
}

type QueryRequest

type QueryRequest struct {
	Query string              `json:"query"`
	Head  lakeparse.Commitish `json:"head"`
}

type QueryStats

type QueryStats struct {
	StartTime  nano.Ts `json:"start_time" zed:"start_time"`
	UpdateTime nano.Ts `json:"update_time" zed:"update_time"`
	ScannerStats
}

type QueryWarning

type QueryWarning struct {
	Warning string `json:"warning" zed:"warning"`
}

type ScannerStats

type ScannerStats struct {
	BytesRead      int64 `json:"bytes_read"`
	BytesMatched   int64 `json:"bytes_matched"`
	RecordsRead    int64 `json:"records_read"`
	RecordsMatched int64 `json:"records_matched"`
}

type VersionResponse

type VersionResponse struct {
	Version string `json:"version"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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