SlideShare ist ein Scribd-Unternehmen logo
1 von 36
Downloaden Sie, um offline zu lesen
CDN	
  &	
  Cloud
Junho	
  Choi	
  <junho.choi@cdnetworks.com>	
  
CDNetworks	
  h7p://www.cdnetworks.com	
  
rev.	
  3
Who	
  am	
  I?

    Junho	
  Choi	
  (         )	
  
    CTO/APAC,	
  VP	
  of	
  Engineering	
  |	
  CDNetworks	
  hAp://www.cdnetworks.com	
  
    FreeBSD	
  CommiAer(ports)	
  (cjh@freebsd.org,	
  2001-­‐2010)	
  
    Korea	
  FreeBSD	
  Users	
  Group	
  hAp://www.kr.freebsd.org	
  since	
  1999	
  
    TwiAer:	
  junhochoi	
  




                                        PHPFest	
  2011	
                                  2	
  
Contents

    CDN	
  –	
  what	
  problem	
  to	
  solve	
  
    Technology	
  in	
  CDN	
  
    How	
  to	
  uZlize	
  CDN/Cache	
  using	
  PHP	
  
    Cloud	
  CompuZng	
  &	
  CDN




                                                PHPFest	
  2011	
     3	
  
A	
  typical	
  web	
  site	
  

  You	
  built	
  a	
  fancy	
  web	
  site!	
  
  As	
  your	
  website	
  is	
  ge_ng	
  popular,	
  you	
  are	
  ge_ng	
  more	
  and	
  more	
  traffic.	
  
  Your	
  website	
  will	
  be	
  slow	
  when	
  more	
  users	
  visit.	
  
  Your	
  website	
  will	
  be	
  slow	
  when	
  users	
  from	
  other	
  countries	
  visit.	
  
  Your	
  website	
  can	
  be	
  down	
  due	
  to	
  hardware	
  failure,	
  network	
  failure.	
  
  Your	
  website	
  will	
  be	
  down	
  when	
  there	
  is	
  a	
  spike	
  of	
  traffic	
  because	
  your	
  we
   bsite	
  is	
  suddenly	
  popular	
  on	
  famous	
  news	
  site,	
  twiAer,	
  slashdot,	
  facebook	
  
   etc.	
  
  Your	
  website	
  is	
  not	
  scalable	
  when	
  you	
  want	
  to	
  expand	
  more	
  
  You	
  want	
  to	
  have	
  a	
  streaming	
  video	
  on	
  your	
  website	
  but	
  don’t	
  want	
  to	
  bu
   y	
  a	
  license	
  for	
  commercial	
  streaming	
  soluZon	
  such	
  as	
  Flash	
  Media	
  or	
  Wind
   ows	
  Media.	
  
  …



                                                  PHPFest	
  2011	
                                                 4	
  
Content	
  Delivery	
  Network

  Problem	
  to	
  solve	
  
      •  Network	
  Distance	
  
      •  Reliability	
  
      •  Scalability	
  




                                   PHPFest	
  2011	
     5	
  
Problem	
  to	
  Solve	
  –	
  Network	
  Distance

  Middle	
  Mile	
  Problem



             EMEA
             HQ

                                                                           End-user



       “Origin	
  Server”	
  
       Customer’s	
  web	
  site




              First	
  Mile	
             Middle	
  Mile	
        Last	
  Mile	
  
          Same	
  Data	
  Center	
       Bad Routing            Same	
  LocaZon	
  
              Same	
  ISP	
                                        Same	
  ISP	
  
                                       Network Failure            Low	
  latency	
  
             Low	
  latency	
  
           High	
  Bandwidth            Long distance           Low	
  Bandwidth	
  

                                          PHPFest	
  2011	
                            6	
  
Problem	
  to	
  Solve	
  –	
  Network	
  Distance



                                                                                “Edge	
  Server”	
  
                                                                                CDN	
  Cache

             EMEA
             HQ

                                                                                                  End-user



       “Origin	
  Server”	
  
       Customer’s	
  web	
  site




             First	
  Mile              Middle	
  Mile                                  Last	
  Mile
                                                      Place	
  edge	
  (caching	
  or	
  mirroring)	
  server	
  on	
  
                                                      nearest	
  locaZon	
  to	
  end	
  user


                                        PHPFest	
  2011	
                                                                 7	
  
Problem	
  to	
  Solve	
  –	
  Reliability




             EMEA
             HQ

                                                                                                         End-user




              First	
  Mile                  Middle	
  Mile                                   Last	
  Mile
                                                               SZll	
  able	
  to	
  access	
  on	
  CDN	
  Edge	
  server



                                             PHPFest	
  2011	
                                                               8	
  
Problem	
  to	
  Solve	
  –	
  Scalability




             EMEA
             HQ




                                                                                                                   End-user




              First	
  Mile                  Middle	
  Mile                                   Last	
  Mile
                                                               Put	
  more	
  edge	
  servers	
  instead	
  of	
  customer	
  
                                                               Content	
  is	
  cached;	
  no	
  increase	
  on	
  origin	
  server	
  
                                                               traffic
                                             PHPFest	
  2011	
                                                                 9	
  
History

  Late	
  90’s,	
  SandPiper	
  was	
  first	
  CDN	
  company	
  and	
  Akamai	
  made	
  it	
  a	
  success
   ful	
  market	
  around	
  1999~2000	
  
  In	
  Korea,	
  CDN	
  service	
  started	
  around	
  2000	
  by	
  a	
  few	
  startups	
  including	
  CD
   Networks	
  

  Now	
  CDN	
  provider	
  and	
  ISP	
  are	
  compeZng	
  each	
  other	
  




                                                PHPFest	
  2011	
                                            10	
  
CDN	
  Services

  HTTP/HTTPS	
  Delivery	
  
      •  Web	
  Caching	
  Model	
  
      •  Mirroring	
  Model	
  
  Streaming	
  
      •  Windows	
  Media	
  Streaming	
  (VOD,	
  Live)	
  
      •  Flash	
  Media	
  Streaming	
  (VOD,	
  Live)	
  
      •  Caching	
  and	
  mirroring	
  model	
  
  AddiZonal	
  Service	
  
      •  Storage	
  as	
  a	
  origin	
  
      •  P2P	
  delivery	
  (aka	
  grid	
  delivery)	
  
  Pay	
  for	
  usage:	
  traffic	
  (Gbytes)	
  or	
  bandwidth	
  (Gbit/sec)	
  
	
  




                                                      PHPFest	
  2011	
             11	
  
In	
  real	
  world

  Websites	
  (HTTP/HTTPS)	
  
     •  E-­‐Commerce	
  
            −  A	
  large	
  number	
  of	
  images	
  
            −  Accessing	
  from	
  many	
  users	
  
     •  Social	
  commerce	
  
            −  A	
  few	
  number	
  of	
  images	
  
            −  Many	
  users	
  at	
  the	
  same	
  Zme	
  –	
  high	
  spike	
  
     •  Web	
  site	
  with	
  global	
  audience	
  
  Streaming	
  
     •  E-­‐learning	
  Contents	
  for	
  students	
  
     •  Live	
  event	
  for	
  a	
  big	
  sports	
  game	
  
     •  User	
  Generated	
  Contents	
  
  Online	
  Gaming	
  
     •  Launching	
  a	
  new	
  game	
  
     •  Release	
  update	
  or	
  patch	
  


                                                            PHPFest	
  2011	
        12	
  
Traffic	
  PaNern	
  of	
  a	
  web	
  site

As	
  your	
  website	
  ge_ng	
  popular,	
  there	
  will	
  be	
  unexpected	
  traffic	
  paAerns	
  


                                                                         Website	
  only	
  can	
  handle	
  this	
  
                                                                         (limited	
  by	
  bandwidth,	
  server,	
  etc)




                                                   PHPFest	
  2011	
                                                 13	
  
High	
  Level	
  Architecture

                                          Data	
  Center,	
  or	
  PoP	
  (Point	
  Of	
  Presence)
              Cache
            Streaming
     Storage
           Monitoring
                          Router
                                              GSLB

              Cache
                                                    Management

              Cache
                                                   Log	
  Processing
                           Storage
           Monitoring
                                                Operator	
  Portal
                          Router
                                     Customer	
  Portal

              Cache
                                              Admin	
  PoP	
  or	
  Control	
  Center

              Cache
       Storage
           Monitoring
                          Router
                                      PHPFest	
  2011	
                                                     14	
  
