A practical implementation of using hash/maps to create statistics about "Exceptions" in Apache Tomcat logfiles.
Use your Go toolkit to get the sources and compile exceptionz
from scratch:
go get -u github.com/andygeiss/exceptionz
The current version supports three different statistics (see API):
-
Get the total amount of unique Exceptions occured: totalExceptions
-
Get the amount of unique Exceptions occured per Class: totalClasses
-
Get the amount of Exceptions mapped to each Class (detailed): classExceptions
Usage of [exceptionz]: -path string Target path -stats string Type of statistics (totalClasses|totalExceptions|classExceptions) Examples: exceptionz -path ./testdata -stats totalClasses
The output will be written as CSV with semicolon as separator:
Exception Occured;Exception;Classname
1;java.io.IOException;Classname