consoleserver

package
v0.0.0-...-b0621e5 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2025 License: BSD-3-Clause Imports: 30 Imported by: 0

Documentation

Overview

Package consoleserver is the implementation of the backend of the console UI.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InstallServices

func InstallServices(consoleFrontend fleetconsolerpc.FleetConsoleServer, srv grpc.ServiceRegistrar)

InstallServices installs services into the server.

func MustSetDBConnection

func MustSetDBConnection(ctx context.Context, consoleFrontend *FleetConsoleFrontend)

MustSetDBConnection sets the db connection and panics if it can't retrieve the secret or connect to the database.

func NewFleetConsoleFrontend

func NewFleetConsoleFrontend() fleetconsolerpc.FleetConsoleServer

NewFleetConsoleFrontend creates a new fleet console frontend.

func SetCloudProject

func SetCloudProject(consoleFrontend *FleetConsoleFrontend, cloudProject string)

SetCloudProject sets the cloud project

func SetDeviceManagerClient

func SetDeviceManagerClient(consoleFrontend *FleetConsoleFrontend, deviceManagerClient func(context.Context, string) (*devicemanagerclient.Client, error))

SetDeviceManagerClient sets the device manager client.

func SetUFSClient

func SetUFSClient(consoleFrontend *FleetConsoleFrontend, ufsClient func(context.Context, string) (ufsclient.Client, error))

SetUFSClient sets the UFS client.

Types

type FleetConsoleFrontend

type FleetConsoleFrontend struct {
	fleetconsolerpc.UnimplementedFleetConsoleServer
	// contains filtered or unexported fields
}

FleetConsoleFrontend is the fleet console frontend.

func (*FleetConsoleFrontend) CleanExit

CleanExit exits the current process.

func (*FleetConsoleFrontend) CountDevices

func (*FleetConsoleFrontend) GetDeviceDimensions

func (frontend *FleetConsoleFrontend) GetDeviceDimensions(ctx context.Context, req *emptypb.Empty) (_ *fleetconsolerpc.GetDeviceDimensionsResponse, err error)

GetDeviceDimensions returns dimensions of all devices

func (*FleetConsoleFrontend) ListDevices

ListDevices lists devices from the db.

func (*FleetConsoleFrontend) ListResourceRequests

ListResourceRequests lists resource requests.

func (*FleetConsoleFrontend) Ping

Ping is the ping RPC. It responds with an empty response and never fails.

func (*FleetConsoleFrontend) PingBigQuery

PingBigQuery pings the mock BQ database with a random query and logs the results.

func (*FleetConsoleFrontend) PingDB

PingDB pings the database.

func (*FleetConsoleFrontend) PingDeviceManager

PingDeviceManager pings device manager.

func (*FleetConsoleFrontend) PingUfs

PingUfs pings UFS.

func (*FleetConsoleFrontend) RepopulateCache

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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