Details
-
Type:
New Feature
-
Status: Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 0.7.0
-
Fix Version/s: 0.8.0
-
Component/s: Morphlines Module
-
Labels:None
Description
Add morphline commands that support publishing the metrics of all morphline commands to JMX, SLF4J and CSV files. The new commands are: startReportingMetricsToJMX, startReportingMetricsToSLF4J and startReportingMetricsToCSV.
Example usage for startReportingMetricsToJMX:
startReportingMetricsToJMX { domain : myMetrics durationUnits : { myMetrics.myTimer : minutes } defaultDurationUnit : milliseconds rateUnits : { myMetrics.myTimer : milliseconds LogDebug.numProcessCalls : milliseconds } defaultRateUnit : seconds metricFilter : { includes : { # if absent defaults to match all "literal:foo" : "glob:foo*" "regex:.*" : "glob:*" } excludes : { # if absent defaults to match none "literal:foo.bar" : "*" } } }
Example usage for startReportingMetricsToSLF4J:
startReportingMetricsToSLF4J { logger : "com.cloudera.cdk.morphline.domain1" period : "10 seconds" defaultDurationUnit : milliseconds defaultRateUnit : seconds metricFilter : { includes : { # if absent defaults to match all "literal:foo" : "glob:foo*" "regex:.*" : "glob:*" } excludes : { # if absent defaults to match none "literal:foo.bar" : "*" } } }
Example usage for startReportingMetricsToCSV:
startReportingMetricsToCSV { dir : "mytest/metricsLogs" period : "10 seconds" locale : en_US defaultDurationUnit : milliseconds defaultRateUnit : seconds metricFilter : { includes : { # if absent defaults to match all "literal:foo" : "glob:foo*" "regex:.*" : "glob:*" } excludes : { # if absent defaults to match none "literal:foo.bar" : "*" } } }
For detailed docs see https://github.com/cloudera/cdk/blob/master/cdk-morphlines/src/site/confluence/morphlinesReferenceGuide.confluence