Last active
September 27, 2017 15:26
-
-
Save wardbekker/24e3cbb981ac97af3be0cff274e1d04a to your computer and use it in GitHub Desktop.
Squid parsers config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"parserClassName": "org.apache.metron.parsers.GrokParser", | |
"filterClassName": null, | |
"sensorTopic": "squid2", | |
"writerClassName": null, | |
"errorWriterClassName": null, | |
"invalidWriterClassName": null, | |
"readMetadata": false, | |
"mergeMetadata": false, | |
"numWorkers": null, | |
"numAckers": null, | |
"spoutParallelism": 1, | |
"spoutNumTasks": 1, | |
"parserParallelism": 1, | |
"parserNumTasks": 1, | |
"errorWriterParallelism": 1, | |
"errorWriterNumTasks": 1, | |
"spoutConfig": null, | |
"securityProtocol": null, | |
"stormConfig": null, | |
"parserConfig": { | |
"grokPath": "/patterns/squid", | |
"patternLabel": "SQUID_DELIMITED", | |
"timestampField": "timestamp" | |
}, | |
"fieldTransformations": [ | |
{ | |
"input": [], | |
"output": [ | |
"full_hostname", | |
"domain_without_subdomains", | |
"count_unique_dist_addr", | |
"is_alert" | |
], | |
"transformation": "STELLAR", | |
"config": { | |
"full_hostname": "URL_TO_HOST(url)", | |
"domain_without_subdomains": "DOMAIN_REMOVE_SUBDOMAINS(full_hostname)", | |
"count_unique_dist_addr": "REDUCE(PROFILE_GET( 'count_unique_dist_addr', ip_dst_addr, PROFILE_FIXED(1, 'DAYS')), (sum, x) -> sum + x, 0)", | |
"is_alert": true | |
} | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment