SlideShare a Scribd company logo
1 of 50
Log Management
System
for Microservices
Võ Duy Tuấn
Founder
Teamcrop.com
Vo Duy Tuan
 PHP, Javascript, Flutter
 Web Scalability & Optimization
 Data Mining
 ERP System
 Docker & Microservices
Interests
Founder @ Teamcrop.com
Why log management?
• System troubleshooting
• Application debugging
• Performance optimization
• Security
• Business decision making
Type of Logs
• Business
– Auditing
– Feature Usage
– Critical Function
• Operation
– Operating System
– General
– API Request
– SQL Query
– Distributed Tracing
Abstract Logging Design
Storage
Collecto
r
Dashboard
Syslog
PHP Log
Nginx Log
Access Log
Error Log
Activity Log
…
PHP
React JS
Grafana
File
Syslog
RabbitMQ
MySQL
Clickhouse
Anatomy of a Service @Teamcrop
Host (Linux)
Service Container (Docker)
Web Server (Nginx) + PHP
Application Request (eg: order)
SQL Query 1
SQL Query 2
Call another services request (Eg: customer, cashflow…)
OS log
Syslog
Access, Error log
API Request, Audit…
SQL Query log
Distributed tracing
| Business1
1.1. Auditing Log
• Metrics:
– Employee
– Service
– Section (controller)
– Action (add, update, delete, import..)
– Severity
– Change log
– IP Address
1.1. Store Auditing Log
Audit Log
Message
Queue
(RabbitMQ)
Queue Worker
(PHP)
Teamcrop API
(PHP)
Teamcrop Log
(MySQL)
1.1. View Auditing Log
Teamcrop
Audit Log API
(PHP)
Teamcrop Log
(MySQL)
Dashboard
(React JS)
Request Query
1.1. Auditing Log Stack
• Collector
– PHP
• Storage
– MySQL
• Dashboard
– React JS
1.1. Auditing Log Example
1.1. Auditing Log Example (cont.)
1.2. Feature Usage Log
• Metrics:
– Visitor
– Page View
– Time on Page
– Technology
– …
• Stack:
– Google Analytics
– Self-hosted application
1.2. Feature Usage Log Example
1.3. Critical Function Log
• Metrics:
– Raw POST data
• Stack:
– Collector: PHP
– Storage: File System
– Dashboard: React JS
1.3. Critical Function Log Example
| Operation2
2.1. Operating System Log
• Metrics:
– Memory (RAM)
– CPU
– Disk
– Network
– …
• Stack:
– NodeQuery.com
2.1. Operating System Log Example
2.1. Operating System Log Example
(cont.)
2.1. Operating System Log Example
(cont.)
2.2. General Log
• Metrics:
– PHP: error, warning…
– Nginx: access, error…
– Custom Log Message
– Cronjob Log
– Queue Log
– Others
2.2. Store General Log
General Log
(Access, Error Log)
Syslog
(syslog-ng)
UDP
UDP Log Server
(PHP)
Message
Queue
(RabbitMQ)
UDP Log Worker
(PHP)
Clickhouse
(Syslog Table)
2.2. View General Log
Teamcrop
Analytics API
(PHP)
Clickhouse
(Syslog Table)
Dashboard
(React JS)
Request Query
2.2. General Log Stack
• Collector:
– Syslog-ng
• Storage:
– RabbitMQ (Queue)
– Clickhouse
• Dashboard:
– PHP
– React JS
2.2. General Log Example
2.2. General Log Example (cont.)
2.3. API Request Log
• Metrics:
– HTTP Status
– HTTP Method
– Tenant
– Service name
– Function (controller, action)
– Execution time
– Memory
– Source
– …
2.3. Store API Request Log
API Request Log Syslog
(syslog-ng)
UDP
UDP Log Server
(PHP)
Message
Queue
(RabbitMQ)
UDP Log Worker
(PHP)Clickhouse
2.3. View API Request Log
Teamcrop
Analytics API
(PHP) Clickhouse
(API Request
Log Table)
Dashboard
(React JS)
Request Query
Grafana UI Grafana API
Request
Query
2.3. API Request Log Stack
• Collector:
– Syslog-ng
– Monolog (PHP)
• Storage:
– RabbitMQ (Queue)
– Clickhouse
• Dashboard:
– PHP
– React JS
– Grafana
2.3. API Request Log Example
2.3. API Request Log Example
(cont.)
2.3. API Request Log Example
(cont.)
2.3. API Request Log Example
(cont.)
2.4. SQL Query Log
• Metrics:
– Replication
– Table
– Query type (SELECT, INSERT…)
– Execution
– Tenant
– …
2.4. Store SQL Query Log
SQL Query Log Syslog
(syslog-ng)
UDP
UDP Log Server
(PHP)
Message
Queue
(RabbitMQ)
UDP Log Worker
(PHP)Clickhouse
2.4. View SQL Query Log
Teamcrop
Analytics API
(PHP) Clickhouse
(SQL Query
Log Table)
Dashboard
(React JS)
Request Query
Grafana UI Grafana API
Request
Query
2.4. SQL Query Log Stack
• Collector:
– Syslog-ng
– Monolog (PHP)
• Storage:
– RabbitMQ (Queue)
– Clickhouse
• Dashboard:
– PHP
– React JS
– Grafana
2.4. SQL Query Log Example
4. SQL Query Log Example (cont.)
4. SQL Query Log Example (cont.)
2.5. Distributed Tracing Log
• Metrics:
– Chain of requests
– Duration
– Execution
– Tenant
– Service
– …
2.5. Store Distributed Tracing Log
OpenTracing Log
(ZipKin format)
Syslog
(syslog-ng)
UDP
UDP Log Server
(PHP)
Message
Queue
(RabbitMQ)
UDP Log Worker
(PHP)
Jaeger
API
Jaeger
DB
2.5. Distributed Tracing Log Stack
• Collector:
– Syslog-ng
– Monolog (PHP)
– Zipkin Client Library (PHP)
• Storage:
– RabbitMQ (Queue)
– Jaeger
• Dashboard:
– Jaeger UI
2.5. Distributed Tracing Model
• OpenTracing Specification
2.5. Distributed Tracing Log Example
DEMO
RabbitMQ
Jeager UI
Clickhouse GUI Client
Customized Log Dashboard
NodeQuery
Grafana
Teamcrop Log Audit
Thanks!
CONTACT:
voduytuan@teamcrop.com
bloghoctap.com

More Related Content

What's hot

AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017Amazon Web Services Korea
 
Distributed tracing 101
Distributed tracing 101Distributed tracing 101
Distributed tracing 101Itiel Shwartz
 
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기Kee Hoon Lee
 
Microservices & API Gateways
Microservices & API Gateways Microservices & API Gateways
Microservices & API Gateways Kong Inc.
 
[개인 프로젝트] 쿠버네티스를 이용한 개발환경 자동화 구축시스템 - 프로토타입
[개인 프로젝트] 쿠버네티스를 이용한 개발환경 자동화 구축시스템 - 프로토타입[개인 프로젝트] 쿠버네티스를 이용한 개발환경 자동화 구축시스템 - 프로토타입
[개인 프로젝트] 쿠버네티스를 이용한 개발환경 자동화 구축시스템 - 프로토타입choi sungwook
 
Prometheus Training
Prometheus TrainingPrometheus Training
Prometheus TrainingTim Tyler
 
AWS RDS Benchmark - Instance comparison
AWS RDS Benchmark - Instance comparisonAWS RDS Benchmark - Instance comparison
AWS RDS Benchmark - Instance comparisonRoberto Gaiser
 
Grafana Loki: like Prometheus, but for Logs
Grafana Loki: like Prometheus, but for LogsGrafana Loki: like Prometheus, but for Logs
Grafana Loki: like Prometheus, but for LogsMarco Pracucci
 
Distributed Tracing in Practice
Distributed Tracing in PracticeDistributed Tracing in Practice
Distributed Tracing in PracticeDevOps.com
 
Synchronous Commands over Apache Kafka (Neil Buesing, Object Partners, Inc) K...
Synchronous Commands over Apache Kafka (Neil Buesing, Object Partners, Inc) K...Synchronous Commands over Apache Kafka (Neil Buesing, Object Partners, Inc) K...
Synchronous Commands over Apache Kafka (Neil Buesing, Object Partners, Inc) K...confluent
 
AWS 기반 대규모 트래픽 견디기 - 장준엽 (구로디지털 모임) :: AWS Community Day 2017
AWS 기반 대규모 트래픽 견디기 - 장준엽 (구로디지털 모임) :: AWS Community Day 2017AWS 기반 대규모 트래픽 견디기 - 장준엽 (구로디지털 모임) :: AWS Community Day 2017
AWS 기반 대규모 트래픽 견디기 - 장준엽 (구로디지털 모임) :: AWS Community Day 2017AWSKRUG - AWS한국사용자모임
 
Log analysis with the elk stack
Log analysis with the elk stackLog analysis with the elk stack
Log analysis with the elk stackVikrant Chauhan
 
Optimizing Kubernetes Resource Requests/Limits for Cost-Efficiency and Latenc...
Optimizing Kubernetes Resource Requests/Limits for Cost-Efficiency and Latenc...Optimizing Kubernetes Resource Requests/Limits for Cost-Efficiency and Latenc...
Optimizing Kubernetes Resource Requests/Limits for Cost-Efficiency and Latenc...Henning Jacobs
 
