Documentation ¶
Index ¶
- func AutoSetMetricAPI(currentSample *map[string]interface{}, api *load.API)
- func AutoSetMetricInfra(k string, v interface{}, metricSet *metric.Set, metrics map[string]string, ...)
- func AutoSetStandard(currentSample *map[string]interface{}, api *load.API, ...)
- func CreateMetricSets(samples []interface{}, config *load.Config, i int, mergeMetric bool, ...)
- func FinalMerge(data map[string]interface{}) []interface{}
- func FindStartKey(mainDataset *map[string]interface{}, startKeys []string, ...)
- func FlattenData(unknown interface{}, data map[string]interface{}, key string, ...) map[string]interface{}
- func ProcessSamplesMergeJoin(samplesToMerge *map[string][]interface{}, yml *load.Config)
- func RunDataHandler(dataSets []interface{}, samplesToMerge *map[string][]interface{}, i int, ...)
- func RunEventFilter(filters []load.Filter, createEvent *bool, k string, v interface{})
- func RunKeepKeys(keepKeys []string, key *string, currentSample *map[string]interface{})
- func RunKeyConversion(key *string, api load.API, v interface{}, SkipProcessing *[]string)
- func RunKeyFilter(filters []load.Filter, currentSample *map[string]interface{}, k string)
- func RunKeyRemover(currentSample *map[string]interface{}, removeKeys []string)
- func RunKeyRenamer(renameKeys map[string]string, key *string, originalKey string)
- func RunLazyFlatten(ds *map[string]interface{}, cfg *load.Config, api int)
- func RunMathCalculations(math *map[string]string, currentSample *map[string]interface{})
- func RunPluckNumbers(v *interface{}, api load.API, key *string)
- func RunSampleFilter(currentSample map[string]interface{}, sampleFilters []map[string]string, ...)
- func RunSampleRenamer(renameSamples map[string]string, currentSample *map[string]interface{}, ...)
- func RunSubParse(subParse []load.Parse, currentSample *map[string]interface{}, key string, ...)
- func RunValConversion(v *interface{}, api load.API, key *string)
- func RunValueMapper(mapKeys map[string][]string, currentSample *map[string]interface{}, key string, ...)
- func RunValueParser(v *interface{}, api load.API, key *string)
- func RunValueTransformer(v *interface{}, api load.API, key *string)
- func SetEventType(currentSample *map[string]interface{}, eventType *string, apiEventType string, ...)
- func StoreLookups(storeLookups map[string]string, key *string, ...)
- func StripKeys(ds *map[string]interface{}, stripKeys []string)
- func VariableLookups(variableLookups map[string]string, key *string, ...)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AutoSetMetricAPI ¶
AutoSetMetricAPI automatically set metrics for use with the metric api
func AutoSetMetricInfra ¶
func AutoSetMetricInfra(k string, v interface{}, metricSet *metric.Set, metrics map[string]string, autoSet bool, mode string)
AutoSetMetricInfra parse to number
func AutoSetStandard ¶
func AutoSetStandard(currentSample *map[string]interface{}, api *load.API, workingEntity *integration.Entity, eventType string, config *load.Config)
AutoSetStandard x
func CreateMetricSets ¶
func CreateMetricSets(samples []interface{}, config *load.Config, i int, mergeMetric bool, samplesToMerge *map[string][]interface{})
CreateMetricSets creates metric sets hren added samplesToMerge parameter, moved merge operation to CreateMetricSets so that the "Run...." functions still apply before merge
func FinalMerge ¶
func FinalMerge(data map[string]interface{}) []interface{}
FinalMerge Perform final data merging Separates detected samples and already flattened attributes
func FindStartKey ¶
FindStartKey start at a different section of a payload
func FlattenData ¶
func FlattenData(unknown interface{}, data map[string]interface{}, key string, sampleKeys map[string]string, api *load.API) map[string]interface{}
FlattenData flatten an interface
func ProcessSamplesMergeJoin ¶ added in v0.9.3
hren: ProcessSamplesMergeJoin used to merge/join multiple samples together hren
func RunDataHandler ¶
func RunDataHandler(dataSets []interface{}, samplesToMerge *map[string][]interface{}, i int, cfg *load.Config)
RunDataHandler handles the data received for processing
func RunEventFilter ¶
RunEventFilter filters events generated
func RunKeepKeys ¶
RunKeepKeys Removes all other keys/attributes and keep only those defined in keep_keys
func RunKeyConversion ¶
RunKeyConversion handles to lower and snake to camel case for keys
func RunKeyFilter ¶
RunKeyFilter filters keys generated
func RunKeyRemover ¶
RunKeyRemover Remove unwanted keys with regex
func RunKeyRenamer ¶
RunKeyRenamer find keys with regex, and replace the value
func RunLazyFlatten ¶
RunLazyFlatten lazy flattens the payload
func RunMathCalculations ¶
RunMathCalculations performs math calculations
func RunPluckNumbers ¶
RunPluckNumbers pluck numbers out automatically with ValueParser eg. "sample_start_time = 1552864614.137869 (Sun, 17 Mar 2019 23:16:54 GMT)" returns 1552864614.137869
func RunSampleFilter ¶
func RunSampleFilter(currentSample map[string]interface{}, sampleFilters []map[string]string, createSample *bool)
RunSampleFilter Filters samples generated
func RunSampleRenamer ¶
func RunSampleRenamer(renameSamples map[string]string, currentSample *map[string]interface{}, key string, eventType *string)
RunSampleRenamer using regex if sample has a key that matches, make that a different sample (event_type)
func RunSubParse ¶
func RunSubParse(subParse []load.Parse, currentSample *map[string]interface{}, key string, v interface{})
RunSubParse splits nested values out from one line eg. db0:keys=1,expires=0,avg_ttl=0
func RunValConversion ¶
RunValConversion performs percentage to decimal & nano second to millisecond
func RunValueMapper ¶ added in v0.9.3
func RunValueMapper(mapKeys map[string][]string, currentSample *map[string]interface{}, key string, v *interface{})
RunValueMapper map the value using regex grouping for keys e.g. "*.?\s(Service Status)=>$1-Good" -> "Service Status-Good"
func RunValueParser ¶
RunValueParser use regex to find a key, and pluck out its value by regex
func RunValueTransformer ¶
RunValueTransformer use regex to find a key, and then transform the value eg. key: world key: hello-${value} == key: hello-world
func SetEventType ¶
func SetEventType(currentSample *map[string]interface{}, eventType *string, apiEventType string, apiMerge string, apiName string)
SetEventType sets the metricSet's eventType
func StoreLookups ¶
func StoreLookups(storeLookups map[string]string, key *string, lookupStore *map[string]map[string]struct{}, v *interface{})
StoreLookups if key is found (using regex), store the values in the lookupStore as the defined lookupStoreKey for later use
Types ¶
This section is empty.