server

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2024 License: Apache-2.0 Imports: 8 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(
	stop <-chan struct{},
) api_adapter_v1.AdapterServer

New returns an AdapterServer that wraps the given high-level Adapter implementation with the Tokens field populated from the file which name is configured in the AUTH_TOKENS_PATH environment variable. The stop channel is used to signal when the file watcher should be closed and stop watching for file changes.

func RegisterAdapter added in v0.7.1

func RegisterAdapter[Config any](s api_adapter_v1.AdapterServer, datasourceType string, adapter framework.Adapter[Config]) error

RegisterAdapter registers a new high-level Adapter implementation with the server. The Config type parameter is the type of the config object that will be passed to the high-level Adapter implementation.

If this function is called with the datasource type of an already-registered Adapter, it will return an error.

Types

type Server added in v0.7.2

type Server = internal.Server

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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