GCP Best Practices for SRE Team
GCP Best Practices for SRE TeamGCP Best Practices for SRE Team
GCP Best Practices for SRE TeamHuynh Thai Bao
 
Message Redelivery: An Unexpected Journey - Pulsar Summit SF 2022
Message Redelivery: An Unexpected Journey - Pulsar Summit SF 2022Message Redelivery: An Unexpected Journey - Pulsar Summit SF 2022
Message Redelivery: An Unexpected Journey - Pulsar Summit SF 2022StreamNative
 
Writing Continuous Applications with Structured Streaming PySpark API
Writing Continuous Applications with Structured Streaming PySpark APIWriting Continuous Applications with Structured Streaming PySpark API
Writing Continuous Applications with Structured Streaming PySpark APIDatabricks
 
Let's build a simple app with .net 6 asp.net core web api, react, and elasti...
Let's build a simple app with  .net 6 asp.net core web api, react, and elasti...Let's build a simple app with  .net 6 asp.net core web api, react, and elasti...
Let's build a simple app with .net 6 asp.net core web api, react, and elasti...Shotaro Suzuki
 

What's hot (20)

AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
 
Distributed tracing 101
Distributed tracing 101Distributed tracing 101
Distributed tracing 101
 
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기
실시간 이상탐지를 위한 머신러닝 모델에 Druid _ Imply 활용하기
 
Microservices & API Gateways
Microservices & API Gateways Microservices & API Gateways
Microservices & API Gateways
 
[개인 프로젝트] 쿠버네티스를 이용한 개발환경 자동화 구축시스템 - 프로토타입
[개인 프로젝트] 쿠버네티스를 이용한 개발환경 자동화 구축시스템 - 프로토타입[개인 프로젝트] 쿠버네티스를 이용한 개발환경 자동화 구축시스템 - 프로토타입
[개인 프로젝트] 쿠버네티스를 이용한 개발환경 자동화 구축시스템 - 프로토타입
 
Prometheus Training
Prometheus TrainingPrometheus Training
Prometheus Training
 
AWS RDS Benchmark - Instance comparison
AWS RDS Benchmark - Instance comparisonAWS RDS Benchmark - Instance comparison
AWS RDS Benchmark - Instance comparison
 
Grafana Loki: like Prometheus, but for Logs
Grafana Loki: like Prometheus, but for LogsGrafana Loki: like Prometheus, but for Logs
Grafana Loki: like Prometheus, but for Logs
 
Distributed Tracing in Practice
Distributed Tracing in PracticeDistributed Tracing in Practice
Distributed Tracing in Practice
 
Grafana 7.0
Grafana 7.0Grafana 7.0
Grafana 7.0
 
Synchronous Commands over Apache Kafka (Neil Buesing, Object Partners, Inc) K...
Synchronous Commands over Apache Kafka (Neil Buesing, Object Partners, Inc) K...Synchronous Commands over Apache Kafka (Neil Buesing, Object Partners, Inc) K...
Synchronous Commands over Apache Kafka (Neil Buesing, Object Partners, Inc) K...
 
AWS 기반 대규모 트래픽 견디기 - 장준엽 (구로디지털 모임) :: AWS Community Day 2017
AWS 기반 대규모 트래픽 견디기 - 장준엽 (구로디지털 모임) :: AWS Community Day 2017AWS 기반 대규모 트래픽 견디기 - 장준엽 (구로디지털 모임) :: AWS Community Day 2017
AWS 기반 대규모 트래픽 견디기 - 장준엽 (구로디지털 모임) :: AWS Community Day 2017
 
RabbitMQ
RabbitMQ RabbitMQ
RabbitMQ
 
Log analysis with the elk stack
Log analysis with the elk stackLog analysis with the elk stack
Log analysis with the elk stack
 
Optimizing Kubernetes Resource Requests/Limits for Cost-Efficiency and Latenc...
Optimizing Kubernetes Resource Requests/Limits for Cost-Efficiency and Latenc...Optimizing Kubernetes Resource Requests/Limits for Cost-Efficiency and Latenc...
Optimizing Kubernetes Resource Requests/Limits for Cost-Efficiency and Latenc...
 
GCP Best Practices for SRE Team
GCP Best Practices for SRE TeamGCP Best Practices for SRE Team
GCP Best Practices for SRE Team
 
Elk - An introduction
Elk - An introductionElk - An introduction
Elk - An introduction
 
Message Redelivery: An Unexpected Journey - Pulsar Summit SF 2022
Message Redelivery: An Unexpected Journey - Pulsar Summit SF 2022Message Redelivery: An Unexpected Journey - Pulsar Summit SF 2022
Message Redelivery: An Unexpected Journey - Pulsar Summit SF 2022
 
Writing Continuous Applications with Structured Streaming PySpark API
Writing Continuous Applications with Structured Streaming PySpark APIWriting Continuous Applications with Structured Streaming PySpark API
Writing Continuous Applications with Structured Streaming PySpark API
 
