339ac072d1f85bd1b55fc2e123d15282b2bd89dc
1
module internal Logger.Constants
4 open System.Text.RegularExpressions
6 let [<Literal>] DEFAULT_MAX_SIZE_FILE = 52428800L // [byte] (50 MB).
8 // Each 100 entries added we check the size of the log file to test if it is greater than 'MAX_SIZE_FILE'.
9 let [<Literal>] NB_ENTRIES_CHECK_SIZE = 100;
11 let [<Literal>] MAX_NB_OF_MESSAGE_HASHES_WHEN_AVOIDING_REPEATING_IDENTICAL_MESSAGES = 10;
12 let [<Literal>] MIN_MESSAGE_LENGTH_TO_NOT_BE_REPEATED = 40;
14 let [<Literal>] COMPRESS_ARCHIVED_FILES = true
16 let [<Literal>] FILENAME_FORMAT = "{0:D4}.log"
17 let [<Literal>] COMPRESSED_FILE_POSTFIX = ".gzip"
18 let FILENAME_PATTERN = Regex @"\d{4}\.log"
19 let FILENAME_PATTERN_COMPRESSED = Regex (string FILENAME_PATTERN + COMPRESSED_FILE_POSTFIX.Replace (".", @"\."))
20 let encoding = Encoding.GetEncoding "UTF-8"
21 let [<Literal>] DEFAULT_LOG_DIR = "log"