Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Monitoring & Profiling at ResearchGate
Search
Bastian Hofmann
November 30, 2016
Programming
280
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Monitoring & Profiling at ResearchGate
Bastian Hofmann
November 30, 2016
More Decks by Bastian Hofmann
See All by Bastian Hofmann
Monitoring in Kubernetes with Prometheus and Grafana
bastianhofmann
0
360
Creating a fast Kubernetes Development Workflow
bastianhofmann
0
150
Highly available cross-region deployments with Kubernetes
bastianhofmann
1
170
From source to Kubernetes in 30 minutes
bastianhofmann
0
200
Introduction to Kubernetes
bastianhofmann
1
140
CI/CD with Kubernetes
bastianhofmann
0
250
Creating a fast Kubernetes Development Workflow
bastianhofmann
1
290
Deploying your first Micro-Service application to Kubernetes
bastianhofmann
2
210
Creating a fast Kubernetes Development Workflow
bastianhofmann
0
280
Other Decks in Programming
See All in Programming
継続モナドとリアクティブプログラミング
yukikurage
3
620
act2-costs.pdf
sumedhbala
0
120
なぜ型を書くのか? TSKaigi2026で改めて考える #tskaigi_smarthr
kajitack
0
400
1年で人数1.5倍、PR数5.5倍増。 品質とアウトカムはどうなったか、 何が効いたか
ike002jp
0
140
GitHubCopilotCLIのスラッシュコマンドを自作してみる
htkym
0
100
生成AI導入の「期待外れ」を乗り越える ー 開発フロー改革が目指す、真の組織変革
starfish719
0
1.6k
共通化で考えるべきは、実装より公開する型だった
codeegg
0
270
ルールを書いて終わらせないハーネスエンジニアリング
yug1224
4
1.7k
なぜ関数型プログラミングで「型」と「証明」が語られるのか #fp_matsuri
kajitack
3
1k
Terraform標準の組織で AWS CDKをどう使うか
mu7889yoon
1
330
PHP初心者セッション2026 〜生成AIでは見えない裏側を知る:今だからLAMPを通して仕組みを学ぶ〜
kashioka
0
620
FDEが実現するAI駆動経営の現在地
gonta
2
190
Featured
See All Featured
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.5k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4.1k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
11
970
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.4k
Visualization
eitanlees
152
17k
Agile that works and the tools we love
rasmusluckow
331
22k
New Earth Scene 8
popppiees
3
2.4k
Noah Learner - AI + Me: how we built a GSC Bulk Export data pipeline
techseoconnect
PRO
0
330
Jamie Indigo - Trashchat’s Guide to Black Boxes: Technical SEO Tactics for LLMs
techseoconnect
PRO
0
510
Speed Design
sergeychernyshev
33
1.9k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
333
23k
Transcript
Monitoring and Profiling at ResearchGate @BastianHofmann
None
http://www.alexa.com/
11 million users
193 countries
~1800 request/s
lots of data
>100 million publications
~ 140 components
~ 400 repositories
haproxy node memcache postgresql mongodb solr infinispan hbase mongodb solr
community services
+ async events, stream and batch processing
We need to know whats going on
Monitoring
Logging
Profiling
Real-Time
Many roads
None
Logging
Error Logs
Access Logs
Enrich with additional information
We turn Notices, Warnings, Errors into Exceptions
set_error_handler( function($errno, $msg, $file, $line) { switch ($errno) { case
E_RECOVERABLE_ERROR: case E_USER_ERROR: throw new \ErrorException($msg, null, $errno, $file, $line); case E_WARNING: case E_USER_WARNING: case E_CORE_WARNING: case E_COMPILE_WARNING: throw new WarningException($msg, null, $errno, $file, $line); case E_NOTICE: case E_USER_NOTICE: throw new NoticeException($msg, null, $errno, $file, $line); case E_STRICT: throw new StrictException($msg, null, $errno, $file, $line); } return true; }); $a = []; try { $b = $a['doesNotExist']; } catch (NoticeException $e) { }
Log as JSON
Correlation with logs from other services
web server http service http service http service http service
create unique trace_id for request user request trace_id trace_id trace_id trace_id log log log log log
None
Central log management
Aggregated in a central place
Easily full-text searchable
Always Log to file
Logstash + Elasticsearch + Kibana
Logstash elasticsearch webserver webserver webserver AMQP log log log logstash
logstash logstash
Kibana http://www.elasticsearch.org/overview/kibana/
None
Monitoring
Graphite http://graphite.wikidot.com/
None
StatsD https://github.com/etsy/statsd/
webserver webserver webserver statsd statsd statsd graphite
What do we measure?
Business Metrics
Technical Metrics
Error rates
Database Queries
HTTP calls
Cache access
Rendering time
…
Response Times
Easiest approach: Get it out of the access log
192.168.56.1 - - [09/Jul/2012:19:18:19 +0200] "GET /rg_trunk/webroot/c/af10c/ images/template/rg_logo_default.png HTTP/ 1.1"
200 882 "http://devm/rg_trunk/webroot/ directory/publications/"
Or measure it in your PHP process
Is this actually what we want to measure?
http://www.stevesouders.com/blog/2012/02/10/the-performance-golden-rule/
None
None
None
Navigation Timing API https://developer.mozilla.org/en-US/docs/ Navigation_timing
None
Profiling
XHProf with tideways.io Extension https://github.com/tideways/php-profiler-extension
XHGUI https://github.com/perftools/xhgui
None
None
None
None
Active in production for a subset of requests
Symfony Debug Toolbar
None
None
Extend it http://symfony.com/doc/current/cookbook/profiler/ data_collector.html
None
None
None
None
None
Active in production for a subset of requests
Alerts
None
Dashboards
None
None
None
None
http://twitter.com/BastianHofmann http://profiles.google.com/bashofmann http://lanyrd.com/people/BastianHofmann http://speakerdeck.com/u/bastianhofmann https://github.com/bashofmann https://www.researchgate.net/profile/Bastian_Hofmann/
[email protected]