server

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2018 License: AGPL-3.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Analyzers []lookout.AnalyzerConfig
}

Config is a server configuration

type LogPoster added in v0.1.4

type LogPoster struct {
	Log log.Logger
}

func (*LogPoster) Post added in v0.1.4

func (p *LogPoster) Post(ctx context.Context, e lookout.Event,
	aCommentsList []lookout.AnalyzerComments) error

func (*LogPoster) Status added in v0.1.4

func (p *LogPoster) Status(ctx context.Context, e lookout.Event,
	status lookout.AnalysisStatus) error

type Server

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

Server implements glue between providers / data-server / analyzers

func NewServer

func NewServer(w lookout.Watcher, p lookout.Poster, fileGetter lookout.FileGetter,
	analyzers map[string]lookout.Analyzer, eventOp store.EventOperator, commentOp store.CommentOperator) *Server

NewServer creates new Server

func (*Server) HandlePush

func (s *Server) HandlePush(ctx context.Context, e *lookout.PushEvent) error

HandlePush sends request to analyzers concurrently

func (*Server) HandleReview

func (s *Server) HandleReview(ctx context.Context, e *lookout.ReviewEvent) error

HandleReview sends request to analyzers concurrently

func (*Server) Run

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

Run starts server

Jump to

Keyboard shortcuts

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