Main	
  Technology

  GSLB	
  
     •  Global	
  Server	
  Load	
  Balancing	
  
     •  Typically	
  DNS	
  server	
  which	
  do	
  load	
  balancing	
  between	
  mulZple	
  servers	
  and	
  ne
        tworks	
  
     •  Most	
  CDN	
  provider	
  use	
  GSLB	
  
  Cache	
  
     •    Web	
  Cache	
  for	
  HTTP/HTTPS	
  
     •    Cache	
  objects	
  in	
  storage	
  
     •    When	
  end	
  user	
  access	
  the	
  contents,	
  it	
  will	
  serve	
  objects	
  from	
  cache	
  if	
  possible	
  
     •    Controlled	
  by	
  several	
  configuraZon	
  parameter	
  and	
  HTTP	
  response	
  from	
  origin	
  
  Portal	
  
     •  Large	
  data	
  processing	
  –	
  processing	
  daily	
  logs	
  
     •  Controllable	
  via	
  UI	
  for	
  operators




                                                       PHPFest	
  2011	
                                                         15	
  
CDN	
  in	
  website



    hAp://www.kr.cdnetworks.com/index.php

                                                        Typical	
  web	
  site	
  has	
  a	
  lot	
  of	
  objects	
  
                                                        Inside	
  –	
  images,	
  flash,	
  video,	
  js,	
  css	
  etc




              hAp://www.kr.cdnetworks.com/images/common/main_logo.gif


                                  PHPFest	
  2011	
                                                           16	
  
DNS	
  lookup	
  example

%	
  dig	
  www.kr.cdnetworks.com	
  
	
  
;;	
  QUESTION	
  SECTION:	
  
;www.kr.cdnetworks.com.	
                 	
  IN    	
  A	
  
	
  
;;	
  ANSWER	
  SECTION:	
  
www.kr.cdnetworks.com. 	
  3420           	
  IN    	
  CNAME        	
  www.kr.cdnetworks.com.cdngc.net.	
  
www.kr.cdnetworks.com.cdngc.net.	
  20	
  IN        	
  A            	
  61.110.226.28	
  
www.kr.cdnetworks.com.cdngc.net.	
  20	
  IN        	
  A            	
  61.110.226.15	
  
	
  
;;	
  AUTHORITY	
  SECTION:	
  
cdngc.net. 	
                   	
  68200 	
  IN    	
  NS           	
  ns2.panthercdn.com.	
  
cdngc.net. 	
                   	
  68200 	
  IN    	
  NS           	
  ns1.panthercdn.com.	
  
	
  
;;	
  ADDITIONAL	
  SECTION:	
  
ns1.panthercdn.com.             	
  64021 	
  IN    	
  A            	
  205.252.255.11	
  
ns2.panthercdn.com.             	
  48212 	
  IN    	
  A            	
  67.72.21.11




                                                   PHPFest	
  2011	
                                            17	
  
DNS	
  lookup	
  example




                                          Root	
  DNS	
  (.com,	
  .net)	
  
                                           “What’s	
  DNS	
  Server	
  IP	
  address	
  of	
  cdnetworks.com?”	
  



                                        “What’s	
  IP	
  address	
  of	
  www.kr.cdnetworks.com?”	
  




                     Resolver	
                         DNS	
  for	
  cdnetworks.com	
  
   End	
  User	
     Local	
  DNS	
  
   Browser	
                                     “www.kr.cdnetworks.com	
  is	
  (CNAME)	
  
                                                 	
  	
  	
  	
  www.kr.cdnetworks.cdngc.net”	
  




                                              PHPFest	
  2011	
                                                      18	
  
DNS	
  lookup	
  example




                                          Root	
  DNS	
  (.com,	
  .net)	
  
                                           “What’s	
  DNS	
  Server	
  IP	
  address	
  of	
  cdnetworks.com?”	
  
                                           “What’s	
  DNS	
  Server	
  IP	
  address	
  of	
  cdngc.net?”	
  


                                        “What’s	
  IP	
  address	
  of	
  www.kr.cdnetworks.com?”	
  




                     Resolver	
                         DNS	
  for	
  cdnetworks.com	
  
   End	
  User	
     Local	
  DNS	
  
   Browser	
                             “www.kr.cdnetworks.com	
  is	
  www.kr.cdnetworks.cdngc.net”	
  




                                                           DNS	
  for	
  cdngc.net	
  (GSLB)	
  
                                         “What’s	
  IP	
  address	
  of	
  www.kr.cdnetworks.com.cdngc.net?”	
  
                                         “61.110.226.28	
  and	
  61.110.226.15”	
  (IP	
  of	
  Cache	
  Servers)	
  
                                              PHPFest	
  2011	
                                                      19	
  
Object	
  delivery	
  and	
  whole	
  site	
  delivery

  Object	
  delivery	
  
     •  Only	
  serves	
  specified	
  file	
  (image,	
  video,	
  js,	
  css)	
  and	
  sZll	
  other	
  page	
  is	
  served	
  fr
        om	
  origin	
  site

    hAp://www.kr.cdnetworks.com/index.php




                                                                                 www.kr.cdnetworks.com	
  
                                                                                 !=	
  images.kr.cdnetworks.com




                   hAp://images.kr.cdnetworks.com/images/common/main_logo.gif
                                                       PHPFest	
  2011	
                                                         20	
  
Object	
  delivery	
  and	
  whole	
  site	
  delivery

  Whole	
  Site	
  Delivery	
  
      •  CDN	
  covers	
  whole	
  site	
  –	
  including	
  objects,	
  dynamic	
  pages	
  etc.	
  
      •  Need	
  more	
  aAenZon	
  –	
  what	
  is	
  cacheable	
  and	
  not	
  cacheable	
  not	
  to	
  break	
  sites	
  
     hAp://www.kr.cdnetworks.com/index.php




                                                                             www.kr.cdnetworks.com	
  
                                                                             ==	
  www.kr.cdnetworks.com




                   hAp://www.kr.cdnetworks.com/images/common/main_logo.gif
                                                     PHPFest	
  2011	
                                                     21	
  
Cacheable	
  and	
  non-­‐cacheable

  Objects	
  are	
  cacheable	
  
     •    In	
  Edge	
  Cache	
  Server	
  
     •    In	
  Proxy	
  Cache	
  in	
  ISP	
  or	
  your	
  network	
  
     •    In	
  Browser	
  Cache	
  
     •    TTL	
  (Time	
  To	
  Live)	
  –	
  lifeZme	
  in	
  Edge	
  Cache	
  

     •  Images,	
  Videos,	
  Documents,	
  CSS,	
  Javascript	
  
     •  Not	
  changed	
  by	
  me,	
  locaon,	
  session,	
  cookie,	
  browser	
  


  Objects	
  are	
  non-­‐cacheable	
  
     •  Dynamic	
  response	
  from	
  PHP/JSP/ASP/…	
  
     •  Cannot	
  be	
  stored	
  in	
  Edge	
  Cache/Proxy/Browser	
  Cache	
  

     •  Dynamically	
  generated	
  HTML	
  pages,	
  AJAX	
  response,	
  API	
  
     •  Same	
  URL	
  but	
  different	
  contents	
  by	
  me,	
  locaon,	
  session,	
  cookie,	
  browser	
  

                                                         PHPFest	
  2011	
                                      22	
  
Cache	
  Control

  You	
  can	
  control	
  cache-­‐ability	
  of	
  objects	
  using	
  various	
  headers	
  in	
  HTTP	
  resp
   onse.	
  
      •  CDN	
  Edge	
  Cache	
  
      •  Browser	
  Cache	
  (local	
  PC)	
  
  2	
  Basic	
  Status	
  
      •  Cache	
  Hit:	
  when	
  cache	
  already	
  has	
  the	
  object	
  
      •  Cache	
  Miss:	
  cache	
  will	
  pull	
  the	
  object	
  from	
  origin	
  and	
  store	
  
  Cache	
  related	
  headers	
  
      •    Last-­‐Modified,	
  Etag	
  
      •    Cache-­‐Control	
  
      •    Pragma	
  
      •    Vary	
  
      •    Expires	
  
  Cache/Proxy	
  related	
  headers	
  
      •  Via,	
  Age	
  

                                                        PHPFest	
  2011	
                                     23	
  
Example	
  of	
  non-­‐cacheable	
  object

%	
  curl	
  -­‐I	
  http://www.naver.com	
  	
  
HTTP/1.1	
  200	
  OK	
  
Date:	
  Thu,	
  26	
  May	
  2011	
  12:23:01	
  GMT	
  
Server:	
  Apache	
  
Cache-­‐Control:	
  no-­‐cache,	
  no-­‐store,	
  must-­‐revalidate	
  
Pragma:	
  no-­‐cache	
  
P3P:	
  CP="CAO	
  DSP	
  CURa	
  ADMa	
  TAIa	
  PSAa	
  OUR	
  LAW	
  STP	
  PHY	
  ONL	
  UNI	
  PUR	
  FIN	
  COM
	
  NAV	
  INT	
  DEM	
  STA	
  PRE"	
  
