多行切分
简介
配置参数
参数
类型
是否必选
说明
样例
echo -e '[2022-03-03 18:00:00] xxx1\nyyyyy\nzzzzzz\n[2022-03-03 18:00:01] xxx2\nyyyyy\nzzzzzz' >> /home/test-log/multiline.logenable: true
inputs:
- Type: file_log
LogPath: /home/test-log/
FilePattern: multiline.log
processors:
- Type: processor_split_log_regex
SplitRegex: \[\d+-\d+-\d+\s\d+:\d+:\d+]\s.*
SplitKey: content
PreserveOthers: true
flushers:
- Type: flusher_sls
Endpoint: cn-xxx.log.aliyuncs.com
ProjectName: test_project
LogstoreName: test_logstore
- Type: flusher_stdout
OnlyStdout: trueLast updated