Documentation ¶
Overview ¶
Package datamanager contains a gRPC based datamanager service server
Package datamanager contains a service type that can be used to capture data from a robot's components.
Package datamanager contains a gRPC based datamanager service server
Index ¶
Constants ¶
const SubtypeName = "data_manager"
SubtypeName is the name of the type of service.
Variables ¶
var API = resource.APINamespaceRDK.WithServiceType(SubtypeName)
API is a variable that identifies the data manager service resource API.
var ShouldSyncKey = "should_sync"
ShouldSyncKey is a special key we use within a modular sensor to pass a boolean that indicates to the datamanager whether or not we want to sync.
Functions ¶
func CreateShouldSyncReading ¶ added in v0.13.0
CreateShouldSyncReading is a helper for creating the expected reading for a modular sensor that passes a bool to the datamanager to indicate whether or not we want to sync.
func NewRPCServiceServer ¶ added in v0.2.36
func NewRPCServiceServer(coll resource.APIResourceCollection[Service]) interface{}
NewRPCServiceServer constructs a datamanager gRPC service server. It is intentionally untyped to prevent use outside of tests.
Types ¶
type DataCaptureConfig ¶ added in v0.2.36
type DataCaptureConfig struct { Resource resource.Resource `json:"-"` Name resource.Name `json:"name"` Method string `json:"method"` CaptureFrequencyHz float32 `json:"capture_frequency_hz"` CaptureQueueSize int `json:"capture_queue_size"` CaptureBufferSize int `json:"capture_buffer_size"` AdditionalParams map[string]string `json:"additional_params"` Disabled bool `json:"disabled"` Tags []string `json:"tags,omitempty"` CaptureDirectory string `json:"capture_directory"` }
DataCaptureConfig is used to initialize a collector for a component or remote.
func (*DataCaptureConfig) Equals ¶ added in v0.2.36
func (c *DataCaptureConfig) Equals(other *DataCaptureConfig) bool
Equals checks if one capture config is equal to another.
type DataCaptureConfigs ¶ added in v0.2.36
type DataCaptureConfigs struct {
CaptureMethods []DataCaptureConfig `json:"capture_methods"`
}
DataCaptureConfigs specify a list of methods to capture on resources.
func (*DataCaptureConfigs) UpdateResourceNames ¶ added in v0.2.36
func (dcs *DataCaptureConfigs) UpdateResourceNames(updater func(old resource.Name) resource.Name)
UpdateResourceNames allows the caller to modify the resource names of data capture in place.
type Service ¶
type Service interface { resource.Resource Sync(ctx context.Context, extra map[string]interface{}) error }
Service defines what a Data Manager Service should expose to the users.
func FromDependencies ¶ added in v0.12.0
func FromDependencies(deps resource.Dependencies, name string) (Service, error)
FromDependencies is a helper for getting the named data manager service from a collection of dependencies.
Directories ¶
Path | Synopsis |
---|---|
Package builtin contains a service type that can be used to capture data from a robot's components.
|
Package builtin contains a service type that can be used to capture data from a robot's components. |
Package datacapture contains tools for interacting with Viam datacapture files.
|
Package datacapture contains tools for interacting with Viam datacapture files. |
Package datasync contains interfaces for syncing data from robots to the app.viam.com cloud.
|
Package datasync contains interfaces for syncing data from robots to the app.viam.com cloud. |
Package internal implements a data manager service definition with additional exported functions for the purpose of testing
|
Package internal implements a data manager service definition with additional exported functions for the purpose of testing |
Package register registers all relevant datamanager models and also API specific functions
|
Package register registers all relevant datamanager models and also API specific functions |