Cache-­‐Control:	
  no-­‐cache,	
  no-­‐store,	
  must-­‐revalidate	
  
Pragma:	
  no-­‐cache	
  
Vary:	
  Accept-­‐Encoding,User-­‐Agent	
  
Connection:	
  close	
  
Content-­‐Type:	
  text/html;	
  charset=UTF-­‐8




                                                  PHPFest	
  2011	
                                               24	
  
Example	
  of	
  non-­‐cacheable	
  object	
  –	
  from	
  iPod?

%	
  curl	
  -­‐I	
  -­‐A	
  "Mozilla/5.0	
  (iPod;	
  U;	
  CPU	
  iPhone	
  OS	
  4_3_1	
  like	
  Mac	
  OS	
  X;	
  e
n-­‐us)	
  AppleWebKit/533.17.9	
  (KHTML,	
  like	
  Gecko)	
  Version/5.0.2	
  Mobile/8G4	
  
Safari/6533.18.5"	
  http://www.naver.com	
  
HTTP/1.1	
  302	
  Found	
  
Date:	
  Thu,	
  26	
  May	
  2011	
  12:37:32	
  GMT	
  
Server:	
  Apache	
  
Location:	
  http://m.naver.com	
  
Vary:	
  Accept-­‐Encoding	
  
Connection:	
  close	
  
Content-­‐Type:	
  text/html;	
  charset=iso-­‐8859-­‐1




                                                    PHPFest	
  2011	
                                                 25	
  
How	
  to	
  make	
  non-­‐cacheable	
  object	
  in	
  PHP

  Using	
  header()	
  funcZon	
  
	
  
<?php	
  
header(“Cache-­‐Control:	
  no-­‐cache,	
  no-­‐store,	
  must-­‐revalidate”);	
  
header(“Pragma:	
  no-­‐cache”);	
  
header(“Vary:	
  Accept-­‐Encoding,	
  User-­‐Agent”);	
  
?>	
  
Hello	
  World	
  
	
  




                                         PHPFest	
  2011	
                           26	
  
How	
  to	
  make	
  non-­‐cacheable	
  object	
  in	
  PHP

%	
  curl	
  -­‐D-­‐	
  http://www.kr.freebsd.org/~cjh/phpfest2011/nc.php	
  
HTTP/1.1	
  200	
  OK	
  
Date:	
  Thu,	
  26	
  May	
  2011	
  13:09:11	
  GMT	
  
Server:	
  Apache/1.3.41	
  (Unix)	
  mod_perl/1.31	
  DAV/1.0.3	
  PHP/4.4.9	
  with	
  Suho
sin-­‐Patch	
  mod_ssl/2.8.31	
  OpenSSL/0.9.7e-­‐p1	
  
MS-­‐Author-­‐Via:	
  DAV	
  
X-­‐Powered-­‐By:	
  PHP/4.4.9	
  
Cache-­‐Control:	
  no-­‐cache,	
  no-­‐store,	
  must-­‐revalidate	
  
Pragma:	
  no-­‐cache	
  
Vary:	
  Accept-­‐Encoding,	
  User-­‐Agent	
  
Transfer-­‐Encoding:	
  chunked	
  
Content-­‐Type:	
  text/html;	
  charset=euc-­‐kr	
  
	
  
Hello	
  World	
  




                                         PHPFest	
  2011	
                                 27	
  
How	
  to	
  make	
  non-­‐cacheable	
  object	
  in	
  PHP	
  (2)

<?php	
  
header(“Cache-­‐Control:	
  no-­‐cache,	
  no-­‐store,	
  must-­‐revalidate”);	
  
header(“Pragma:	
  no-­‐cache”);	
  
header(“Vary:	
  Accept-­‐Encoding,	
  User-­‐Agent”);	
  
	
  
