This is an application to parse log files
Responsible for file reading and parsing, handles file errors.
File reader streams each row directly to consumer to support huge files, lazy enumerator allows not to load enormous file into memory
Strategy to gather data. Analyzers are injectable and could be turned off\on if necessary
Strategy for reporting data.
There is only one reporting to stdout, there could be email\file reporters
- install ruby 2.7.1
- install bundler
- run
bundle install
To run the parser
bin/parser.rb spec/files/webserver.log
-
code linter:
bin/rubocop
-
specs:
bin/rspec