admin

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2022 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IndexHandler

func IndexHandler(w http.ResponseWriter, r *http.Request)

func LoadHandlers

func LoadHandlers(orchestratorUrl string, client Client) func(router *mux.Router)

func NewApplicationsHandler

func NewApplicationsHandler(orchestratorUrl string, client Client) applicationsHandler

func NewIntegrationsHandler

func NewIntegrationsHandler(orchestratorUrl string, client Client) integrationsHandler

func NewStatusHandler

func NewStatusHandler(orchestratorUrl string, client Client) statusHandler

Types

type Application

type Application struct {
	ID            string
	IntegrationId string
	ObjectId      string
	Name          string
	Description   string
}

type Client

type Client interface {
	Health(url string) (string, error)
	Applications(url string) ([]Application, error)
	Application(url string) (Application, error)
	Integrations(url string) ([]Integration, error)
	CreateIntegration(url string, provider string, key []byte) error
	DeleteIntegration(url string) error
}

func NewOrchestratorClient

func NewOrchestratorClient(client HTTPClient, key string) Client

type HTTPClient

type HTTPClient interface {
	Get(url string) (resp *http.Response, err error)
	Do(req *http.Request) (*http.Response, error)
}

type Integration

type Integration struct {
	ID       string
	Name     string
	Provider string
	Key      []byte
}

type Status

type Status struct {
	URL    string
	Status string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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