Enviar búsqueda
Cargar
Anatomy of a PHP Request ( UTOSC 2010 )
•
Descargar como KEY, PDF
•
1 recomendación
•
1,861 vistas
J
Joseph Scott
Seguir
Tecnología
Denunciar
Compartir
Denunciar
Compartir
1 de 40
Descargar ahora
Recomendados
Key features PHP 5.3 - 5.6
Key features PHP 5.3 - 5.6
Federico Damián Lozada Mosto
The why and how of moving to PHP 5.5/5.6
The why and how of moving to PHP 5.5/5.6
Wim Godden
How to deploy node to production
How to deploy node to production
Sean Hess
The why and how of moving to PHP 5.4/5.5
The why and how of moving to PHP 5.4/5.5
Wim Godden
Joy of Six - Discover the Joy of Perl 6
Joy of Six - Discover the Joy of Perl 6
trexy
The why and how of moving to php 5.4
The why and how of moving to php 5.4
Wim Godden
Caching and tuning fun for high scalability @ FrOSCon 2011
Caching and tuning fun for high scalability @ FrOSCon 2011
Wim Godden
Yapcasia2011 - Hello Embed Perl
Yapcasia2011 - Hello Embed Perl
Hideaki Ohno
Recomendados
Key features PHP 5.3 - 5.6
Key features PHP 5.3 - 5.6
Federico Damián Lozada Mosto
The why and how of moving to PHP 5.5/5.6
The why and how of moving to PHP 5.5/5.6
Wim Godden
How to deploy node to production
How to deploy node to production
Sean Hess
The why and how of moving to PHP 5.4/5.5
The why and how of moving to PHP 5.4/5.5
Wim Godden
Joy of Six - Discover the Joy of Perl 6
Joy of Six - Discover the Joy of Perl 6
trexy
The why and how of moving to php 5.4
The why and how of moving to php 5.4
Wim Godden
Caching and tuning fun for high scalability @ FrOSCon 2011
Caching and tuning fun for high scalability @ FrOSCon 2011
Wim Godden
Yapcasia2011 - Hello Embed Perl
Yapcasia2011 - Hello Embed Perl
Hideaki Ohno
The why and how of moving to php 5.4/5.5
The why and how of moving to php 5.4/5.5
Wim Godden
Perl IO
Perl IO
guest998254
Debugging: Rules & Tools
Debugging: Rules & Tools
Ian Barber
An introduction to PHP 5.4
An introduction to PHP 5.4
Giovanni Derks
2016年のPerl (Long version)
2016年のPerl (Long version)
charsbar
Php in 2013 (Web-5 2013 conference)
Php in 2013 (Web-5 2013 conference)
julien pauli
Kansai.pm 10周年記念 Plack/PSGI 入門
Kansai.pm 10周年記念 Plack/PSGI 入門
lestrrat
Smolder @Silex
Smolder @Silex
Jeen Lee
Publishing a Perl6 Module
Publishing a Perl6 Module
ast_j
Hachiojipm11
Hachiojipm11
Hideaki Ohno
Quick tour of PHP from inside
Quick tour of PHP from inside
julien pauli
The new features of PHP 7
The new features of PHP 7
Zend by Rogue Wave Software
Zend Framework Study@Tokyo #2
Zend Framework Study@Tokyo #2
Shinya Ohyanagi
Working with databases in Perl
Working with databases in Perl
Laurent Dami
Phpをいじり倒す10の方法
Phpをいじり倒す10の方法
Moriyoshi Koizumi
On UnQLite
On UnQLite
charsbar
Better detection of what modules are used by some Perl 5 code
Better detection of what modules are used by some Perl 5 code
charsbar
Zend con 2016 - Asynchronous Prorgamming in PHP
Zend con 2016 - Asynchronous Prorgamming in PHP
Adam Englander
Vladimir Vorontsov - Splitting, smuggling and cache poisoning come back
Vladimir Vorontsov - Splitting, smuggling and cache poisoning come back
DefconRussia
Is your code ready for PHP 7 ?
Is your code ready for PHP 7 ?
Wim Godden
Debugging: Rules And Tools - PHPTek 11 Version
Debugging: Rules And Tools - PHPTek 11 Version
Ian Barber
第1回PHP拡張勉強会
第1回PHP拡張勉強会
Ippei Ogiwara
Más contenido relacionado
La actualidad más candente
The why and how of moving to php 5.4/5.5
The why and how of moving to php 5.4/5.5
Wim Godden
Perl IO
Perl IO
guest998254
Debugging: Rules & Tools
Debugging: Rules & Tools
Ian Barber
An introduction to PHP 5.4
An introduction to PHP 5.4
Giovanni Derks
2016年のPerl (Long version)
2016年のPerl (Long version)
charsbar
Php in 2013 (Web-5 2013 conference)
Php in 2013 (Web-5 2013 conference)
julien pauli
Kansai.pm 10周年記念 Plack/PSGI 入門
Kansai.pm 10周年記念 Plack/PSGI 入門
lestrrat
Smolder @Silex
Smolder @Silex
Jeen Lee
Publishing a Perl6 Module
Publishing a Perl6 Module
ast_j
Hachiojipm11
Hachiojipm11
Hideaki Ohno
Quick tour of PHP from inside
Quick tour of PHP from inside
julien pauli
The new features of PHP 7
The new features of PHP 7
Zend by Rogue Wave Software
Zend Framework Study@Tokyo #2
Zend Framework Study@Tokyo #2
Shinya Ohyanagi
Working with databases in Perl
Working with databases in Perl
Laurent Dami
Phpをいじり倒す10の方法
Phpをいじり倒す10の方法
Moriyoshi Koizumi
On UnQLite
On UnQLite
charsbar
Better detection of what modules are used by some Perl 5 code
Better detection of what modules are used by some Perl 5 code
charsbar
Zend con 2016 - Asynchronous Prorgamming in PHP
Zend con 2016 - Asynchronous Prorgamming in PHP
Adam Englander
Vladimir Vorontsov - Splitting, smuggling and cache poisoning come back
Vladimir Vorontsov - Splitting, smuggling and cache poisoning come back
DefconRussia
Is your code ready for PHP 7 ?
Is your code ready for PHP 7 ?
Wim Godden
La actualidad más candente
(20)
The why and how of moving to php 5.4/5.5
The why and how of moving to php 5.4/5.5
Perl IO
Perl IO
Debugging: Rules & Tools
Debugging: Rules & Tools
An introduction to PHP 5.4
An introduction to PHP 5.4
2016年のPerl (Long version)
2016年のPerl (Long version)
Php in 2013 (Web-5 2013 conference)
Php in 2013 (Web-5 2013 conference)
Kansai.pm 10周年記念 Plack/PSGI 入門
Kansai.pm 10周年記念 Plack/PSGI 入門
Smolder @Silex
Smolder @Silex
Publishing a Perl6 Module
Publishing a Perl6 Module
Hachiojipm11
Hachiojipm11
Quick tour of PHP from inside
Quick tour of PHP from inside
The new features of PHP 7
The new features of PHP 7
Zend Framework Study@Tokyo #2
Zend Framework Study@Tokyo #2
Working with databases in Perl
Working with databases in Perl
Phpをいじり倒す10の方法
Phpをいじり倒す10の方法
On UnQLite
On UnQLite
Better detection of what modules are used by some Perl 5 code
Better detection of what modules are used by some Perl 5 code
Zend con 2016 - Asynchronous Prorgamming in PHP
Zend con 2016 - Asynchronous Prorgamming in PHP
Vladimir Vorontsov - Splitting, smuggling and cache poisoning come back
Vladimir Vorontsov - Splitting, smuggling and cache poisoning come back
Is your code ready for PHP 7 ?
Is your code ready for PHP 7 ?
Similar a Anatomy of a PHP Request ( UTOSC 2010 )
Debugging: Rules And Tools - PHPTek 11 Version
Debugging: Rules And Tools - PHPTek 11 Version
Ian Barber
第1回PHP拡張勉強会
第1回PHP拡張勉強会
Ippei Ogiwara
Living With Legacy Code
Living With Legacy Code
Rowan Merewood
Security in PHP - 那些在滲透測試的小技巧
Security in PHP - 那些在滲透測試的小技巧
Orange Tsai
Orange@php conf
Orange@php conf
Hash Lin
Tips
Tips
mclee
PHP5.5 is Here
PHP5.5 is Here
julien pauli
GettingStartedWithPHP
GettingStartedWithPHP
Nat Weerawan
Php101
Php101
Ömer Taşkın
DevOps in PHP environment
DevOps in PHP environment
Evaldo Felipe
The new features of PHP 7 - Enrico Zimuel - Codemotion Milan 2016
The new features of PHP 7 - Enrico Zimuel - Codemotion Milan 2016
Codemotion
PHP & Performance
PHP & Performance
毅 吕
What's new with PHP7
What's new with PHP7
SWIFTotter Solutions
php & performance
php & performance
simon8410
Prepare for PHP Test Fest 2009
Prepare for PHP Test Fest 2009
PHPBelgium
Site Performance - From Pinto to Ferrari
Site Performance - From Pinto to Ferrari
Joseph Scott
Php.ppt
Php.ppt
Nidhi mishra
Php 7 evolution
Php 7 evolution
Félix Gómez López
Wt unit 4 server side technology-2
Wt unit 4 server side technology-2
PUNE VIDYARTHI GRIHA'S COLLEGE OF ENGINEERING, NASHIK
Revoke-Obfuscation
Revoke-Obfuscation
Daniel Bohannon
Similar a Anatomy of a PHP Request ( UTOSC 2010 )
(20)
Debugging: Rules And Tools - PHPTek 11 Version
Debugging: Rules And Tools - PHPTek 11 Version
第1回PHP拡張勉強会
第1回PHP拡張勉強会
Living With Legacy Code
Living With Legacy Code
Security in PHP - 那些在滲透測試的小技巧
Security in PHP - 那些在滲透測試的小技巧
Orange@php conf
Orange@php conf
Tips
Tips
PHP5.5 is Here
PHP5.5 is Here
GettingStartedWithPHP
GettingStartedWithPHP
Php101
Php101
DevOps in PHP environment
DevOps in PHP environment
The new features of PHP 7 - Enrico Zimuel - Codemotion Milan 2016
The new features of PHP 7 - Enrico Zimuel - Codemotion Milan 2016
PHP & Performance
PHP & Performance
What's new with PHP7
What's new with PHP7
php & performance
php & performance
Prepare for PHP Test Fest 2009
Prepare for PHP Test Fest 2009
Site Performance - From Pinto to Ferrari
Site Performance - From Pinto to Ferrari
Php.ppt
Php.ppt
Php 7 evolution
Php 7 evolution
Wt unit 4 server side technology-2
Wt unit 4 server side technology-2
Revoke-Obfuscation
Revoke-Obfuscation
Más de Joseph Scott
Scaling WordPress
Scaling WordPress
Joseph Scott
Site Testing with CasperJS
Site Testing with CasperJS
Joseph Scott
Python & FUSE
Python & FUSE
Joseph Scott
Improving Front End Performance
Improving Front End Performance
Joseph Scott
WordPress Performance & Scalability
WordPress Performance & Scalability
Joseph Scott
WordPress APIs
WordPress APIs
Joseph Scott
WordPress Performance & Scalability
WordPress Performance & Scalability
Joseph Scott
WordPress APIs
WordPress APIs
Joseph Scott
Más de Joseph Scott
(8)
Scaling WordPress
Scaling WordPress
Site Testing with CasperJS
Site Testing with CasperJS
Python & FUSE
Python & FUSE
Improving Front End Performance
Improving Front End Performance
WordPress Performance & Scalability
WordPress Performance & Scalability
WordPress APIs
WordPress APIs
WordPress Performance & Scalability
WordPress Performance & Scalability
WordPress APIs
WordPress APIs
Último
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Orbitshub
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
Dropbox
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
apidays
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
Remote DBA Services
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Angeliki Cooney
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
sudhanshuwaghmare1
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Deepika Singh
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
Sandro Moreira
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Jeffrey Haguewood
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
ThousandEyes
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
apidays
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Juan lago vázquez
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
Product Anonymous
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Edi Saputra
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
apidays
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
apidays
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
The Digital Insurer
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Victor Rentea
Último
(20)
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Mcleodganj Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Finding Java's Hidden Performance Traps @ DevoxxUK 2024
Anatomy of a PHP Request ( UTOSC 2010 )
1.
Blank Slide
2.
This one too
3.
One for the
road
4.
Anatomy of a
PHP Request Joseph Scott 7 Oct 2010 UTOSC
5.
Rules of Engagement
6.
Lifespan .php Read
Parse Compile Execute Output
7.
Lifespan .php Read
Parse Compile Execute Output Apache / mod_php
8.
Lifespan .php Read
Parse Compile Execute Output FastCGI Nginx
9.
Reading Open
Read Close
10.
Reading Open
Read Close Avoid co$tly services like NFS
11.
Parse hello.php
<?php echo "Hello, World!n" Parse error: syntax error, unexpected $end, expecting ',' or ';' in /tmp/hello.php on line 3
12.
Tokens
<?php echo $tokens = token_get_all( ' "Hello, World!";' ); foreach ( $tokens as $token ) { if ( is_array( $token ) ) { echo token_name( $token[0] ) . " ( {$token[2]} ) - {$token[1]}n"; } else { echo "{$token}n"; } }
13.
Tokens T_OPEN_TAG ( 1
) - <?php T_ECHO ( 1 ) - echo T_WHITESPACE ( 1 ) - T_CONSTANT_ENCAPSED_STRING ( 1 ) - "Hello, World!" ;
14.
Compile Branch analysis from
position: 0 Return found filename: /tmp/hello.php function name: (null) number of ops: 3 compiled vars: none line # op fetch ext return operands ------------------------------------------------------------------------------- 2 0 ECHO 'Hello%2C+World%21%0A' 3 1 RETURN 1 2* ZEND_HANDLE_EXCEPTION
15.
Execute Deceptively Simple Term •Includes
all sorts of activity •Database / remote requests
16.
Output •PHP can buffer
output •Don’t forget about compression
17.
Making Things Faster
18.
Making Things Faster Less
work, for the same result = awesome
19.
Making Things Faster .php Read
Parse Compile Execute Output
20.
Making Things Faster .php Read
APC Parse Compile Execute Output
21.
Making Things Faster .php Read
APC Parse Compile Execute Output opcode cache
22.
HipHop for PHP •
Open source code translator from Facebook • Converts PHP into c++ • Single binary with built in web server • http://github.com/facebook/hiphop-php/
23.
HipHop for PHP
How much faster?
24.
HipHop for PHP
How much faster? Depends (of course)
25.
Measuring Tape for
Programmers
26.
Measuring Tape for
Programmers Xdebug can provide TONS of information http://xdebug.org/
27.
Xdebug Profiler •Generates cachegrind
output ➡KCachegrind ➡webgrind ➡MacCallGrind ➡WinCacheGrind ➡Valgrind
28.
Kcachegrind
29.
webgrind
30.
XHProf
31.
XHProf Call Graph
32.
XHProf Diff
33.
The PHP Point
of View opcodes VLD - Vulcan Logic Dumper
34.
Example PHP $html =
file_get_contents( 'http://www.google.com/' ); $regex_pattern = '!<a href="[^>]*">(.*?)</a>!'; preg_match_all( $regex_pattern, $html, $matches );
35.
Example PHP -
VLD Branch analysis from position: 0 Return found filename: /drive/home/joseph/vld/parse-links.php function name: (null) number of ops: 17 compiled vars: !0 = $html, !1 = $regex_pattern, !2 = $matches
36.
Example PHP -
VLD line # op fetch ext return operands ------------------------------------------------------------------------------- 4 0 EXT_STMT 1 EXT_FCALL_BEGIN 2 SEND_VAL 'http%3A%2F%2Fwww.google.com%2F' 3 DO_FCALL 1 'file_get_contents' 4 EXT_FCALL_END 5 ASSIGN !0, $0 5 6 EXT_STMT 7 ASSIGN !1, '%21%3Ca+href%3D%22%5B%5E%3E %5D%2A%22%3E%28.%2A%3F%29%3C%2Fa%3E%21' 6 8 EXT_STMT 9 EXT_FCALL_BEGIN 10 SEND_VAR !1 11 SEND_VAR !0 12 SEND_REF !2 13 DO_FCALL 3 'preg_match_all' 14 EXT_FCALL_END 7 15 RETURN 1 16* ZEND_HANDLE_EXCEPTION
37.
PHP - strace •
System calls, expect LOTS of data • strace -o out php parse-links.php
38.
PHP - strace •
System calls, expect LOTS of data • strace -o out php parse-links.php 1,500+ lines of output!
39.
1.
PHP - strace socket(PF_INET, SOCK_STREAM, IPPROTO_IP) = 3 2. fcntl64(3, F_GETFL) = 0x2 (flags O_RDWR) 3. fcntl64(3, F_SETFL, O_RDWR|O_NONBLOCK) = 0 4. connect(3, {sa_family=AF_INET, sin_port=htons(80), sin_addr=inet_addr("64.233.169.99")}, 16) = -1 EINPROGRESS (Operation now in progress) 5. poll([{fd=3, events=POLLIN|POLLOUT|POLLERR|POLLHUP}], 1, 60000) = 1 ([{fd=3, revents=POLLOUT}]) 6. getsockopt(3, SOL_SOCKET, SO_ERROR, [0], [4]) = 0 7. fcntl64(3, F_SETFL, O_RDWR) = 0 8. send(3, "GET / HTTP/1.0rn", 16, MSG_DONTWAIT) = 16 9. send(3, "Host: www.google.comrn", 22, MSG_DONTWAIT) = 22 10.send(3, "rn", 2, MSG_DONTWAIT) = 2 11.poll([{fd=3, events=POLLIN|POLLPRI|POLLERR|POLLHUP}], 1, 0) = 0 (Timeout) 12.poll([{fd=3, events=POLLIN|POLLERR|POLLHUP}], 1, 60000) = 1 ([{fd=3, revents=POLLIN}]) 13.recv(3, "HTTP/1.0 200 OKrnDate: Tue, 13 A"..., 8192, MSG_DONTWAIT) = 4636 14.poll([{fd=3, events=POLLIN|POLLERR|POLLHUP}], 1, 60000) = 1 ([{fd=3, revents=POLLIN}]) 15.recv(3, "is) class=gb2>Blogs</a> <div cla"..., 8192, MSG_DONTWAIT) = 4290 16.poll([{fd=3, events=POLLIN|POLLERR|POLLHUP}], 1, 60000) = 1 ([{fd=3, revents=POLLIN}]) 17.recv(3, "", 8192, MSG_DONTWAIT) = 0 18.poll([{fd=3, events=POLLIN|POLLERR|POLLHUP}], 1, 60000) = 1 ([{fd=3, revents=POLLIN}]) 19.recv(3, "", 8192, MSG_DONTWAIT) = 0 20.close(3) = 0
40.
Live Demo Time
Notas del editor
Descargar ahora