Documentation ¶
Index ¶
- Constants
- func ActiveSessions(db *sql.DB) ([]map[string]interface{}, error)
- func CompareLastModified(dfStatMapA map[string]interface{}, dfStatMapB map[string]interface{}) bool
- func DecryptSecretConfig(sourceDatabaseConfigs map[string]interface{}, config map[string]interface{}) string
- func FindIndexForService(project string, service string) (string, []string, string, error)
- func GetDFSPathName() (string, string)
- func GetDatabaseName() string
- func GetFolderPrefix(custom []string) string
- func GetLocalHost() string
- func GetMachineID() string
- func GetRegion(hostName string) string
- func GetSupportedDomains(prod bool) []string
- func GetSupportedEndpoints(prod bool) [][]string
- func GetSupportedTemplates(custom []string) []string
- func GetSyncedTables() []string
- func GetUserCodeField() string
- func GetUserNameField() string
- func GetVaultHost() string
- func GetVaultHostPort() string
- func GetVaultInstallRoot() string
- func InitPluginConfig(pluginEnvConfig map[string]interface{}) map[string]interface{}
- func IsLocalEndpoint(addr string) bool
- func IsTestRunner() bool
- func NewOptionsBuilder(opts ...Option)
- func PreviousStateCheck(currentState int) int
- type Option
- type OptionsBuilder
Constants ¶
const RFC_ISO_8601 = "2006-01-02 15:04:05 -0700 MST"
Variables ¶
This section is empty.
Functions ¶
func ActiveSessions ¶
Override to provide a map of active sessions by querying the provided database connection. Used to provide active sessions in the web interface -- not maintained..
func CompareLastModified ¶ added in v1.0.1
Compares the lastModified field in the provided data flow statistics maps. It returns true if the lastModified fields are equal. False otherwise. Override to provide alternate fields to match on in your flows for comparing lastModified or even other fields...
func DecryptSecretConfig ¶
func DecryptSecretConfig(sourceDatabaseConfigs map[string]interface{}, config map[string]interface{}) string
DecryptSecretConfig
- provides the secret to be used in obtaining a database connection when provided with source database configuration attributes. The config map contains additional global attributes that can be utilized in decrypting an encrypted password found within the source database configuration.
returns: the decrypted password to be used in establishing a database connection.
func FindIndexForService ¶
FindIndexForService - override to provide a custom index for a given service. This should return the name of the column that is to be treated as the index for the table. TODO: This function is miss-named. It should be called FindInexForTable where project = databaseName and service = tableName.
func GetDFSPathName ¶ added in v1.0.1
Utlized to provide Data Flow Statistics components: database name in which the DFS resides and the index of the DataFlowStatistics table (argosId)
func GetDatabaseName ¶ added in v1.0.1
func GetDatabaseName() string
GetDatabaseName - returns a name to be used by TrcDb.
func GetFolderPrefix ¶
Folder prefix for _seed and _templates. This function takes a list of paths and looking at the first entry, retrieve an embedded folder prefix.
func GetLocalHost ¶
func GetLocalHost() string
GetLocalHost - return the local host name. Override this function to provide a custom local host name.
func GetMachineID ¶ added in v1.18.2
func GetMachineID() string
func GetRegion ¶
GetRegion - return the region. Override this function to provide default region given a host name.
func GetSupportedDomains ¶ added in v1.5.3
GetSupportedDomains - return a list of supported domains. Override this function to provide a list of supported domains.
func GetSupportedEndpoints ¶
GetSupportedEndpoints - return a list of supported endpoints. Override this function to provide a list of supported endpoints.
func GetSupportedTemplates ¶
GetSupportedTemplates - override to provide a list of supported certificate templates. This function serves as a gateway so that unintentional certificates or files are not picked up and inadvertently seeded into vault. example return value:
return []string{ folderPrefix + "_templates/Common/my.cer.mf.tmpl", folderPrefix + "_templates/Common/my.pem.mf.tmpl", }
func GetSyncedTables ¶
func GetSyncedTables() []string
GetSyncedTables - return a list of synced tables from a remote source in TrcDb. Override this function to provide a list of synced tables.
func GetUserCodeField ¶
func GetUserCodeField() string
GetUserCodeField - return the user code field. Override this function to provide a custom user code field. Used to provide active sessions in the web interface -- not maintained..
func GetUserNameField ¶
func GetUserNameField() string
GetUserNameField - return the user name field. Override this function to provide a custom user name field. Used to provide active sessions in the web interface -- not maintained..
func GetVaultHost ¶
func GetVaultHost() string
GetVaultHost - return the vault host. Override this function to provide a custom vault host.
func GetVaultHostPort ¶
func GetVaultHostPort() string
GetVaultHost - return the vault host and port. Override this function to provide a custom vault host and port.
func GetVaultInstallRoot ¶ added in v1.10.4
func GetVaultInstallRoot() string
func InitPluginConfig ¶ added in v1.20.0
Utilized by trcsh curator to indicate the following map attributes:
exitOnFailure - if true, the plugin will exit on failure regions - a list of regions to be supported by the carrier pluginNameList - a list of plugins to be supported by the carrier the carrier is responsible for keeping the indicated plugins up to date and deployed with certified code... example values: trcsh, trc-vault-plugin templatePath - a list of template paths (presently 1 template) to the certification template utilized by plugins. This template references the published template originating from the source: installation/trcdb/trc_templates/TrcVault/Certify/config.yml.tmpl logNamespace - a log namespace to be used by the carrier in logging.
func IsLocalEndpoint ¶ added in v1.7.9
Determines if running tierceron in the default local development mode with the default test host.
func IsTestRunner ¶
func IsTestRunner() bool
func NewOptionsBuilder ¶ added in v1.0.1
func NewOptionsBuilder(opts ...Option)
func PreviousStateCheck ¶ added in v1.0.1
PreviousStateCheck - provides the previous state of a flow given the provided current state. All states for flows rotate in a 0-3 cycle.
Types ¶
type Option ¶ added in v1.0.1
type Option func(*OptionsBuilder)
func LoadOptions ¶ added in v1.0.1
func LoadOptions() Option
type OptionsBuilder ¶ added in v1.0.1
type OptionsBuilder struct { GetFolderPrefix func(custom []string) string GetSupportedTemplates func(custom []string) []string GetVaultInstallRoot func() string IsLocalEndpoint func(addr string) bool GetSupportedDomains func(bool) []string GetSupportedEndpoints func(bool) [][]string GetLocalHost func() string GetRegion func(hostName string) string GetVaultHost func() string GetVaultHostPort func() string GetUserNameField func() string GetUserCodeField func() string ActiveSessions func(db *sql.DB) ([]map[string]interface{}, error) GetSyncedTables func() []string FindIndexForService func(project string, service string) (string, []string, string, error) DecryptSecretConfig func(tenantConfiguration map[string]interface{}, config map[string]interface{}) string GetDFSPathName func() (string, string) GetDatabaseName func() string CompareLastModified func(dfStatMapA map[string]interface{}, dfStatMapB map[string]interface{}) bool PreviousStateCheck func(currentState int) int GetMachineID func() string InitPluginConfig func(pluginEnvConfig map[string]interface{}) map[string]interface{} }
var BuildOptions *OptionsBuilder