server

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2023 License: Apache-2.0 Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DoWithContext

func DoWithContext(ctx context.Context, f func() error) error

DoWithContext runs f and returns its error. If the context is cancelled or times out first, it returns the context's error instead.

func DoWithTimeout

func DoWithTimeout(f func() error, d time.Duration) error

DoWithTimeout runs f and returns its error. If the deadline d elapses first, it returns a grpc DeadlineExceeded error instead.

Types

type ApiServer

type ApiServer struct {
	browsercontrollerV1.UnimplementedBrowserControllerServer
	// contains filtered or unexported fields
}

ApiServer is the gRPC api endpoint for the Browser Controller

func NewApiServer

func NewApiServer(listenInterface string, listenPort int, sessions *session.Registry, robotsEvaluator robotsevaluator.RobotsEvaluator, logWriter logwriter.LogWriter) *ApiServer

NewApiServer returns a new instance of ApiServer listening on the given port

func (*ApiServer) Close

func (a *ApiServer) Close()

func (*ApiServer) Do

Implements BrowserController

func (*ApiServer) Start

func (a *ApiServer) Start() error

Jump to

Keyboard shortcuts

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