Articles index:
- Introduction (Everyone)
- JSON as logs format (Everyone)
- Logging best practices with Logback (Targetting Java DEVs)
- Logging cutting-edge practices (Targetting Java DEVs)
- Contract first log generator (Targetting Java DEVs)
- ElasticSearch VRR Estimation Strategy (Targetting OPS)
- VRR Java + Logback configuration (Targetting OPS)
- VRR FileBeat configuration (Targetting OPS)
- VRR Logstash configuration and Index templates (Targetting OPS)
- VRR Curator configuration (Targetting OPS)
- Logstash Grok, JSON Filter and JSON Input performance comparison (Targetting OPS)
VRR FileBeat configuration
Filebeat doesn't need much configuration for JSON log files, just our typical agreement between parties:
- DEVs agree to
- use JSON for logs,
- VRR as log retention strategy,
- "imp" JSON field for VRR "importance" fields with values LOW, IMP, CRIT
- no "imp" field means LOW importance
- OPS agree to
- take this file and use retention and replication depending on those fields
- add "service" in filebeat for application name
- add "environment" in filebeat where applicable
- add "logschema":"vrr" to distinguish a common approach for logs.
As contract is mostly the same for all applications, Filebeat configuration is very reusable, one entry per application and box.
This file, in a working example, can be found here.
- type: log
enabled: true <- important ;)
paths:
- /path/to/logFile.json
encoding: utf-8
fields:
logschema: vrr <- this value will be reused in Logstash configuration
service: leveluplogging <- application / service name
environment: production <- optional, very.
Next: 9 - VRR Logstash configuration and Index templates
No hay comentarios:
Publicar un comentario
Nota: solo los miembros de este blog pueden publicar comentarios.