rainbond: github.com/goodrain/rainbond/gateway/store Index | Files

package store

import "github.com/goodrain/rainbond/gateway/store"

Index

Package Files

informer.go ingress_annotation.go local_secret.go secret_ingress_map.go store.go

type Event Uses

type Event struct {
    Type EventType
    Obj  interface{}
}

Event holds the context of an event.

type EventType Uses

type EventType string

EventType -

const (
    // CreateEvent event associated with new objects in an informer
    CreateEvent EventType = "CREATE"
    // UpdateEvent event associated with an object update in an informer
    UpdateEvent EventType = "UPDATE"
    // DeleteEvent event associated when an object is removed from an informer
    DeleteEvent EventType = "DELETE"
    // CertificatePath is the default path of certificate file
    CertificatePath = "/run/nginx/conf/certificate"
    // DefVirSrvName is the default virtual service name
    DefVirSrvName = "_"
)

type Informer Uses

type Informer struct {
    Ingress  cache.SharedIndexInformer
    Service  cache.SharedIndexInformer
    Endpoint cache.SharedIndexInformer
    Secret   cache.SharedIndexInformer
}

Informer defines the required SharedIndexInformers that interact with the API server.

func (*Informer) Run Uses

func (i *Informer) Run(stopCh chan struct{})

Run initiates the synchronization of the informers against the API server.

type IngressAnnotationsLister Uses

type IngressAnnotationsLister struct {
    cache.Store
}

IngressAnnotationsLister makes a Store that lists annotations in Ingress rules.

func (IngressAnnotationsLister) ByKey Uses

func (il IngressAnnotationsLister) ByKey(key string) (*annotations.Ingress, error)

ByKey returns the Ingress annotations matching key in the local Ingress annotations Store.

type Lister Uses

type Lister struct {
    Ingress           istroe.IngressLister
    Service           istroe.ServiceLister
    Endpoint          istroe.EndpointLister
    Secret            istroe.SecretLister
    IngressAnnotation IngressAnnotationsLister
}

Lister contains object listers (stores).

type SSLCertTracker Uses

type SSLCertTracker struct {
    cache.ThreadSafeStore
}

SSLCertTracker holds a store of referenced Secrets in Ingress rules

func NewSSLCertTracker Uses

func NewSSLCertTracker() *SSLCertTracker

NewSSLCertTracker creates a new SSLCertTracker store

func (SSLCertTracker) ByKey Uses

func (s SSLCertTracker) ByKey(key string) (*v1.SSLCert, error)

ByKey searches for an ingress in the local ingress Store

type Storer Uses

type Storer interface {
    // list endpoints pool
    ListPool() ([]*v1.Pool, []*v1.Pool)

    // list virtual service
    ListVirtualService() ([]*v1.VirtualService, []*v1.VirtualService)

    ListIngresses() []*extensions.Ingress

    GetIngressAnnotations(key string) (*annotations.Ingress, error)

    // Run initiates the synchronization of the controllers
    Run(stopCh chan struct{})

    // GetDefaultBackend returns the default backend configuration
    GetDefaultBackend() defaults.Backend
}

Storer is the interface that wraps the required methods to gather information

func New Uses

func New(client kubernetes.Interface,
    updateCh *channels.RingChannel,
    conf *option.Config) Storer

New creates a new Storer

Package store imports 29 packages (graph) and is imported by 1 packages. Updated 2019-05-12. Refresh now. Tools for package owners.