Let's build a simple app with .net 6 asp.net core web api, react, and elasti...
Let's build a simple app with  .net 6 asp.net core web api, react, and elasti...Let's build a simple app with  .net 6 asp.net core web api, react, and elasti...
Let's build a simple app with .net 6 asp.net core web api, react, and elasti...
 

Similar to Log management system for Microservices

Extreme Replication - Performance Tuning Oracle GoldenGate
Extreme Replication - Performance Tuning Oracle GoldenGateExtreme Replication - Performance Tuning Oracle GoldenGate
Extreme Replication - Performance Tuning Oracle GoldenGateBobby Curtis
 
Log Data Analysis Platform by Valentin Kropov
Log Data Analysis Platform by Valentin KropovLog Data Analysis Platform by Valentin Kropov
Log Data Analysis Platform by Valentin KropovSoftServe
 
Log Data Analysis Platform
Log Data Analysis PlatformLog Data Analysis Platform
Log Data Analysis PlatformValentin Kropov
 
Triangle Node.js DevOps
Triangle Node.js DevOpsTriangle Node.js DevOps
Triangle Node.js DevOpsShubhra Kar
 
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly SolarWinds Loggly
 
VMworld 2013: Deep Dive into vSphere Log Management with vCenter Log Insight
VMworld 2013: Deep Dive into vSphere Log Management with vCenter Log InsightVMworld 2013: Deep Dive into vSphere Log Management with vCenter Log Insight
VMworld 2013: Deep Dive into vSphere Log Management with vCenter Log InsightVMworld
 
Tuning Elasticsearch Indexing Pipeline for Logs
Tuning Elasticsearch Indexing Pipeline for LogsTuning Elasticsearch Indexing Pipeline for Logs
Tuning Elasticsearch Indexing Pipeline for LogsSematext Group, Inc.
 
Dealing with and learning from the sandbox
Dealing with and learning from the sandboxDealing with and learning from the sandbox
Dealing with and learning from the sandboxElaine Van Bergen
 
Transforming Mobile Push Notifications with Big Data
Transforming Mobile Push Notifications with Big DataTransforming Mobile Push Notifications with Big Data
Transforming Mobile Push Notifications with Big Dataplumbee
 
How bol.com makes sense of its logs, using the Elastic technology stack.
How bol.com makes sense of its logs, using the Elastic technology stack.How bol.com makes sense of its logs, using the Elastic technology stack.
How bol.com makes sense of its logs, using the Elastic technology stack.Renzo Tomà
 
Cloud Foundry Monitoring How-To: Collecting Metrics and Logs
Cloud Foundry Monitoring How-To: Collecting Metrics and LogsCloud Foundry Monitoring How-To: Collecting Metrics and Logs
Cloud Foundry Monitoring How-To: Collecting Metrics and LogsAltoros
 
Meetup milano #4 log management and anypoint advanced monitoring
Meetup milano #4   log management and anypoint advanced monitoringMeetup milano #4   log management and anypoint advanced monitoring
Meetup milano #4 log management and anypoint advanced monitoringGonzalo Marcos Ansoain
 
Dealing with and learning from the sandbox
Dealing with and learning from the sandboxDealing with and learning from the sandbox
Dealing with and learning from the sandboxElaine Van Bergen
 
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...Amazon Web Services
 
VMworld 2013: Performance Management of Business Critical Applications using ...
VMworld 2013: Performance Management of Business Critical Applications using ...VMworld 2013: Performance Management of Business Critical Applications using ...
VMworld 2013: Performance Management of Business Critical Applications using ...VMworld
 
Log aggregation and analysis
Log aggregation and analysisLog aggregation and analysis
Log aggregation and analysisDhaval Mehta
 
NoSQL em Windows Azure Table Storage - Vitor Tomaz
NoSQL em Windows Azure Table Storage - Vitor TomazNoSQL em Windows Azure Table Storage - Vitor Tomaz
NoSQL em Windows Azure Table Storage - Vitor TomazComunidade NetPonto
 
[NetPonto] NoSQL em Windows Azure Table Storage
[NetPonto] NoSQL em Windows Azure Table Storage[NetPonto] NoSQL em Windows Azure Table Storage
[NetPonto] NoSQL em Windows Azure Table StorageVitor Tomaz
 

Similar to Log management system for Microservices (20)

Extreme Replication - Performance Tuning Oracle GoldenGate
Extreme Replication - Performance Tuning Oracle GoldenGateExtreme Replication - Performance Tuning Oracle GoldenGate
Extreme Replication - Performance Tuning Oracle GoldenGate
 
Log Data Analysis Platform by Valentin Kropov
Log Data Analysis Platform by Valentin KropovLog Data Analysis Platform by Valentin Kropov
Log Data Analysis Platform by Valentin Kropov
 
