Fluentular

a Fluentd regular expression editor

Configuration

Copy and paste to fluent.conf or td-agent.conf

<source>
  type tail
  path /var/log/foo/bar.log
  pos_file /var/log/td-agent/foo-bar.log.pos
  tag foo.bar
  format /^(?<level>[^ ]*) \| (?<logtime>[^\]]*) \| (?<app_name>[^ ]*) \| (?<log_type>[^ ]*) \| (?<program>[^ ]*) \| (?<function>[^ ]*) \| (?<message>[^*]*)$/
</source>

Data Inspector

Attributes

Key Value
time 2024/09/13 10:09:55 +0000

Records

Key Value
level INFO
logtime 2021-09-05 16:34:353535 +00:00
app_name hello_api
log_type access
program my_api.http
function send
message here is your log