handler

package
v0.0.0-...-ba7165a Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2020 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package handler provides request handler implementations.

Index

Constants

View Source
const ResultBufferSize = 1000

ResultBufferSize sets the amount of objects in the result buffer.

Variables

View Source
var (
	// ErrUnknownBrowser indicates an error when an unknown browser type is given.
	ErrUnknownBrowser = status.Error(codes.InvalidArgument, "unknown browser type in request")
)

Functions

This section is empty.

Types

type Worker

type Worker struct{}

Worker implements the gRPC worker service handler.

func NewWorker

func NewWorker() *Worker

NewWorker returns a new Worker.

func (*Worker) Ping

func (w *Worker) Ping(ctx context.Context, req *api.PingRequest) (*api.PingResponse, error)

Ping responds with a PingResponse message to incoming ping requests.

func (*Worker) Run

func (w *Worker) Run(req *api.RunRequest, srv api.Worker_RunServer) error

Run handles incoming run requests. It starts a new loadtest and sends the response results of the runners as single messages via gRPC stream. Closing the gRPC channel stops the load test and shuts all runners down.

Jump to

Keyboard shortcuts

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