Log Data Analysis Platform
Log Data Analysis PlatformLog Data Analysis Platform
Log Data Analysis Platform
 
Triangle Node.js DevOps
Triangle Node.js DevOpsTriangle Node.js DevOps
Triangle Node.js DevOps
 
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly
AWS re:Invent presentation: Unmeltable Infrastructure at Scale by Loggly
 
Docker Logging Webinar
Docker Logging  WebinarDocker Logging  Webinar
Docker Logging Webinar
 
VMworld 2013: Deep Dive into vSphere Log Management with vCenter Log Insight
VMworld 2013: Deep Dive into vSphere Log Management with vCenter Log InsightVMworld 2013: Deep Dive into vSphere Log Management with vCenter Log Insight
VMworld 2013: Deep Dive into vSphere Log Management with vCenter Log Insight
 
Tuning Elasticsearch Indexing Pipeline for Logs
Tuning Elasticsearch Indexing Pipeline for LogsTuning Elasticsearch Indexing Pipeline for Logs
Tuning Elasticsearch Indexing Pipeline for Logs
 
Log Files
Log FilesLog Files
Log Files
 
Dealing with and learning from the sandbox
Dealing with and learning from the sandboxDealing with and learning from the sandbox
Dealing with and learning from the sandbox
 
Transforming Mobile Push Notifications with Big Data
Transforming Mobile Push Notifications with Big DataTransforming Mobile Push Notifications with Big Data
Transforming Mobile Push Notifications with Big Data
 
How bol.com makes sense of its logs, using the Elastic technology stack.
How bol.com makes sense of its logs, using the Elastic technology stack.How bol.com makes sense of its logs, using the Elastic technology stack.
How bol.com makes sense of its logs, using the Elastic technology stack.
 
Cloud Foundry Monitoring How-To: Collecting Metrics and Logs
Cloud Foundry Monitoring How-To: Collecting Metrics and LogsCloud Foundry Monitoring How-To: Collecting Metrics and Logs
Cloud Foundry Monitoring How-To: Collecting Metrics and Logs
 
Meetup milano #4 log management and anypoint advanced monitoring
Meetup milano #4   log management and anypoint advanced monitoringMeetup milano #4   log management and anypoint advanced monitoring
Meetup milano #4 log management and anypoint advanced monitoring
 
