postgres

package
v0.1.9 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2019 License: Apache-2.0, BSD-3-Clause, MIT Imports: 23 Imported by: 0

Documentation

Overview

Package postgres implements the Service Manager storage interfaces for Postgresql Repository

Index

Constants

View Source
const Storage = "postgres"

Storage defines the name of the PostgreSQL relational storage

Variables

This section is empty.

Functions

This section is empty.

Types

type Broker

type Broker struct {
	ID          string         `db:"id"`
	Name        string         `db:"name"`
	Description sql.NullString `db:"description"`
	CreatedAt   time.Time      `db:"created_at"`
	UpdatedAt   time.Time      `db:"updated_at"`
	BrokerURL   string         `db:"broker_url"`
	Username    string         `db:"username"`
	Password    string         `db:"password"`
}

Broker entity

func (*Broker) FromDTO added in v0.1.2

func (b *Broker) FromDTO(broker *types.Broker)

func (*Broker) ToDTO added in v0.1.2

func (b *Broker) ToDTO() *types.Broker

type BrokerLabel added in v0.1.8

type BrokerLabel struct {
	ID        sql.NullString `db:"id"`
	Key       sql.NullString `db:"key"`
	Val       sql.NullString `db:"val"`
	CreatedAt *time.Time     `db:"created_at"`
	UpdatedAt *time.Time     `db:"updated_at"`
	BrokerID  sql.NullString `db:"broker_id"`
}

func (*BrokerLabel) Label added in v0.1.8

func (bl *BrokerLabel) Label() (labelTableName string, referenceColumnName string, primaryColumnName string)

type Labelable added in v0.1.8

type Labelable interface {
	Label() (labelTableName string, referenceColumnName string, primaryColumnName string)
}

Labelable is an interface that entities that support can be labelled should implement

type Platform

type Platform struct {
	ID          string         `db:"id"`
	Type        string         `db:"type"`
	Name        string         `db:"name"`
	Description sql.NullString `db:"description"`
	CreatedAt   time.Time      `db:"created_at"`
	UpdatedAt   time.Time      `db:"updated_at"`
	Username    string         `db:"username"`
	Password    string         `db:"password"`
}

Platform entity

func (*Platform) FromDTO added in v0.1.2

func (p *Platform) FromDTO(platform *types.Platform)

func (*Platform) ToDTO added in v0.1.2

func (p *Platform) ToDTO() *types.Platform

type Safe

type Safe struct {
	Secret    []byte    `db:"secret"`
	CreatedAt time.Time `db:"created_at"`
	UpdatedAt time.Time `db:"updated_at"`
}

Safe represents a secret entity

type ServiceOffering added in v0.1.2

type ServiceOffering struct {
	ID          string    `db:"id"`
	Name        string    `db:"name"`
	Description string    `db:"description"`
	CreatedAt   time.Time `db:"created_at"`
	UpdatedAt   time.Time `db:"updated_at"`

	Bindable             bool   `db:"bindable"`
	InstancesRetrievable bool   `db:"instances_retrievable"`
	BindingsRetrievable  bool   `db:"bindings_retrievable"`
	PlanUpdatable        bool   `db:"plan_updateable"`
	CatalogID            string `db:"catalog_id"`
	CatalogName          string `db:"catalog_name"`

	Tags     sqlxtypes.JSONText `db:"tags"`
	Requires sqlxtypes.JSONText `db:"requires"`
	Metadata sqlxtypes.JSONText `db:"metadata"`

	BrokerID string `db:"broker_id"`
}

func (*ServiceOffering) FromDTO added in v0.1.2

func (so *ServiceOffering) FromDTO(offering *types.ServiceOffering)

func (*ServiceOffering) ToDTO added in v0.1.2

func (so *ServiceOffering) ToDTO() *types.ServiceOffering

type ServicePlan added in v0.1.2

type ServicePlan struct {
	ID          string    `db:"id"`
	Name        string    `db:"name"`
	Description string    `db:"description"`
	CreatedAt   time.Time `db:"created_at"`
	UpdatedAt   time.Time `db:"updated_at"`

	Free          bool   `db:"free"`
	Bindable      bool   `db:"bindable"`
	PlanUpdatable bool   `db:"plan_updateable"`
	CatalogID     string `db:"catalog_id"`
	CatalogName   string `db:"catalog_name"`

	Metadata sqlxtypes.JSONText `db:"metadata"`
	Schemas  sqlxtypes.JSONText `db:"schemas"`

	ServiceOfferingID string `db:"service_offering_id"`
}

func (*ServicePlan) FromDTO added in v0.1.2

func (sp *ServicePlan) FromDTO(plan *types.ServicePlan)

func (*ServicePlan) ToDTO added in v0.1.2

func (sp *ServicePlan) ToDTO() *types.ServicePlan

type Visibility added in v0.1.6

type Visibility struct {
	ID            string         `db:"id"`
	PlatformID    sql.NullString `db:"platform_id"`
	ServicePlanID string         `db:"service_plan_id"`
	CreatedAt     time.Time      `db:"created_at"`
	UpdatedAt     time.Time      `db:"updated_at"`
}

func (*Visibility) FromDTO added in v0.1.6

func (v *Visibility) FromDTO(visibility *types.Visibility)

func (*Visibility) ToDTO added in v0.1.6

func (v *Visibility) ToDTO() *types.Visibility

type VisibilityLabel added in v0.1.8

type VisibilityLabel struct {
	ID                  sql.NullString `db:"id"`
	Key                 sql.NullString `db:"key"`
	Val                 sql.NullString `db:"val"`
	CreatedAt           *time.Time     `db:"created_at"`
	UpdatedAt           *time.Time     `db:"updated_at"`
	ServiceVisibilityID sql.NullString `db:"visibility_id"`
}

func (*VisibilityLabel) Label added in v0.1.8

func (vl *VisibilityLabel) Label() (labelTableName string, referenceColumnName string, primaryColumnName string)

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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