Skip to main content

@terascope/types / terafoundation

terafoundation

Index

Interfaces

InterfaceDescription
ConnectionConfig-
Connector-
ConnectorOutput-
FoundationAPIs-
FoundationWorker-
PromMetrics-
PromMetricsAPIConfig-
PromMetricsInitConfig-
TerafoundationConfig-

Type Aliases

Cluster

Cluster: Overwrite<NodeJSCluster, object>

Source

terafoundation.ts:119


Config<S, A, D>

Config<S, A, D>: object

Type parameters

Type parameterValue
SRecord<string, any>
ARecord<string, any>
D extends stringstring

Type declaration

cluster_name?

optional cluster_name: string | (sysconfig) => string

config_schema?

optional config_schema: any

default_config_file?

optional default_config_file: string

descriptors?

optional descriptors: Record<D, string>

master()?

optional master: (context, config) => void | Promise<void>

Parameters
ParameterType
contextContext<S, A, D>
configConfig<S, A, D>
Returns

void | Promise<void>

name

name: string

schema_formats?

optional schema_formats: Format[]

script()?

optional script: (context) => void | Promise<void>

Parameters
ParameterType
contextContext<S, A, D>
Returns

void | Promise<void>

shutdownMessaging?

optional shutdownMessaging: boolean

start_workers?

optional start_workers: boolean

worker()?

optional worker: (context) => void | Promise<void>

Parameters
ParameterType
contextContext<S, A, D>
Returns

void | Promise<void>

Source

terafoundation.ts:50


Context<S, A, D>

Context<S, A, D>: object

Type parameters

Type parameterValue
SRecord<string, any>
ARecord<string, any>
D extends stringstring

Type declaration

apis

apis: ContextAPIs & A

arch

arch: string

assignment

assignment: D

cluster

cluster: Cluster

cluster_name?

optional cluster_name: string

logger

logger: Logger

name

name: string

platform

platform: string

sysconfig

sysconfig: SysConfig<S>

Source

terafoundation.ts:144


ContextAPIs

ContextAPIs: object

Index signature

[namespace: string]: any

Type declaration

foundation

readonly foundation: FoundationAPIs

registerAPI()
Parameters
ParameterType
namespacestring
apisany
Returns

void

Source

terafoundation.ts:101


CreateClientFactoryFn()

CreateClientFactoryFn: (config, logger, options) => Promise<ConnectorOutput>

Parameters

ParameterType
configRecord<string, any>
loggerLogger
optionsConnectionConfig

Returns

Promise<ConnectorOutput>

Source

terafoundation.ts:84


Initializers<S>

Initializers<S>: object

Type parameters

Type parameterValue
SRecord<string, any>

Type declaration

schema

schema: Schema<S>

validatorFn?

optional validatorFn: ValidatorFn<S>

Source

terafoundation.ts:34


LogLevelConfig

LogLevelConfig: string | { [type in LogType]: LogLevelType }[]

Source

terafoundation.ts:109


LogLevelType

LogLevelType: "trace" | "debug" | "info" | "warn" | "error" | "fatal"

Source

terafoundation.ts:108


LogType

LogType: "console" | "file"

Source

terafoundation.ts:107


MetricList

MetricList: Record<string, object>

Source

terafoundation.ts:215


Schema<T>

Schema<T>: { [P in keyof T]: Schema<T[P]> | SchemaObj<T[P]> }

Type parameters

Type parameter
T

Source

terafoundation.ts:30


SysConfig<S>

SysConfig<S>: object & S

Type declaration

_nodeName

_nodeName: string

terafoundation

terafoundation: TerafoundationConfig

Type parameters

Type parameter
S

Source

terafoundation.ts:139


ValidationObj<S>

ValidationObj<S>: object

Type parameters

Type parameter
S

Type declaration

config

config: Record<string, any>

connector?

optional connector: boolean

validatorFn?

optional validatorFn: ValidatorFn<S>

Source

terafoundation.ts:39


ValidatorFn()<S>

ValidatorFn<S>: (config, sysconfig) => void

Type parameters

Type parameterValue
SRecord<string, any>

Parameters

ParameterType
configRecord<string, any>
sysconfigSysConfig<S>

Returns

void

Source

terafoundation.ts:45