The project aim is to help "plain old text logs" analysis, by transforming log entries into more structured form and putting them into a database.
The project aim is to help “plain old text logs” analysis, by transforming log entries into more structured form and putting them into a database. User can configure values to be extracted from log text messages and placed into separate columns in the target table.
IMPORTANT: The project is at an early stage of development and is still work in progress.
The conversion process implemented in the application can be divided into several steps:
The logs conversion process is configured with log-conversion-config.json file. Sample file is included in the application repository. Configuration parameters:
InputLogFilePath
- path to the file to be processedConnectionString
- connection string to the target MS SQL Server databaseLogTableName
- name of the table where the logs should be inserted - if the table does not exist, it will be created automaticallyLogRegexTemplates
- array of log matching patterns matching and templates for structurized logs to be saved into a database. Log patterns and templates are described more thoroughly in the next section.Pattern matching uses standard C# Regex class pattern syntaxt. It’s important to note that names of the named capture groups defined in the pattern are used to extract values for specific fields.
When a match is found for specific named group, its name represents extracted field’s name. The matched group name and value are then used to fill target structured log template in the appropriate place.
Features supported so far: