data

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: May 2, 2025 License: Apache-2.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadAllCallOperands added in v0.2.0

func LoadAllCallOperands(dsConfs map[string]*configs.Datastore, callOperandsDir *string) (map[string]map[string]func(args ...string) (string, error), error)

LoadAllCallOperands will try loading the call operands from the configured directory. If directory was not configured or and error while parsing occurred, the default call operands will be used.

func MakeDatastores

func MakeDatastores(config *configs.ExternalConfig, dsLoggingWriter io.Writer, loggingMode bool) map[string]*data.Datastore

MakeDatastores instantiates a new datastores instances based on the provided configuration. If loggingMode is enabled, a logging variant will be created

func NewDatastore added in v0.2.0

func NewDatastore(translator data.DatastoreTranslator, executor data.DatastoreExecutor) data.Datastore

func NewLoggingDatastoreExecutor added in v0.2.0

func NewLoggingDatastoreExecutor(writer io.Writer) data.DatastoreExecutor

NewLoggingDatastoreExecutor instantiates a new DatastoreExecutor, which logs the queries instead of executing it against a database.

func NewMongoDatastoreExecuter

func NewMongoDatastoreExecuter() data.DatastoreExecutor

func NewMongoDatastoreTranslator added in v0.2.0

func NewMongoDatastoreTranslator() data.DatastoreTranslator

NewMongoDatastoreTranslator Returns a new data.DatastoreTranslator which is able to connect to MongoDB databases.

func NewSQLDatastoreExecutor

func NewSQLDatastoreExecutor() data.DatastoreExecutor

NewSQLDatastoreExecutor instantiates a new DatastoreExecutor, which can be used for MySQL and PostgreSQL queries.

func NewSQLDatastoreTranslator added in v0.2.0

func NewSQLDatastoreTranslator() data.DatastoreTranslator

NewSQLDatastoreTranslator returns a new data.DatastoreTranslator which is able to connect to PostgreSQL and MySQL databases.

Types

type GenericCallOpMapper

type GenericCallOpMapper struct {
	// contains filtered or unexported fields
}

func (GenericCallOpMapper) Handles

func (h GenericCallOpMapper) Handles() string

func (GenericCallOpMapper) Map

func (h GenericCallOpMapper) Map(args ...string) (string, error)

Jump to

Keyboard shortcuts

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