Containerized applications को centralized logging और monitoring की आवश्यकता होती है क्योंकि containers ephemeral और numerous हैं — logs और metrics को externally collect किया जाना चाहिए ताकि वे container removal से बच सकें और पूरे system में visibility प्रदान करें। यह production containers के लिए आवश्यक observability है।
Logging: stdout/stderr पर log करें, centrally aggregate करें
BEST PRACTICE: containers should log to STDOUT/STDERR (not to files inside the container):
→ Docker captures these (`docker logs`); a logging DRIVER forwards them elsewhere
→ WHY: containers are EPHEMERAL — logs in a removed container are LOST. Centralize them.
