database

package
Version: v0.0.0-...-54afde0 Latest Latest
Warning

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

Go to latest
Published: Mar 31, 2020 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AsyncOperations

AsyncOperations is the database interface for AsyncOperationDocuments

func NewAsyncOperations

func NewAsyncOperations(uuid string, dbc cosmosdb.DatabaseClient, dbid, collid string) (AsyncOperations, error)

NewAsyncOperations returns a new AsyncOperations

type Billing

Billing is the database interface for BillingDocuments

func NewBilling

func NewBilling(ctx context.Context, uuid string, dbc cosmosdb.DatabaseClient, dbid, collid string) (Billing, error)

NewBilling returns a new Billing

type Database

type Database struct {
	AsyncOperations   AsyncOperations
	Billing           Billing
	Monitors          Monitors
	OpenShiftClusters OpenShiftClusters
	Subscriptions     Subscriptions
	// contains filtered or unexported fields
}

Database represents a database

func NewDatabase

func NewDatabase(ctx context.Context, log *logrus.Entry, env env.Interface, m metrics.Interface, cipher encryption.Cipher, uuid string) (db *Database, err error)

NewDatabase returns a new Database

type Monitors

type Monitors interface {
	Create(context.Context, *api.MonitorDocument) (*api.MonitorDocument, error)
	PatchWithLease(context.Context, string, func(*api.MonitorDocument) error) (*api.MonitorDocument, error)
	TryLease(context.Context) (*api.MonitorDocument, error)
	ListBuckets(context.Context) ([]int, error)
	ListMonitors(context.Context) (*api.MonitorDocuments, error)
	MonitorHeartbeat(context.Context) error
}

Monitors is the database interface for MonitorDocuments

func NewMonitors

func NewMonitors(ctx context.Context, uuid string, dbc cosmosdb.DatabaseClient, dbid, collid string) (Monitors, error)

NewMonitors returns a new Monitors

type OpenShiftClusters

OpenShiftClusters is the database interface for OpenShiftClusterDocuments

func NewOpenShiftClusters

func NewOpenShiftClusters(ctx context.Context, uuid string, dbc cosmosdb.DatabaseClient, dbid, collid string) (OpenShiftClusters, error)

NewOpenShiftClusters returns a new OpenShiftClusters

type Subscriptions

Subscriptions is the database interface for SubscriptionDocuments

func NewSubscriptions

func NewSubscriptions(ctx context.Context, uuid string, dbc cosmosdb.DatabaseClient, dbid, collid string) (Subscriptions, error)

NewSubscriptions returns a new Subscriptions

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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