Small optimization: pre-compile the regex patterns
Introduces thread safety and re-use of a single parser. Also allows # of days for UA cache to be configured via command line