if	
  (strstr($_SERVER["HTTP_USER_AGENT"],	
  "iPhone	
  OS"))	
  {	
  
	
  	
  	
  	
  print	
  "<h1>Hello	
  iOS</h1>";	
  
	
  	
  	
  	
  print	
  "<h1>Hello	
  iOS</h1>";	
  
	
  	
  	
  	
  print	
  "<h1>Hello	
  iOS</h1>";	
  
	
  	
  	
  	
  exit;	
  
}	
  
?>	
  
Hello	
  World	
  
	
  




                                           PHPFest	
  2011	
                         28	
  
Example	
  of	
  cacheable	
  object

%	
  curl	
  -­‐I	
  'http://static.naver.com/www/u/2010/0611/nmms_215646753.gif'	
  
HTTP/1.1	
  200	
  OK	
  
Date:	
  Thu,	
  26	
  May	
  2011	
  12:27:30	
  GMT	
  
Server:	
  Apache/2.0.52	
  
Last-­‐Modified:	
  Fri,	
  11	
  Jun	
  2010	
  12:56:46	
  GMT	
  
ETag:	
  "a06-­‐abe73f80"	
  
Accept-­‐Ranges:	
  bytes	
  
Content-­‐Length:	
  2566	
  
                                                         TTL	
  is	
  7	
  day	
  
Cache-­‐Control:	
  max-­‐age=604800	
  
Content-­‐Type:	
  image/gif	
  
Via:	
  1.1	
  SI2286-­‐239	
  (Jaguar/3.0-­‐62)	
  
Age:	
  3	
  
Expires:	
  Thu,	
  02	
  Jun	
  2011	
  12:27:23	
  GMT




                                       PHPFest	
  2011	
                            29	
  
Example	
  of	
  cacheable	
  object	
  in	
  CDN	
  Server

%	
  curl	
  -­‐I	
  'http://static.naver.com/www/                       %	
  curl	
  -­‐I	
  'http://static.naver.com/www/
u/2010/0611/nmms_215646753.gif'	
                                        u/2010/0611/nmms_215646753.gif'	
  
HTTP/1.1	
  200	
  OK	
                                                  HTTP/1.1	
  200	
  OK	
  
Date:	
  Thu,	
  26	
  May	
  2011	
  12:27:30	
  GMT	
                  Date:	
  Thu,	
  26	
  May	
  2011	
  12:31:23	
  GMT	
  
Server:	
  Apache/2.0.52	
                                               Server:	
  Apache/2.0.52	
  
Last-­‐Modified:	
  Fri,	
  11	
  Jun	
  2010	
  12:56:4                 Last-­‐Modified:	
  Fri,	
  11	
  Jun	
  2010	
  12:56:4
6	
  GMT	
                                                               6	
  GMT	
  
ETag:	
  "a06-­‐abe73f80"	
                                              ETag:	
  "a06-­‐abe73f80"	
  
Accept-­‐Ranges:	
  bytes	
                                              Accept-­‐Ranges:	
  bytes	
  
Content-­‐Length:	
  2566	
                                              Content-­‐Length:	
  2566	
  
Cache-­‐Control:	
  max-­‐age=604800	
                                   Cache-­‐Control:	
  max-­‐age=604800	
  
Content-­‐Type:	
  image/gif	
                                           Content-­‐Type:	
  image/gif	
  
Age:	
  3	
                            	
                                Age:	
  53	
  
                                       	
  
Expires:	
  Thu,	
  02	
  Jun	
  2011	
  12:27:23	
  GMT	
               Expires:	
  Thu,	
  02	
  Jun	
  2011	
  12:30:30	
  GMT
	
  


                    Age:	
  header	
  value	
  is	
  residing	
  Zme	
  (second)	
  in	
  Edge	
  Cache.	
  
                    In	
  this	
  case	
  this	
  object	
  will	
  stored	
  in	
  Edge	
  Cache	
  for	
  7	
  day	
  
                    (604800	
  sec).

                                         PHPFest	
  2011	
                                                                      30	
  
How	
  to	
  make	
  cacheable	
  object	
  in	
  PHP

<?php	
  
header("Cache-­‐Control:	
  max-­‐age=604800");	
  //	
  tell	
  CDN	
  cache	
  to	
  store	
  object	
  f
or	
  next	
  24	
  hours	
  
header("Content-­‐Type:	
  text/plain");	
  
header("Content-­‐Length:	
  ".filesize("test.txt"));	
  
readfile("test.txt");	
  
?>	
  
	
  
%	
  curl	
  -­‐D-­‐	
  http://www.kr.freebsd.org/~cjh/phpfest2011/c.php	
  
HTTP/1.1	
  200	
  OK	
  
Date:	
  Thu,	
  26	
  May	
  2011	
  13:35:32	
  GMT	
  
Server:	
  Apache/1.3.41	
  (Unix)	
  mod_perl/1.31	
  DAV/1.0.3	
  PHP/4.4.9	
  with	
  Suhosin-­‐
Patch	
  mod_ssl/2.8.31	
  OpenSSL/0.9.7e-­‐p1	
  
MS-­‐Author-­‐Via:	
  DAV	
  
X-­‐Powered-­‐By:	
  PHP/4.4.9	
  
Cache-­‐Control:	
  max-­‐age=604800	
  
Content-­‐Length:	
  17	
  
Content-­‐Type:	
  text/plain;charset=euc-­‐kr	
  
	
  
THIS	
  IS	
  TEST.TXT	
  
                                              PHPFest	
  2011	
                                          31	
  
How	
  to	
  make	
  cacheable	
  object	
  in	
  PHP	
  (2)

HTTP/1.1	
  200	
  OK	
                                               HTTP/1.1	
  200	
  OK	
  
Date:	
  Thu,	
  26	
  May	
  2011	
  15:28:06	
  GMT	
               Date:	
  Thu,	
  26	
  May	
  2011	
  15:28:15	
  GMT	
  
Server:	
  PWS/1.7.2.3	
                                              Server:	
  PWS/1.7.2.3	
  
Cache-­‐Control:	
  max-­‐age=604800	
                                Cache-­‐Control:	
  max-­‐age=604800	
  
Expires:	
  Thu,	
  02	
  Jun	
  2011	
  15:28:07	
  GMT	
            Expires:	
  Thu,	
  02	
  Jun	
  2011	
  15:28:06	
  GMT	
  
Age:	
  0	
                            	
  
                                                                      Age:	
  9	
  
Content-­‐Length:	
  17	
  
                                       	
  
                                                                      Content-­‐Length:	
  17	
  
Content-­‐Type:	
  text/plain;charset=euc-­‐kr	
                      Content-­‐Type:	
  text/plain;charset=euc-­‐kr	
  
Connection:	
  keep-­‐alive	
                                         Connection:	
  keep-­‐alive	
  
	
                                                                    	
  
THIS	
  IS	
  TEST.TXT                                                THIS	
  IS	
  TEST.TXT




              As	
  you	
  can	
  see	
  now	
  this	
  URL	
  is	
  cached	
  in	
  Edge	
  Cache,	
  although	
  this	
  page	
  
              is	
  generated	
  by	
  PHP.	
  
              Also	
  check	
  origin	
  server	
  if	
  access	
  from	
  cache	
  exists	
  	
  should	
  be	
  none



                                                          PHPFest	
  2011	
                                                           32	
  
CDN	
  &	
  Cloud

  Cloud	
  CompuZng	
  provide	
  very	
  similar	
  purpose	
  of	
  CDN	
  such	
  as	
  reliability	
  an
   d	
  scalability,	
  but	
  not	
  helpful	
  to	
  solve	
  other	
  problems	
  such	
  as	
  Network	
  Dist
   ance	
  (middle	
  mile)	
  problem	
  
      •  Cloud:	
  Most	
  servers	
  are	
  located	
  in	
  ONE	
  locaZon	
  


  Combining	
  CDN	
  with	
  Cloud	
  service	
  
      •    Cloud	
  CompuZng	
  can	
  solve	
  a	
  lot	
  of	
  origin	
  issue	
  such	
  as	
  scalability	
  
      •    CDN	
  can	
  provide	
  fast	
  access	
  to	
  cacheable	
  objects	
  
      •    For	
  high	
  performance,	
  global-­‐accessed	
  websites	
  
      •    Example	
  
             −  Origin	
  Server	
  use	
  VM	
  Cloud	
  and	
  Storage	
  
             −  Use	
  CDN	
  for	
  caching	
  and	
  low	
  latency	
  


  Cloud	
  Service	
  company	
  has	
  compeZng	
  products	
  with	
  CDN	
  
      •  Amazon’s	
  S3	
  storage	
  +	
  CloudFront	
  

                                                          PHPFest	
  2011	
                                          33	
  
Example:	
  CloudSleuth.net




                              PHPFest	
  2011	
     34	
  
Example:	
  CloudSleuth.net




                              PHPFest	
  2011	
     35	
  
Other	
  keywords

    ApplicaZon	
  Delivery	
  
    WAN	
  AcceleraZon/OpZmizaZon	
  
    Edge	
  CompuZng	
  
    Web	
  Page	
  OpZmizaZon	
  
    Mobile	
  OpZmizaZon	
  
    …	
  




                            Thank	
  you!	
  

                                   PHPFest	
  2011	
     36	
  

Weitere ähnliche Inhalte

Was ist angesagt?

The Evolution of the Content Delivery Network
The Evolution of the Content Delivery NetworkThe Evolution of the Content Delivery Network
The Evolution of the Content Delivery NetworkCisco Service Provider
 
BT Rich Media platform 2004
BT Rich Media platform 2004BT Rich Media platform 2004
BT Rich Media platform 2004dsbowskill
 
Ibc forum 2012-divitel
Ibc forum 2012-divitelIbc forum 2012-divitel
Ibc forum 2012-divitelVerimatrix
 
QLogic Adapters & Virtualized Environments
QLogic Adapters & Virtualized EnvironmentsQLogic Adapters & Virtualized Environments
QLogic Adapters & Virtualized EnvironmentsQLogic Corporation
 
Using Bandwidth Aggregation to Improve the Performance of Video Quality- Adap...
Using Bandwidth Aggregation to Improve the Performance of Video Quality- Adap...Using Bandwidth Aggregation to Improve the Performance of Video Quality- Adap...
Using Bandwidth Aggregation to Improve the Performance of Video Quality- Adap...paperpublications3
 
CCNxCon2012: Session 2: A Content-Centric Approach for Requesting and Dissemi...
CCNxCon2012: Session 2: A Content-Centric Approach for Requesting and Dissemi...CCNxCon2012: Session 2: A Content-Centric Approach for Requesting and Dissemi...
CCNxCon2012: Session 2: A Content-Centric Approach for Requesting and Dissemi...PARC, a Xerox company
 
Next Generation Video Services Fundamentals
Next Generation Video Services FundamentalsNext Generation Video Services Fundamentals
Next Generation Video Services FundamentalsCisco Canada
 
QLogic Solutions - Microsoft Exchange Server
QLogic Solutions - Microsoft Exchange ServerQLogic Solutions - Microsoft Exchange Server
QLogic Solutions - Microsoft Exchange ServerQLogic Corporation
 
Shinde qos-mpls-tutorial
Shinde qos-mpls-tutorialShinde qos-mpls-tutorial
Shinde qos-mpls-tutorialadvojoy
 
Phil Evans - broadband aggregation Wales
Phil Evans - broadband aggregation WalesPhil Evans - broadband aggregation Wales
Phil Evans - broadband aggregation WalesSocitm
 
High Efficiency of Media Processing Amos K.
High Efficiency of Media Processing Amos K.High Efficiency of Media Processing Amos K.
High Efficiency of Media Processing Amos K.Amos Kohn
 
C2C Forum no2 Bill Murphy final
C2C Forum no2 Bill Murphy finalC2C Forum no2 Bill Murphy final
C2C Forum no2 Bill Murphy finalPhilip Locke
 
Verimatrix - Multi-network Solutions in the Real World - CSTB 2012
Verimatrix - Multi-network Solutions in the Real World - CSTB 2012Verimatrix - Multi-network Solutions in the Real World - CSTB 2012
Verimatrix - Multi-network Solutions in the Real World - CSTB 2012Verimatrix
 
1. Shipit Smarter Concept &amp; Functionalities (English)
1. Shipit Smarter Concept &amp; Functionalities (English)1. Shipit Smarter Concept &amp; Functionalities (English)
1. Shipit Smarter Concept &amp; Functionalities (English)Pieter Nijman
 
Survey paper on Virtualized cloud based IPTV System
Survey paper on Virtualized cloud based IPTV SystemSurvey paper on Virtualized cloud based IPTV System
Survey paper on Virtualized cloud based IPTV Systemijceronline
 
Gulfnet Profile
Gulfnet ProfileGulfnet Profile
Gulfnet Profilejolian
 
An operator CDN deployment in Latin America: facts & lessons learnt
An operator CDN deployment in Latin America: facts & lessons learntAn operator CDN deployment in Latin America: facts & lessons learnt
An operator CDN deployment in Latin America: facts & lessons learntnivedita_nouvel
 
Cdn world summit oct 2011
Cdn world summit oct 2011Cdn world summit oct 2011
Cdn world summit oct 2011Martin Ortiz
 
Key Considerations for MPLS IP-VPN Success
Key Considerations for  MPLS IP-VPN SuccessKey Considerations for  MPLS IP-VPN Success
Key Considerations for MPLS IP-VPN SuccessXO Communications
 

Was ist angesagt? (20)

The Evolution of the Content Delivery Network
The Evolution of the Content Delivery NetworkThe Evolution of the Content Delivery Network
The Evolution of the Content Delivery Network
 
Mplsvpn seminar
Mplsvpn seminarMplsvpn seminar
Mplsvpn seminar
 
BT Rich Media platform 2004
BT Rich Media platform 2004BT Rich Media platform 2004
BT Rich Media platform 2004
 
Ibc forum 2012-divitel
Ibc forum 2012-divitelIbc forum 2012-divitel
Ibc forum 2012-divitel
 
QLogic Adapters & Virtualized Environments
QLogic Adapters & Virtualized EnvironmentsQLogic Adapters & Virtualized Environments
QLogic Adapters & Virtualized Environments
 
Using Bandwidth Aggregation to Improve the Performance of Video Quality- Adap...
Using Bandwidth Aggregation to Improve the Performance of Video Quality- Adap...Using Bandwidth Aggregation to Improve the Performance of Video Quality- Adap...
Using Bandwidth Aggregation to Improve the Performance of Video Quality- Adap...
 
CCNxCon2012: Session 2: A Content-Centric Approach for Requesting and Dissemi...
CCNxCon2012: Session 2: A Content-Centric Approach for Requesting and Dissemi...CCNxCon2012: Session 2: A Content-Centric Approach for Requesting and Dissemi...
CCNxCon2012: Session 2: A Content-Centric Approach for Requesting and Dissemi...
 
Next Generation Video Services Fundamentals
Next Generation Video Services FundamentalsNext Generation Video Services Fundamentals
Next Generation Video Services Fundamentals
 
QLogic Solutions - Microsoft Exchange Server
QLogic Solutions - Microsoft Exchange ServerQLogic Solutions - Microsoft Exchange Server
QLogic Solutions - Microsoft Exchange Server
 
Shinde qos-mpls-tutorial
Shinde qos-mpls-tutorialShinde qos-mpls-tutorial
Shinde qos-mpls-tutorial
 
Phil Evans - broadband aggregation Wales
Phil Evans - broadband aggregation WalesPhil Evans - broadband aggregation Wales
Phil Evans - broadband aggregation Wales
 
High Efficiency of Media Processing Amos K.
High Efficiency of Media Processing Amos K.High Efficiency of Media Processing Amos K.
High Efficiency of Media Processing Amos K.
 
C2C Forum no2 Bill Murphy final
C2C Forum no2 Bill Murphy finalC2C Forum no2 Bill Murphy final
C2C Forum no2 Bill Murphy final
 
Verimatrix - Multi-network Solutions in the Real World - CSTB 2012
Verimatrix - Multi-network Solutions in the Real World - CSTB 2012Verimatrix - Multi-network Solutions in the Real World - CSTB 2012
Verimatrix - Multi-network Solutions in the Real World - CSTB 2012
 
1. Shipit Smarter Concept &amp; Functionalities (English)
1. Shipit Smarter Concept &amp; Functionalities (English)1. Shipit Smarter Concept &amp; Functionalities (English)
1. Shipit Smarter Concept &amp; Functionalities (English)
 
Survey paper on Virtualized cloud based IPTV System
Survey paper on Virtualized cloud based IPTV SystemSurvey paper on Virtualized cloud based IPTV System
Survey paper on Virtualized cloud based IPTV System
 
Gulfnet Profile
Gulfnet ProfileGulfnet Profile
Gulfnet Profile
 
An operator CDN deployment in Latin America: facts & lessons learnt
An operator CDN deployment in Latin America: facts & lessons learntAn operator CDN deployment in Latin America: facts & lessons learnt
An operator CDN deployment in Latin America: facts & lessons learnt
 
Cdn world summit oct 2011
Cdn world summit oct 2011Cdn world summit oct 2011
Cdn world summit oct 2011
 
Key Considerations for MPLS IP-VPN Success
Key Considerations for  MPLS IP-VPN SuccessKey Considerations for  MPLS IP-VPN Success
Key Considerations for MPLS IP-VPN Success
 

Ähnlich wie CDN and Cloud - PHPFest 2011

Memcached, presented to LCA2010
Memcached, presented to LCA2010Memcached, presented to LCA2010
Memcached, presented to LCA2010Mark Atwood
 
FOSS Sthlm: Realtime Communication Update
FOSS Sthlm: Realtime Communication UpdateFOSS Sthlm: Realtime Communication Update
FOSS Sthlm: Realtime Communication UpdateOlle E Johansson
 
Best Practices for Virtualizing Hadoop
Best Practices for Virtualizing HadoopBest Practices for Virtualizing Hadoop
Best Practices for Virtualizing HadoopDataWorks Summit
 
SAP Virtualization Week 2012 - The Lego Cloud
SAP Virtualization Week 2012 - The Lego CloudSAP Virtualization Week 2012 - The Lego Cloud
SAP Virtualization Week 2012 - The Lego Cloudaidanshribman
 
vFabric - Ideal Platform for SaaS Apps
vFabric - Ideal Platform for SaaS AppsvFabric - Ideal Platform for SaaS Apps
vFabric - Ideal Platform for SaaS AppsVMware vFabric
 
AMF Flash and .NET
AMF Flash and .NETAMF Flash and .NET
AMF Flash and .NETYaniv Uriel
 
HTML5 - The Python Angle (PyCon Ireland 2010)
HTML5 - The Python Angle (PyCon Ireland 2010)HTML5 - The Python Angle (PyCon Ireland 2010)
HTML5 - The Python Angle (PyCon Ireland 2010)Kevin Gill
 
Introduction to First Commercial Memcached Service for Cloud
Introduction to First Commercial Memcached Service for CloudIntroduction to First Commercial Memcached Service for Cloud
Introduction to First Commercial Memcached Service for CloudGear6
 
HAProxy tech talk
HAProxy tech talkHAProxy tech talk
HAProxy tech talkicebourg
 
Windows Server 2008 Web Workload Overview
Windows Server 2008 Web Workload OverviewWindows Server 2008 Web Workload Overview
Windows Server 2008 Web Workload OverviewDavid Chou
 
전문가토크릴레이 1탄 html5 전망 (전종홍 박사)
전문가토크릴레이 1탄 html5 전망 (전종홍 박사)전문가토크릴레이 1탄 html5 전망 (전종홍 박사)
전문가토크릴레이 1탄 html5 전망 (전종홍 박사)Saltlux zinyus
 
전문가 토크릴레이 1탄 html5 전망 (전종홍 박사)
전문가 토크릴레이 1탄 html5 전망 (전종홍 박사)전문가 토크릴레이 1탄 html5 전망 (전종홍 박사)
전문가 토크릴레이 1탄 html5 전망 (전종홍 박사)zinyus
 
Network Virtualization in Windows Server 2012
Network Virtualization in Windows Server 2012Network Virtualization in Windows Server 2012
Network Virtualization in Windows Server 2012Lai Yoong Seng
 
Ceph Day Chicago - Deploying flash storage for Ceph without compromising perf...
Ceph Day Chicago - Deploying flash storage for Ceph without compromising perf...Ceph Day Chicago - Deploying flash storage for Ceph without compromising perf...
Ceph Day Chicago - Deploying flash storage for Ceph without compromising perf...Ceph Community
 
Virtualizing Latency Sensitive Workloads and vFabric GemFire
Virtualizing Latency Sensitive Workloads and vFabric GemFireVirtualizing Latency Sensitive Workloads and vFabric GemFire
Virtualizing Latency Sensitive Workloads and vFabric GemFireCarter Shanklin
 
CM WebClient for CA Plex
CM WebClient for CA PlexCM WebClient for CA Plex
CM WebClient for CA PlexCM First Group
 
Mike Taulty DevDays 2010 Silverlight 4 - What's New Part 2
Mike Taulty DevDays 2010 Silverlight 4 - What's New Part 2Mike Taulty DevDays 2010 Silverlight 4 - What's New Part 2
Mike Taulty DevDays 2010 Silverlight 4 - What's New Part 2ukdpe
 
What’s new in Nuxeo 5.2?
What’s new in Nuxeo 5.2?What’s new in Nuxeo 5.2?
What’s new in Nuxeo 5.2?Nuxeo
 

Ähnlich wie CDN and Cloud - PHPFest 2011 (20)

Memcached, presented to LCA2010
Memcached, presented to LCA2010Memcached, presented to LCA2010
Memcached, presented to LCA2010
 
FOSS Sthlm: Realtime Communication Update
FOSS Sthlm: Realtime Communication UpdateFOSS Sthlm: Realtime Communication Update
FOSS Sthlm: Realtime Communication Update
 
Best Practices for Virtualizing Hadoop
Best Practices for Virtualizing HadoopBest Practices for Virtualizing Hadoop
Best Practices for Virtualizing Hadoop
 
SAP Virtualization Week 2012 - The Lego Cloud
SAP Virtualization Week 2012 - The Lego CloudSAP Virtualization Week 2012 - The Lego Cloud
SAP Virtualization Week 2012 - The Lego Cloud
 
vFabric - Ideal Platform for SaaS Apps
vFabric - Ideal Platform for SaaS AppsvFabric - Ideal Platform for SaaS Apps
vFabric - Ideal Platform for SaaS Apps
 
AMF Flash and .NET
AMF Flash and .NETAMF Flash and .NET
AMF Flash and .NET
 
HTML5 - The Python Angle (PyCon Ireland 2010)
HTML5 - The Python Angle (PyCon Ireland 2010)HTML5 - The Python Angle (PyCon Ireland 2010)
HTML5 - The Python Angle (PyCon Ireland 2010)
 
Introduction to First Commercial Memcached Service for Cloud
Introduction to First Commercial Memcached Service for CloudIntroduction to First Commercial Memcached Service for Cloud
Introduction to First Commercial Memcached Service for Cloud
 
Project Zero JavaOne 2008
Project Zero JavaOne 2008Project Zero JavaOne 2008
Project Zero JavaOne 2008
 
HAProxy tech talk
HAProxy tech talkHAProxy tech talk
HAProxy tech talk
 
Windows Server 2008 Web Workload Overview
Windows Server 2008 Web Workload OverviewWindows Server 2008 Web Workload Overview
Windows Server 2008 Web Workload Overview
 
전문가토크릴레이 1탄 html5 전망 (전종홍 박사)
전문가토크릴레이 1탄 html5 전망 (전종홍 박사)전문가토크릴레이 1탄 html5 전망 (전종홍 박사)
전문가토크릴레이 1탄 html5 전망 (전종홍 박사)
 
전문가 토크릴레이 1탄 html5 전망 (전종홍 박사)
전문가 토크릴레이 1탄 html5 전망 (전종홍 박사)전문가 토크릴레이 1탄 html5 전망 (전종홍 박사)
전문가 토크릴레이 1탄 html5 전망 (전종홍 박사)
 
Network Virtualization in Windows Server 2012
Network Virtualization in Windows Server 2012Network Virtualization in Windows Server 2012
Network Virtualization in Windows Server 2012
 
2018 jk
2018 jk2018 jk
2018 jk
 
Ceph Day Chicago - Deploying flash storage for Ceph without compromising perf...
Ceph Day Chicago - Deploying flash storage for Ceph without compromising perf...Ceph Day Chicago - Deploying flash storage for Ceph without compromising perf...
Ceph Day Chicago - Deploying flash storage for Ceph without compromising perf...
 
Virtualizing Latency Sensitive Workloads and vFabric GemFire
Virtualizing Latency Sensitive Workloads and vFabric GemFireVirtualizing Latency Sensitive Workloads and vFabric GemFire
Virtualizing Latency Sensitive Workloads and vFabric GemFire
 
CM WebClient for CA Plex
CM WebClient for CA PlexCM WebClient for CA Plex
CM WebClient for CA Plex
 
Mike Taulty DevDays 2010 Silverlight 4 - What's New Part 2
Mike Taulty DevDays 2010 Silverlight 4 - What's New Part 2Mike Taulty DevDays 2010 Silverlight 4 - What's New Part 2
Mike Taulty DevDays 2010 Silverlight 4 - What's New Part 2
 
What’s new in Nuxeo 5.2?
What’s new in Nuxeo 5.2?What’s new in Nuxeo 5.2?
What’s new in Nuxeo 5.2?
 

Kürzlich hochgeladen

Generative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxGenerative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxfnnc6jmgwh
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityIES VE
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxLoriGlavin3
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkPixlogix Infotech
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxLoriGlavin3
 
Scale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL RouterScale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL RouterMydbops
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsRavi Sanghani
 
QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesBernd Ruecker
 
Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024TopCSSGallery
 
Abdul Kader Baba- Managing Cybersecurity Risks and Compliance Requirements i...
Abdul Kader Baba- Managing Cybersecurity Risks  and Compliance Requirements i...Abdul Kader Baba- Managing Cybersecurity Risks  and Compliance Requirements i...
Abdul Kader Baba- Managing Cybersecurity Risks and Compliance Requirements i...itnewsafrica
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Alkin Tezuysal
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxLoriGlavin3
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfIngrid Airi González
 
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security ObservabilityGlenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security Observabilityitnewsafrica
 
Emixa Mendix Meetup 11 April 2024 about Mendix Native development
Emixa Mendix Meetup 11 April 2024 about Mendix Native developmentEmixa Mendix Meetup 11 April 2024 about Mendix Native development
Emixa Mendix Meetup 11 April 2024 about Mendix Native developmentPim van der Noll
 

Kürzlich hochgeladen (20)

Generative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxGenerative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptx
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a reality
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptxA Deep Dive on Passkeys: FIDO Paris Seminar.pptx
A Deep Dive on Passkeys: FIDO Paris Seminar.pptx
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App Framework
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptx
 
Scale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL RouterScale your database traffic with Read & Write split using MySQL Router
Scale your database traffic with Read & Write split using MySQL Router
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and Insights
 
QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architectures
 
Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024
 
Abdul Kader Baba- Managing Cybersecurity Risks and Compliance Requirements i...
Abdul Kader Baba- Managing Cybersecurity Risks  and Compliance Requirements i...Abdul Kader Baba- Managing Cybersecurity Risks  and Compliance Requirements i...
Abdul Kader Baba- Managing Cybersecurity Risks and Compliance Requirements i...
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptxThe Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
The Fit for Passkeys for Employee and Consumer Sign-ins: FIDO Paris Seminar.pptx
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdf
 
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security ObservabilityGlenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
 
Emixa Mendix Meetup 11 April 2024 about Mendix Native development
Emixa Mendix Meetup 11 April 2024 about Mendix Native developmentEmixa Mendix Meetup 11 April 2024 about Mendix Native development
Emixa Mendix Meetup 11 April 2024 about Mendix Native development
 

CDN and Cloud - PHPFest 2011

  • 1. CDN  &  Cloud Junho  Choi  <junho.choi@cdnetworks.com>   CDNetworks  h7p://www.cdnetworks.com   rev.  3
  • 2. Who  am  I?   Junho  Choi  ( )     CTO/APAC,  VP  of  Engineering  |  CDNetworks  hAp://www.cdnetworks.com     FreeBSD  CommiAer(ports)  (cjh@freebsd.org,  2001-­‐2010)     Korea  FreeBSD  Users  Group  hAp://www.kr.freebsd.org  since  1999     TwiAer:  junhochoi   PHPFest  2011   2  
  • 3. Contents   CDN  –  what  problem  to  solve     Technology  in  CDN     How  to  uZlize  CDN/Cache  using  PHP     Cloud  CompuZng  &  CDN PHPFest  2011   3  
  • 4. A  typical  web  site     You  built  a  fancy  web  site!     As  your  website  is  ge_ng  popular,  you  are  ge_ng  more  and  more  traffic.     Your  website  will  be  slow  when  more  users  visit.     Your  website  will  be  slow  when  users  from  other  countries  visit.     Your  website  can  be  down  due  to  hardware  failure,  network  failure.     Your  website  will  be  down  when  there  is  a  spike  of  traffic  because  your  we bsite  is  suddenly  popular  on  famous  news  site,  twiAer,  slashdot,  facebook   etc.     Your  website  is  not  scalable  when  you  want  to  expand  more     You  want  to  have  a  streaming  video  on  your  website  but  don’t  want  to  bu y  a  license  for  commercial  streaming  soluZon  such  as  Flash  Media  or  Wind ows  Media.     … PHPFest  2011   4  
  • 5. Content  Delivery  Network   Problem  to  solve   •  Network  Distance   •  Reliability   •  Scalability   PHPFest  2011   5  
  • 6. Problem  to  Solve  –  Network  Distance   Middle  Mile  Problem EMEA HQ End-user “Origin  Server”   Customer’s  web  site First  Mile   Middle  Mile   Last  Mile   Same  Data  Center   Bad Routing Same  LocaZon   Same  ISP   Same  ISP   Network Failure Low  latency   Low  latency   High  Bandwidth Long distance Low  Bandwidth   PHPFest  2011   6  
  • 7. Problem  to  Solve  –  Network  Distance “Edge  Server”   CDN  Cache EMEA HQ End-user “Origin  Server”   Customer’s  web  site First  Mile Middle  Mile Last  Mile Place  edge  (caching  or  mirroring)  server  on   nearest  locaZon  to  end  user PHPFest  2011   7  
  • 8. Problem  to  Solve  –  Reliability EMEA HQ End-user First  Mile Middle  Mile Last  Mile SZll  able  to  access  on  CDN  Edge  server PHPFest  2011   8  
  • 9. Problem  to  Solve  –  Scalability EMEA HQ End-user First  Mile Middle  Mile Last  Mile Put  more  edge  servers  instead  of  customer   Content  is  cached;  no  increase  on  origin  server   traffic PHPFest  2011   9  
  • 10. History   Late  90’s,  SandPiper  was  first  CDN  company  and  Akamai  made  it  a  success ful  market  around  1999~2000     In  Korea,  CDN  service  started  around  2000  by  a  few  startups  including  CD Networks     Now  CDN  provider  and  ISP  are  compeZng  each  other   PHPFest  2011   10  
  • 11. CDN  Services   HTTP/HTTPS  Delivery   •  Web  Caching  Model   •  Mirroring  Model     Streaming   •  Windows  Media  Streaming  (VOD,  Live)   •  Flash  Media  Streaming  (VOD,  Live)   •  Caching  and  mirroring  model     AddiZonal  Service   •  Storage  as  a  origin   •  P2P  delivery  (aka  grid  delivery)     Pay  for  usage:  traffic  (Gbytes)  or  bandwidth  (Gbit/sec)     PHPFest  2011   11  
  • 12. In  real  world   Websites  (HTTP/HTTPS)   •  E-­‐Commerce   −  A  large  number  of  images   −  Accessing  from  many  users   •  Social  commerce   −  A  few  number  of  images   −  Many  users  at  the  same  Zme  –  high  spike   •  Web  site  with  global  audience     Streaming   •  E-­‐learning  Contents  for  students   •  Live  event  for  a  big  sports  game   •  User  Generated  Contents     Online  Gaming   •  Launching  a  new  game   •  Release  update  or  patch   PHPFest  2011   12  
  • 13. Traffic  PaNern  of  a  web  site As  your  website  ge_ng  popular,  there  will  be  unexpected  traffic  paAerns   Website  only  can  handle  this   (limited  by  bandwidth,  server,  etc) PHPFest  2011   13  
  • 14. High  Level  Architecture Data  Center,  or  PoP  (Point  Of  Presence) Cache Streaming Storage Monitoring Router GSLB Cache Management Cache Log  Processing Storage Monitoring Operator  Portal Router Customer  Portal Cache Admin  PoP  or  Control  Center Cache Storage Monitoring Router PHPFest  2011   14  
  • 15. Main  Technology   GSLB   •  Global  Server  Load  Balancing   •  Typically  DNS  server  which  do  load  balancing  between  mulZple  servers  and  ne tworks   •  Most  CDN  provider  use  GSLB     Cache   •  Web  Cache  for  HTTP/HTTPS   •  Cache  objects  in  storage   •  When  end  user  access  the  contents,  it  will  serve  objects  from  cache  if  possible   •  Controlled  by  several  configuraZon  parameter  and  HTTP  response  from  origin     Portal   •  Large  data  processing  –  processing  daily  logs   •  Controllable  via  UI  for  operators PHPFest  2011   15  
  • 16. CDN  in  website hAp://www.kr.cdnetworks.com/index.php Typical  web  site  has  a  lot  of  objects   Inside  –  images,  flash,  video,  js,  css  etc hAp://www.kr.cdnetworks.com/images/common/main_logo.gif PHPFest  2011   16  
  • 17. DNS  lookup  example %  dig  www.kr.cdnetworks.com     ;;  QUESTION  SECTION:   ;www.kr.cdnetworks.com.    IN  A     ;;  ANSWER  SECTION:   www.kr.cdnetworks.com.  3420  IN  CNAME  www.kr.cdnetworks.com.cdngc.net.   www.kr.cdnetworks.com.cdngc.net.  20  IN  A  61.110.226.28   www.kr.cdnetworks.com.cdngc.net.  20  IN  A  61.110.226.15     ;;  AUTHORITY  SECTION:   cdngc.net.    68200  IN  NS  ns2.panthercdn.com.   cdngc.net.    68200  IN  NS  ns1.panthercdn.com.     ;;  ADDITIONAL  SECTION:   ns1.panthercdn.com.  64021  IN  A  205.252.255.11   ns2.panthercdn.com.  48212  IN  A  67.72.21.11 PHPFest  2011   17  
  • 18. DNS  lookup  example Root  DNS  (.com,  .net)   “What’s  DNS  Server  IP  address  of  cdnetworks.com?”   “What’s  IP  address  of  www.kr.cdnetworks.com?”   Resolver   DNS  for  cdnetworks.com   End  User   Local  DNS   Browser   “www.kr.cdnetworks.com  is  (CNAME)          www.kr.cdnetworks.cdngc.net”   PHPFest  2011   18  
  • 19. DNS  lookup  example Root  DNS  (.com,  .net)   “What’s  DNS  Server  IP  address  of  cdnetworks.com?”   “What’s  DNS  Server  IP  address  of  cdngc.net?”   “What’s  IP  address  of  www.kr.cdnetworks.com?”   Resolver   DNS  for  cdnetworks.com   End  User   Local  DNS   Browser   “www.kr.cdnetworks.com  is  www.kr.cdnetworks.cdngc.net”   DNS  for  cdngc.net  (GSLB)   “What’s  IP  address  of  www.kr.cdnetworks.com.cdngc.net?”   “61.110.226.28  and  61.110.226.15”  (IP  of  Cache  Servers)   PHPFest  2011   19  
  • 20. Object  delivery  and  whole  site  delivery   Object  delivery   •  Only  serves  specified  file  (image,  video,  js,  css)  and  sZll  other  page  is  served  fr om  origin  site hAp://www.kr.cdnetworks.com/index.php www.kr.cdnetworks.com   !=  images.kr.cdnetworks.com hAp://images.kr.cdnetworks.com/images/common/main_logo.gif PHPFest  2011   20  
  • 21. Object  delivery  and  whole  site  delivery   Whole  Site  Delivery   •  CDN  covers  whole  site  –  including  objects,  dynamic  pages  etc.   •  Need  more  aAenZon  –  what  is  cacheable  and  not  cacheable  not  to  break  sites   hAp://www.kr.cdnetworks.com/index.php www.kr.cdnetworks.com   ==  www.kr.cdnetworks.com hAp://www.kr.cdnetworks.com/images/common/main_logo.gif PHPFest  2011   21  
  • 22. Cacheable  and  non-­‐cacheable   Objects  are  cacheable   •  In  Edge  Cache  Server   •  In  Proxy  Cache  in  ISP  or  your  network   •  In  Browser  Cache   •  TTL  (Time  To  Live)  –  lifeZme  in  Edge  Cache   •  Images,  Videos,  Documents,  CSS,  Javascript   •  Not  changed  by  me,  locaon,  session,  cookie,  browser     Objects  are  non-­‐cacheable   •  Dynamic  response  from  PHP/JSP/ASP/…   •  Cannot  be  stored  in  Edge  Cache/Proxy/Browser  Cache   •  Dynamically  generated  HTML  pages,  AJAX  response,  API   •  Same  URL  but  different  contents  by  me,  locaon,  session,  cookie,  browser   PHPFest  2011   22  
  • 23. Cache  Control   You  can  control  cache-­‐ability  of  objects  using  various  headers  in  HTTP  resp onse.   •  CDN  Edge  Cache   •  Browser  Cache  (local  PC)     2  Basic  Status   •  Cache  Hit:  when  cache  already  has  the  object   •  Cache  Miss:  cache  will  pull  the  object  from  origin  and  store     Cache  related  headers   •  Last-­‐Modified,  Etag   •  Cache-­‐Control   •  Pragma   •  Vary   •  Expires     Cache/Proxy  related  headers   •  Via,  Age   PHPFest  2011   23  
  • 24. Example  of  non-­‐cacheable  object %  curl  -­‐I  http://www.naver.com     HTTP/1.1  200  OK   Date:  Thu,  26  May  2011  12:23:01  GMT   Server:  Apache   Cache-­‐Control:  no-­‐cache,  no-­‐store,  must-­‐revalidate   Pragma:  no-­‐cache   P3P:  CP="CAO  DSP  CURa  ADMa  TAIa  PSAa  OUR  LAW  STP  PHY  ONL  UNI  PUR  FIN  COM  NAV  INT  DEM  STA  PRE"   Cache-­‐Control:  no-­‐cache,  no-­‐store,  must-­‐revalidate   Pragma:  no-­‐cache   Vary:  Accept-­‐Encoding,User-­‐Agent   Connection:  close   Content-­‐Type:  text/html;  charset=UTF-­‐8 PHPFest  2011   24  
  • 25. Example  of  non-­‐cacheable  object  –  from  iPod? %  curl  -­‐I  -­‐A  "Mozilla/5.0  (iPod;  U;  CPU  iPhone  OS  4_3_1  like  Mac  OS  X;  e n-­‐us)  AppleWebKit/533.17.9  (KHTML,  like  Gecko)  Version/5.0.2  Mobile/8G4   Safari/6533.18.5"  http://www.naver.com   HTTP/1.1  302  Found   Date:  Thu,  26  May  2011  12:37:32  GMT   Server:  Apache   Location:  http://m.naver.com   Vary:  Accept-­‐Encoding   Connection:  close   Content-­‐Type:  text/html;  charset=iso-­‐8859-­‐1 PHPFest  2011   25  
  • 26. How  to  make  non-­‐cacheable  object  in  PHP   Using  header()  funcZon     <?php   header(“Cache-­‐Control:  no-­‐cache,  no-­‐store,  must-­‐revalidate”);   header(“Pragma:  no-­‐cache”);   header(“Vary:  Accept-­‐Encoding,  User-­‐Agent”);   ?>   Hello  World     PHPFest  2011   26  
  • 27. How  to  make  non-­‐cacheable  object  in  PHP %  curl  -­‐D-­‐  http://www.kr.freebsd.org/~cjh/phpfest2011/nc.php   HTTP/1.1  200  OK   Date:  Thu,  26  May  2011  13:09:11  GMT   Server:  Apache/1.3.41  (Unix)  mod_perl/1.31  DAV/1.0.3  PHP/4.4.9  with  Suho sin-­‐Patch  mod_ssl/2.8.31  OpenSSL/0.9.7e-­‐p1   MS-­‐Author-­‐Via:  DAV   X-­‐Powered-­‐By:  PHP/4.4.9   Cache-­‐Control:  no-­‐cache,  no-­‐store,  must-­‐revalidate   Pragma:  no-­‐cache   Vary:  Accept-­‐Encoding,  User-­‐Agent   Transfer-­‐Encoding:  chunked   Content-­‐Type:  text/html;  charset=euc-­‐kr     Hello  World   PHPFest  2011   27  
  • 28. How  to  make  non-­‐cacheable  object  in  PHP  (2) <?php   header(“Cache-­‐Control:  no-­‐cache,  no-­‐store,  must-­‐revalidate”);   header(“Pragma:  no-­‐cache”);   header(“Vary:  Accept-­‐Encoding,  User-­‐Agent”);     if  (strstr($_SERVER["HTTP_USER_AGENT"],  "iPhone  OS"))  {          print  "<h1>Hello  iOS</h1>";          print  "<h1>Hello  iOS</h1>";          print  "<h1>Hello  iOS</h1>";          exit;   }   ?>   Hello  World     PHPFest  2011   28  
  • 29. Example  of  cacheable  object %  curl  -­‐I  'http://static.naver.com/www/u/2010/0611/nmms_215646753.gif'   HTTP/1.1  200  OK   Date:  Thu,  26  May  2011  12:27:30  GMT   Server:  Apache/2.0.52   Last-­‐Modified:  Fri,  11  Jun  2010  12:56:46  GMT   ETag:  "a06-­‐abe73f80"   Accept-­‐Ranges:  bytes   Content-­‐Length:  2566   TTL  is  7  day   Cache-­‐Control:  max-­‐age=604800   Content-­‐Type:  image/gif   Via:  1.1  SI2286-­‐239  (Jaguar/3.0-­‐62)   Age:  3   Expires:  Thu,  02  Jun  2011  12:27:23  GMT PHPFest  2011   29  
  • 30. Example  of  cacheable  object  in  CDN  Server %  curl  -­‐I  'http://static.naver.com/www/ %  curl  -­‐I  'http://static.naver.com/www/ u/2010/0611/nmms_215646753.gif'   u/2010/0611/nmms_215646753.gif'   HTTP/1.1  200  OK   HTTP/1.1  200  OK   Date:  Thu,  26  May  2011  12:27:30  GMT   Date:  Thu,  26  May  2011  12:31:23  GMT   Server:  Apache/2.0.52   Server:  Apache/2.0.52   Last-­‐Modified:  Fri,  11  Jun  2010  12:56:4 Last-­‐Modified:  Fri,  11  Jun  2010  12:56:4 6  GMT   6  GMT   ETag:  "a06-­‐abe73f80"   ETag:  "a06-­‐abe73f80"   Accept-­‐Ranges:  bytes   Accept-­‐Ranges:  bytes   Content-­‐Length:  2566   Content-­‐Length:  2566   Cache-­‐Control:  max-­‐age=604800   Cache-­‐Control:  max-­‐age=604800   Content-­‐Type:  image/gif   Content-­‐Type:  image/gif   Age:  3     Age:  53     Expires:  Thu,  02  Jun  2011  12:27:23  GMT   Expires:  Thu,  02  Jun  2011  12:30:30  GMT   Age:  header  value  is  residing  Zme  (second)  in  Edge  Cache.   In  this  case  this  object  will  stored  in  Edge  Cache  for  7  day   (604800  sec). PHPFest  2011   30  
  • 31. How  to  make  cacheable  object  in  PHP <?php   header("Cache-­‐Control:  max-­‐age=604800");  //  tell  CDN  cache  to  store  object  f or  next  24  hours   header("Content-­‐Type:  text/plain");   header("Content-­‐Length:  ".filesize("test.txt"));   readfile("test.txt");   ?>     %  curl  -­‐D-­‐  http://www.kr.freebsd.org/~cjh/phpfest2011/c.php   HTTP/1.1  200  OK   Date:  Thu,  26  May  2011  13:35:32  GMT   Server:  Apache/1.3.41  (Unix)  mod_perl/1.31  DAV/1.0.3  PHP/4.4.9  with  Suhosin-­‐ Patch  mod_ssl/2.8.31  OpenSSL/0.9.7e-­‐p1   MS-­‐Author-­‐Via:  DAV   X-­‐Powered-­‐By:  PHP/4.4.9   Cache-­‐Control:  max-­‐age=604800   Content-­‐Length:  17   Content-­‐Type:  text/plain;charset=euc-­‐kr     THIS  IS  TEST.TXT   PHPFest  2011   31  
  • 32. How  to  make  cacheable  object  in  PHP  (2) HTTP/1.1  200  OK   HTTP/1.1  200  OK   Date:  Thu,  26  May  2011  15:28:06  GMT   Date:  Thu,  26  May  2011  15:28:15  GMT   Server:  PWS/1.7.2.3   Server:  PWS/1.7.2.3   Cache-­‐Control:  max-­‐age=604800   Cache-­‐Control:  max-­‐age=604800   Expires:  Thu,  02  Jun  2011  15:28:07  GMT   Expires:  Thu,  02  Jun  2011  15:28:06  GMT   Age:  0     Age:  9   Content-­‐Length:  17     Content-­‐Length:  17   Content-­‐Type:  text/plain;charset=euc-­‐kr   Content-­‐Type:  text/plain;charset=euc-­‐kr   Connection:  keep-­‐alive   Connection:  keep-­‐alive       THIS  IS  TEST.TXT THIS  IS  TEST.TXT As  you  can  see  now  this  URL  is  cached  in  Edge  Cache,  although  this  page   is  generated  by  PHP.   Also  check  origin  server  if  access  from  cache  exists    should  be  none PHPFest  2011   32  
  • 33. CDN  &  Cloud   Cloud  CompuZng  provide  very  similar  purpose  of  CDN  such  as  reliability  an d  scalability,  but  not  helpful  to  solve  other  problems  such  as  Network  Dist ance  (middle  mile)  problem   •  Cloud:  Most  servers  are  located  in  ONE  locaZon     Combining  CDN  with  Cloud  service   •  Cloud  CompuZng  can  solve  a  lot  of  origin  issue  such  as  scalability   •  CDN  can  provide  fast  access  to  cacheable  objects   •  For  high  performance,  global-­‐accessed  websites   •  Example   −  Origin  Server  use  VM  Cloud  and  Storage   −  Use  CDN  for  caching  and  low  latency     Cloud  Service  company  has  compeZng  products  with  CDN   •  Amazon’s  S3  storage  +  CloudFront   PHPFest  2011   33  
  • 34. Example:  CloudSleuth.net PHPFest  2011   34  
  • 35. Example:  CloudSleuth.net PHPFest  2011   35  
  • 36. Other  keywords   ApplicaZon  Delivery     WAN  AcceleraZon/OpZmizaZon     Edge  CompuZng     Web  Page  OpZmizaZon     Mobile  OpZmizaZon     …   Thank  you!   PHPFest  2011   36