What is Logging?
Turkish: Loglama
Logging is the practice of recording runtime events from applications and systems — critical for debugging and monitoring.
What is Logging?
Logging is the practice of recording what an application does at runtime: which request arrived, where an error occurred, and how important business events progressed. Good logs support not only debugging, but also operations, security, and customer support.
Production systems usually benefit from structured logs. Timestamp, level (debug, info, warn, error), service name, environment, request ID, user or tenant ID, and error details can follow the same schema. Passwords, tokens, card data, and unnecessary personal data should not be logged; sensitive fields should be masked.
Good Logging Practices
- Include useful context for errors without repeating the same event excessively.
- Use correlation IDs to follow a request across distributed services.
- Tune log levels based on environment and event importance.
- Define retention, archiving, and access permissions according to compliance needs.
Logging is not the same as monitoring: logs provide textual event records, while metrics and traces cover different visibility layers. Production systems should design it alongside monitoring, audit logs for security records, and OpenTelemetry for distributed tracing.
Related Terms
An audit log records critical system actions with user, time, resource, and outcome details to leave an inspectable trail.
KibanaKibana is the visual component of the ELK Stack for visualizing and analyzing log and metric data stored in Elasticsearch.
MonitoringMonitoring tracks application and infrastructure metrics, logs, and alerts to detect problems before users or SLAs are affected.
ObservabilityObservability is the ability to understand a system's internal state from its external outputs (logs, metrics, traces) — a key DevOps principle.
SentrySentry groups application errors with stack traces, releases, environments, and user impact so teams can monitor production issues.