server

package
v0.0.0-...-0b7b167 Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2019 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewKustomizeSearch

func NewKustomizeSearch(ctx context.Context) (*kustomizeSearch, error)

New server. Creating a server does not launch it. To launch simply:

srv, _ := NewKustomizeSearch(context.Backgroud())
err := srv.Serve()
if err != nil {
	// Handle server issues.
}

The server has three enpoints, two of which are functional:

/search: processes the ?q= parameter for a text query and returns a list of 10 resutls starting from the ?from= value provided, with the default being zero.

/metrics: returns overall metrics about the files indexed. Returns timeseries data for kustomization files, and returns breakdown of file counts by their 'kind' fields

/register: not implemented, but meant as an endpoint for adding new kustomization files to the corpus.

Types

This section is empty.

Jump to

Keyboard shortcuts

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