Documentation ¶
Index ¶
- type ApplicationDescriber
- type HomeDescriber
- type HomeDescriberOption
- type Module
- func (m Module) AddCRD(ctx context.Context, crd *unstructured.Unstructured) error
- func (m Module) ClientRequestHandlers() []octant.ClientRequestHandler
- func (m *Module) Content(ctx context.Context, contentPath string, opts module.ContentOptions) (component.ContentResponse, error)
- func (m *Module) ContentPath() string
- func (m Module) Description() string
- func (m Module) Generators() []octant.Generator
- func (m Module) GroupVersionKindPath(namespace, apiVersion, kind, name string) (string, error)
- func (m Module) GvkFromPath(contentPath, namespace string) (schema.GroupVersionKind, error)
- func (m Module) Name() string
- func (m *Module) Navigation(ctx context.Context, namespace, root string) ([]navigation.Navigation, error)
- func (m Module) RemoveCRD(ctx context.Context, crd *unstructured.Unstructured) error
- func (m Module) ResetCRDs(ctx context.Context) error
- func (m Module) SetContext(ctx context.Context, contextName string) error
- func (m Module) SetNamespace(namespace string) error
- func (m Module) Start() error
- func (m Module) Stop()
- func (m Module) SupportedGroupVersionKind() []schema.GroupVersionKind
- type Options
- type Summarizer
- type SummarizerConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ApplicationDescriber ¶
type ApplicationDescriber struct {
// contains filtered or unexported fields
}
ApplicationDescriber describes an application.
func NewApplicationDescriber ¶
func NewApplicationDescriber(dashConfig config.Dash) *ApplicationDescriber
NewApplicationDescriber creates an instance of ApplicationDescriber.
func (*ApplicationDescriber) Describe ¶
func (a *ApplicationDescriber) Describe(ctx context.Context, namespace string, options describer.Options) (component.ContentResponse, error)
Describe creates an application content response. It includes a list overview and a resource viewer for all the objects in an application.
func (*ApplicationDescriber) PathFilters ¶
func (a *ApplicationDescriber) PathFilters() []describer.PathFilter
PathFilters creates PathFilters for an application. The path for an application is /app-name/app-instance/app-version.
type HomeDescriber ¶
type HomeDescriber struct {
// contains filtered or unexported fields
}
HomeDescriber describes content for applications.
func NewHomeDescriber ¶
func NewHomeDescriber(options ...HomeDescriberOption) *HomeDescriber
NewHomeDescriber creates an instance of HomeDescriber.
func (*HomeDescriber) Describe ¶
func (l *HomeDescriber) Describe(ctx context.Context, namespace string, options describer.Options) (component.ContentResponse, error)
Describe prints a summary of applications.
func (*HomeDescriber) PathFilters ¶
func (l *HomeDescriber) PathFilters() []describer.PathFilter
PathFilters returns PathFilters for this describer. It is the root of a the module.
type HomeDescriberOption ¶
type HomeDescriberOption func(d *HomeDescriber)
HomeDescriberOption is an option for configuring HomeDescriber.
func WithHomeDescriberSummarizer ¶
func WithHomeDescriberSummarizer(s Summarizer) HomeDescriberOption
WithHomeDescriberSummarizer configures the Summarizer for HomeDescriber.
type Module ¶
type Module struct { Options // contains filtered or unexported fields }
Module is an applications module.
func (Module) AddCRD ¶
func (m Module) AddCRD(ctx context.Context, crd *unstructured.Unstructured) error
AddCRD does nothing.
func (Module) ClientRequestHandlers ¶
func (m Module) ClientRequestHandlers() []octant.ClientRequestHandler
ClientRequestHandlers are client handlers for the module.
func (*Module) Content ¶
func (m *Module) Content(ctx context.Context, contentPath string, opts module.ContentOptions) (component.ContentResponse, error)
Content generates content for a content path.
func (*Module) ContentPath ¶
ContentPath returns the root content path for the module.
func (Module) Description ¶ added in v0.17.0
Description is the description of the module.
func (Module) GroupVersionKindPath ¶
GroupVersionKindPath does nothing.
func (Module) GvkFromPath ¶ added in v0.17.0
func (m Module) GvkFromPath(contentPath, namespace string) (schema.GroupVersionKind, error)
func (*Module) Navigation ¶
func (m *Module) Navigation(ctx context.Context, namespace, root string) ([]navigation.Navigation, error)
Navigation generates navigation entries for the module.
func (Module) RemoveCRD ¶
func (m Module) RemoveCRD(ctx context.Context, crd *unstructured.Unstructured) error
RemoveCRD does nothing.
func (Module) SetContext ¶
SetContext does nothing.
func (Module) SetNamespace ¶
SetNamespace sets the module's namespace.
func (Module) SupportedGroupVersionKind ¶
func (m Module) SupportedGroupVersionKind() []schema.GroupVersionKind
SupportedGroupVersionKind does nothing.
type Summarizer ¶
type Summarizer interface { // Summarize generates a table summary. Summarize(ctx context.Context, namespace string, config SummarizerConfig) (*component.Table, error) }
Summarizer summarizes applications for a namespace. Applications are a group of objects labeled with matching application labels. Application labels are:
- app.kubernetes.io/name
- app.kubernetes.io/instance
- app.kubernetes.io/version
type SummarizerConfig ¶
SummarizerConfig is configuration for Summarize.