server

package
v0.0.0-...-f057ec1 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2021 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler struct {
	// contains filtered or unexported fields
}

func NewHandler

func NewHandler(r ReindexCtl) *Handler

func (*Handler) Reindex

func (r *Handler) Reindex(c *gin.Context)

type HealthzOK

type HealthzOK struct {
	Msg string `json:"msg"`
}

type Index

type Index struct {
	Index string `json:"index"`
}

type ReindexCtl

type ReindexCtl interface {
	PublishReindexTask(ctx context.Context, src, dest string) (string, error)
}

type ReindexErr

type ReindexErr struct {
	Msg string `json:"msg"`
}

type ReindexOK

type ReindexOK struct {
	ID string `json:"id"`
}

type ReindexReq

type ReindexReq struct {
	Source Index `json:"source"`
	Dest   Index `json:"dest"`
}

type Server

type Server struct {
	// contains filtered or unexported fields
}

func New

func New(port string, ctl ReindexCtl) *Server

func (*Server) Run

func (s *Server) Run(ctx context.Context) error

Jump to

Keyboard shortcuts

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