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 PHP applications
Search
Mariusz Gil
May 05, 2014
Programming
300
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Monitoring PHP applications
Talk from local meetup.
Mariusz Gil
May 05, 2014
More Decks by Mariusz Gil
See All by Mariusz Gil
Aspect Oriented Programming
mariuszgil
1
350
Designing and implementing GraphQL API
mariuszgil
1
120
Discovering unknown with EventStorming ConFoo
mariuszgil
0
330
Game of Developer Life... Deconstructed
mariuszgil
1
200
Back to forgotten roots
mariuszgil
1
450
Go micro with microservices
mariuszgil
5
720
Machine Learning for the rescue
mariuszgil
0
460
Discovering graph structures
mariuszgil
3
570
Introduction to Aerospike with PHP
mariuszgil
8
880
Other Decks in Programming
See All in Programming
XP祭りでしか伝わらないフリップネタ #xpjug
murabayashi
0
110
GKE で Pod の見方を変えたら、スケールアウト時の挙動を真に捉えられた話
stkk
0
100
書籍「プロフェッショナルAI駆動開発」紹介スライド
juntaromatsumoto
0
1k
AIの中の人になってみる
htkym
0
170
20260828_品質と開発生産性を両立させる、AI時代のE2Eテストの考え方
magicpod
0
160
まずはプロンプトガイドを読もう、話はそれからだ
kiakiraki
1
260
Swift愛好会100回記念 第1回を振り返る
jollyjoester
0
120
Oxlintはいいぞ(続)
yug1224
1
560
業務時間外もAIに働いてもらう話
colorful12
3
10k
初めての模倣学習とVLA
natsutan
0
500
Building an Out-of-Order CPU
latte72
1
710
思考垂れ流し開発 ~音声入力 × AIエージェント × 開発ハーネスによる試行錯誤~
npostring
0
920
Featured
See All Featured
How Software Deployment tools have changed in the past 20 years
geshan
1
34k
What Being in a Rock Band Can Teach Us About Real World SEO
427marketing
0
1.1k
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
1
310
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
590
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
770
Designing for humans not robots
tammielis
254
26k
Primal Persuasion: How to Engage the Brain for Learning That Lasts
tmiket
0
440
Un-Boring Meetings
codingconduct
0
410
Building Flexible Design Systems
yeseniaperezcruz
330
41k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
201
76k
HDC tutorial
michielstock
2
850
The Mindset for Success: Future Career Progression
greggifford
PRO
0
490
Transcript
MONITORING PHP APPS with metrics Mariusz Gil
None
architecture
backend mods
devops
sexy frontend
business logic
technology
the client
None
life guard
monitoring and the answer is…
fast deployment low price strength and power
None
None
graphite even better monitoring
carbon whisper web app
carbon whisper web app metrics data charts
carbon app metrics servers metrics
carbon backtop bucky collectd diamond evenflow ganglia graphios grockets hoardid
host sflow jmxtrans logster sensu statsd statsite
web app
php lang? what about
None
$log = new \StatsD\Client(! ! [$host=‚localhost']! ! [, $port=8125]! );
$log->start($stat);! $log->stop($stat [, $sampleRate]);
$log->timing($stat, $time [, $sampleRate]);!
$log->increment($stat [, $sampleRate]);! $log->decrement($stat [, $sampleRate]);
$log->gauge($stat, $val, [, $sampleRate]);!
None
None
<?php ! $cache =
apc_cache_info(); $cache_user = apc_cache_info('user', 1); $mem = apc_sma_info(); ! $stats = array( "mem"=>array( "segments" => (int)$mem['num_seg'], "segment_size" => (int)$mem['seg_size'], "total" => (int)$mem['num_seg'] * $mem['seg_size'], ), "opcode"=>array( "files_count" => (int)$cache['num_entries'], "files_size" => (int)$cache['mem_size'], "hits" => (int)$cache['num_hits'], "misses" => (int)$cache['num_misses'], "full_count" => (int)$cache['expunges'], ), "user"=>array( "vars_count" => (int)$cache_user['num_entries'], "vars_size" => (int)$cache_user['mem_size'], "hits" => (int)$cache_user['num_hits'], "misses" => (int)$cache_user['num_misses'], "full_count" => (int)$cache_user['expunges'], ), ); ! echo json_encode($stats);
app logs? metrics from
None
app server app server mobile apps
mobile apps app server app server fluentd php php
<?php! ! // you can choose your own AutoLoader! require_once
__DIR__.'/src/Fluent/Autoloader.php';! ! use Fluent\Logger\FluentLogger;! ! Fluent\Autoloader::register();! ! $logger = new FluentLogger("localhost","24224");! $logger->post("debug.test",array("hello"=>"world"));!
app server app server fluentd php php graphite logster mobile
apps
None
THANKS! @mariuszgil