Dealing with and learning from the sandbox
Dealing with and learning from the sandboxDealing with and learning from the sandbox
Dealing with and learning from the sandbox
 
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...
Infrastructure at Scale: Apache Kafka, Twitter Storm & Elastic Search (ARC303...
 
VMworld 2013: Performance Management of Business Critical Applications using ...
VMworld 2013: Performance Management of Business Critical Applications using ...VMworld 2013: Performance Management of Business Critical Applications using ...
VMworld 2013: Performance Management of Business Critical Applications using ...
 
Log aggregation and analysis
Log aggregation and analysisLog aggregation and analysis
Log aggregation and analysis
 
NoSQL em Windows Azure Table Storage - Vitor Tomaz
NoSQL em Windows Azure Table Storage - Vitor TomazNoSQL em Windows Azure Table Storage - Vitor Tomaz
NoSQL em Windows Azure Table Storage - Vitor Tomaz
 
[NetPonto] NoSQL em Windows Azure Table Storage
[NetPonto] NoSQL em Windows Azure Table Storage[NetPonto] NoSQL em Windows Azure Table Storage
[NetPonto] NoSQL em Windows Azure Table Storage
 

More from Võ Duy Tuấn

Mobile outsourcing best practices
Mobile outsourcing best practicesMobile outsourcing best practices
Mobile outsourcing best practicesVõ Duy Tuấn
 
Chatbot in Sale Management
Chatbot in Sale ManagementChatbot in Sale Management
Chatbot in Sale ManagementVõ Duy Tuấn
 
Microservices and docker
Microservices and dockerMicroservices and docker
Microservices and dockerVõ Duy Tuấn
 
Scale with Microservices
Scale with MicroservicesScale with Microservices
Scale with MicroservicesVõ Duy Tuấn
 
Microservices in production
Microservices in productionMicroservices in production
Microservices in productionVõ Duy Tuấn
 
Business Intelligence in Retail Industry
Business Intelligence in Retail IndustryBusiness Intelligence in Retail Industry
Business Intelligence in Retail IndustryVõ Duy Tuấn
 
How to Build Recommender System with Content based Filtering
How to Build Recommender System with Content based FilteringHow to Build Recommender System with Content based Filtering
How to Build Recommender System with Content based FilteringVõ Duy Tuấn
 
Php psr standard 2014 01-22
Php psr standard 2014 01-22Php psr standard 2014 01-22
Php psr standard 2014 01-22Võ Duy Tuấn
 
Speed up with hiphop php 2014 01-22
Speed up with hiphop php 2014 01-22Speed up with hiphop php 2014 01-22
Speed up with hiphop php 2014 01-22Võ Duy Tuấn
 
How to build a Recommender System
How to build a Recommender SystemHow to build a Recommender System
How to build a Recommender SystemVõ Duy Tuấn
 
Reader.vn 2012 - The Book Of Life
Reader.vn 2012 - The Book Of LifeReader.vn 2012 - The Book Of Life
Reader.vn 2012 - The Book Of LifeVõ Duy Tuấn
 
Heavy Web Optimization: Backend
Heavy Web Optimization: BackendHeavy Web Optimization: Backend
Heavy Web Optimization: BackendVõ Duy Tuấn
 
Heavy Web Optimization: Frontend
Heavy Web Optimization: FrontendHeavy Web Optimization: Frontend
Heavy Web Optimization: FrontendVõ Duy Tuấn
 
Caching strategy and apc
Caching strategy and apcCaching strategy and apc
Caching strategy and apcVõ Duy Tuấn
 
PHP: Debugger, Profiler and more
PHP: Debugger, Profiler and morePHP: Debugger, Profiler and more
PHP: Debugger, Profiler and moreVõ Duy Tuấn
 
Magento overview and how sell Magento extensions
Magento overview and how sell Magento extensionsMagento overview and how sell Magento extensions
Magento overview and how sell Magento extensionsVõ Duy Tuấn
 
Javascript unit testing framework
Javascript unit testing frameworkJavascript unit testing framework
Javascript unit testing frameworkVõ Duy Tuấn
 

More from Võ Duy Tuấn (20)

Flutter introduction
Flutter introductionFlutter introduction
Flutter introduction
 
Mobile outsourcing best practices
Mobile outsourcing best practicesMobile outsourcing best practices
Mobile outsourcing best practices
 
Chatbot in Sale Management
Chatbot in Sale ManagementChatbot in Sale Management
Chatbot in Sale Management
 
Microservices and docker
Microservices and dockerMicroservices and docker
Microservices and docker
 
Scale with Microservices
Scale with MicroservicesScale with Microservices
Scale with Microservices
 
React introduction
React introductionReact introduction
React introduction
 
Microservices in production
Microservices in productionMicroservices in production
Microservices in production
 
Business Intelligence in Retail Industry
Business Intelligence in Retail IndustryBusiness Intelligence in Retail Industry
Business Intelligence in Retail Industry
 
How to Build Recommender System with Content based Filtering
How to Build Recommender System with Content based FilteringHow to Build Recommender System with Content based Filtering
How to Build Recommender System with Content based Filtering
 
Php psr standard 2014 01-22
Php psr standard 2014 01-22Php psr standard 2014 01-22
Php psr standard 2014 01-22
 
Speed up with hiphop php 2014 01-22
Speed up with hiphop php 2014 01-22Speed up with hiphop php 2014 01-22
Speed up with hiphop php 2014 01-22
 
How to build a Recommender System
How to build a Recommender SystemHow to build a Recommender System
How to build a Recommender System
 
Mobile for web
Mobile for webMobile for web
Mobile for web
 
Reader.vn 2012 - The Book Of Life
Reader.vn 2012 - The Book Of LifeReader.vn 2012 - The Book Of Life
Reader.vn 2012 - The Book Of Life
 
Heavy Web Optimization: Backend
Heavy Web Optimization: BackendHeavy Web Optimization: Backend
Heavy Web Optimization: Backend
 
Heavy Web Optimization: Frontend
Heavy Web Optimization: FrontendHeavy Web Optimization: Frontend
Heavy Web Optimization: Frontend
 
Caching strategy and apc
Caching strategy and apcCaching strategy and apc
Caching strategy and apc
 
PHP: Debugger, Profiler and more
PHP: Debugger, Profiler and morePHP: Debugger, Profiler and more
PHP: Debugger, Profiler and more
 
Magento overview and how sell Magento extensions
Magento overview and how sell Magento extensionsMagento overview and how sell Magento extensions
Magento overview and how sell Magento extensions
 
Javascript unit testing framework
Javascript unit testing frameworkJavascript unit testing framework
Javascript unit testing framework
 

Recently uploaded

Midocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxMidocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxolyaivanovalion
 
Week-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionWeek-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionfulawalesam
 
Capstone Project on IBM Data Analytics Program
Capstone Project on IBM Data Analytics ProgramCapstone Project on IBM Data Analytics Program
Capstone Project on IBM Data Analytics ProgramMoniSankarHazra
 
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...amitlee9823
 
CebaBaby dropshipping via API with DroFX.pptx
CebaBaby dropshipping via API with DroFX.pptxCebaBaby dropshipping via API with DroFX.pptx
CebaBaby dropshipping via API with DroFX.pptxolyaivanovalion
 
Halmar dropshipping via API with DroFx
Halmar  dropshipping  via API with DroFxHalmar  dropshipping  via API with DroFx
Halmar dropshipping via API with DroFxolyaivanovalion
 
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...amitlee9823
 
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...SUHANI PANDEY
 
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -Pooja Nehwal
 
April 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's AnalysisApril 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's Analysismanisha194592
 
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...Delhi Call girls
 
Discover Why Less is More in B2B Research
Discover Why Less is More in B2B ResearchDiscover Why Less is More in B2B Research
Discover Why Less is More in B2B Researchmichael115558
 
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...Valters Lauzums
 
FESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdfFESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdfMarinCaroMartnezBerg
 
BigBuy dropshipping via API with DroFx.pptx
BigBuy dropshipping via API with DroFx.pptxBigBuy dropshipping via API with DroFx.pptx
BigBuy dropshipping via API with DroFx.pptxolyaivanovalion
 
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...amitlee9823
 

Recently uploaded (20)

Midocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxMidocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFx
 
Week-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionWeek-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interaction
 
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get CytotecAbortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
 
Sampling (random) method and Non random.ppt
Sampling (random) method and Non random.pptSampling (random) method and Non random.ppt
Sampling (random) method and Non random.ppt
 
Capstone Project on IBM Data Analytics Program
Capstone Project on IBM Data Analytics ProgramCapstone Project on IBM Data Analytics Program
Capstone Project on IBM Data Analytics Program
 
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...
 
CebaBaby dropshipping via API with DroFX.pptx
CebaBaby dropshipping via API with DroFX.pptxCebaBaby dropshipping via API with DroFX.pptx
CebaBaby dropshipping via API with DroFX.pptx
 
Halmar dropshipping via API with DroFx
Halmar  dropshipping  via API with DroFxHalmar  dropshipping  via API with DroFx
Halmar dropshipping via API with DroFx
 
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
 
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
VIP Model Call Girls Hinjewadi ( Pune ) Call ON 8005736733 Starting From 5K t...
 
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -
Thane Call Girls 7091864438 Call Girls in Thane Escort service book now -
 
April 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's AnalysisApril 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's Analysis
 
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
Call Girls in Sarai Kale Khan Delhi 💯 Call Us 🔝9205541914 🔝( Delhi) Escorts S...
 
Anomaly detection and data imputation within time series
Anomaly detection and data imputation within time seriesAnomaly detection and data imputation within time series
Anomaly detection and data imputation within time series
 
Discover Why Less is More in B2B Research
Discover Why Less is More in B2B ResearchDiscover Why Less is More in B2B Research
Discover Why Less is More in B2B Research
 
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
 
FESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdfFESE Capital Markets Fact Sheet 2024 Q1.pdf
FESE Capital Markets Fact Sheet 2024 Q1.pdf
 
BigBuy dropshipping via API with DroFx.pptx
BigBuy dropshipping via API with DroFx.pptxBigBuy dropshipping via API with DroFx.pptx
BigBuy dropshipping via API with DroFx.pptx
 
(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7
(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7
(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7
 
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
Call Girls Hsr Layout Just Call 👗 7737669865 👗 Top Class Call Girl Service Ba...
 

Log management system for Microservices

  • 1. Log Management System for Microservices Võ Duy Tuấn Founder Teamcrop.com
  • 2. Vo Duy Tuan  PHP, Javascript, Flutter  Web Scalability & Optimization  Data Mining  ERP System  Docker & Microservices Interests Founder @ Teamcrop.com
  • 3. Why log management? • System troubleshooting • Application debugging • Performance optimization • Security • Business decision making
  • 4. Type of Logs • Business – Auditing – Feature Usage – Critical Function • Operation – Operating System – General – API Request – SQL Query – Distributed Tracing
  • 5. Abstract Logging Design Storage Collecto r Dashboard Syslog PHP Log Nginx Log Access Log Error Log Activity Log … PHP React JS Grafana File Syslog RabbitMQ MySQL Clickhouse
  • 6. Anatomy of a Service @Teamcrop Host (Linux) Service Container (Docker) Web Server (Nginx) + PHP Application Request (eg: order) SQL Query 1 SQL Query 2 Call another services request (Eg: customer, cashflow…) OS log Syslog Access, Error log API Request, Audit… SQL Query log Distributed tracing
  • 8. 1.1. Auditing Log • Metrics: – Employee – Service – Section (controller) – Action (add, update, delete, import..) – Severity – Change log – IP Address
  • 9. 1.1. Store Auditing Log Audit Log Message Queue (RabbitMQ) Queue Worker (PHP) Teamcrop API (PHP) Teamcrop Log (MySQL)
  • 10. 1.1. View Auditing Log Teamcrop Audit Log API (PHP) Teamcrop Log (MySQL) Dashboard (React JS) Request Query
  • 11. 1.1. Auditing Log Stack • Collector – PHP • Storage – MySQL • Dashboard – React JS
  • 12. 1.1. Auditing Log Example
  • 13. 1.1. Auditing Log Example (cont.)
  • 14. 1.2. Feature Usage Log • Metrics: – Visitor – Page View – Time on Page – Technology – … • Stack: – Google Analytics – Self-hosted application
  • 15. 1.2. Feature Usage Log Example
  • 16. 1.3. Critical Function Log • Metrics: – Raw POST data • Stack: – Collector: PHP – Storage: File System – Dashboard: React JS
  • 17. 1.3. Critical Function Log Example
  • 19. 2.1. Operating System Log • Metrics: – Memory (RAM) – CPU – Disk – Network – … • Stack: – NodeQuery.com
  • 20. 2.1. Operating System Log Example
  • 21. 2.1. Operating System Log Example (cont.)
  • 22. 2.1. Operating System Log Example (cont.)
  • 23. 2.2. General Log • Metrics: – PHP: error, warning… – Nginx: access, error… – Custom Log Message – Cronjob Log – Queue Log – Others
  • 24. 2.2. Store General Log General Log (Access, Error Log) Syslog (syslog-ng) UDP UDP Log Server (PHP) Message Queue (RabbitMQ) UDP Log Worker (PHP) Clickhouse (Syslog Table)
  • 25. 2.2. View General Log Teamcrop Analytics API (PHP) Clickhouse (Syslog Table) Dashboard (React JS) Request Query
  • 26. 2.2. General Log Stack • Collector: – Syslog-ng • Storage: – RabbitMQ (Queue) – Clickhouse • Dashboard: – PHP – React JS
  • 27. 2.2. General Log Example
  • 28. 2.2. General Log Example (cont.)
  • 29. 2.3. API Request Log • Metrics: – HTTP Status – HTTP Method – Tenant – Service name – Function (controller, action) – Execution time – Memory – Source – …
  • 30. 2.3. Store API Request Log API Request Log Syslog (syslog-ng) UDP UDP Log Server (PHP) Message Queue (RabbitMQ) UDP Log Worker (PHP)Clickhouse
  • 31. 2.3. View API Request Log Teamcrop Analytics API (PHP) Clickhouse (API Request Log Table) Dashboard (React JS) Request Query Grafana UI Grafana API Request Query
  • 32. 2.3. API Request Log Stack • Collector: – Syslog-ng – Monolog (PHP) • Storage: – RabbitMQ (Queue) – Clickhouse • Dashboard: – PHP – React JS – Grafana
  • 33. 2.3. API Request Log Example
  • 34. 2.3. API Request Log Example (cont.)
  • 35. 2.3. API Request Log Example (cont.)
  • 36. 2.3. API Request Log Example (cont.)
  • 37. 2.4. SQL Query Log • Metrics: – Replication – Table – Query type (SELECT, INSERT…) – Execution – Tenant – …
  • 38. 2.4. Store SQL Query Log SQL Query Log Syslog (syslog-ng) UDP UDP Log Server (PHP) Message Queue (RabbitMQ) UDP Log Worker (PHP)Clickhouse
  • 39. 2.4. View SQL Query Log Teamcrop Analytics API (PHP) Clickhouse (SQL Query Log Table) Dashboard (React JS) Request Query Grafana UI Grafana API Request Query
  • 40. 2.4. SQL Query Log Stack • Collector: – Syslog-ng – Monolog (PHP) • Storage: – RabbitMQ (Queue) – Clickhouse • Dashboard: – PHP – React JS – Grafana
  • 41. 2.4. SQL Query Log Example
  • 42. 4. SQL Query Log Example (cont.)
  • 43. 4. SQL Query Log Example (cont.)
  • 44. 2.5. Distributed Tracing Log • Metrics: – Chain of requests – Duration – Execution – Tenant – Service – …
  • 45. 2.5. Store Distributed Tracing Log OpenTracing Log (ZipKin format) Syslog (syslog-ng) UDP UDP Log Server (PHP) Message Queue (RabbitMQ) UDP Log Worker (PHP) Jaeger API Jaeger DB
  • 46. 2.5. Distributed Tracing Log Stack • Collector: – Syslog-ng – Monolog (PHP) – Zipkin Client Library (PHP) • Storage: – RabbitMQ (Queue) – Jaeger • Dashboard: – Jaeger UI
  • 47. 2.5. Distributed Tracing Model • OpenTracing Specification
  • 49. DEMO RabbitMQ Jeager UI Clickhouse GUI Client Customized Log Dashboard NodeQuery Grafana Teamcrop Log Audit