ããã¯Chrome Turboï¼Google Silkï¼ Androidã§SPDYã使ã£ãData Compression Proxyã試ã
1. ã¯ããã«ã
æ¬æ¥æ©æãAndroid ã® Chrome ã®ãã¼ã¿çãã¢ãããã¼ããããã¼ã¸ã§ã³26ã«ãªãã¾ããã
ããã«ä¼´ããGoogleãã Chrome ã® SPDY Proxyã®æ©è½ã¨ãGoogleãæä¾ãã Page Speed ãµã¼ãã¹ãçµã¿åãããData Compression Proxy ã¨ããå®é¨ãµã¼ãã¹ã®ã¢ãã¦ã³ã¹ããããæ©é使ã£ã¦ãããã調ã¹ã¦ã¿ã¾ããã
2. Data Compression Proxyã¨ã¯ä½ï¼
ãã®Data Compression Proxyã¯ã©ããããã®ã§ããããï¼
Googleã®æ¡å
ãã¼ã¸ã«è¨è¼ããã¦ããä¸è¨ã®å³ãä¸çªããããããã§ã
Andoroid端æ«ããData Compression Proxyãæå¹åããChromeï¼ãã¼ã¿çï¼ã使ã£ã¦Webãã¼ã¸ã«ã¢ã¯ã»ã¹ãããã¨ã
- HTTPSã¯ãããã¾ã§éãAndroid端æ«ããç´æ¥ãµã¼ãã¸ã¢ã¯ã»ã¹ããã
- HTTPã¯ãä¸åº¦ Google ãç¨æããProxyãµã¼ããçµç±ãã¦ãµã¼ãã«ã¢ã¯ã»ã¹ãããã
- Android端æ«ã®Chromeã¯ãSPDY Proxyæ©è½ã使ã£ã¦ãProxyãµã¼ãã¨SPDYæ¥ç¶ãããã
- Proxyãµã¼ãã§ã¯ãAndroid端æ«ãããªã¯ã¨ã¹ããåããã³ã³ãã³ãã対象ãµã¼ãããåå¾ããPageSpeed æè¡ã使ã£ã¦ãã¼ã¿éãæ¸ãããã³ã³ãã³ããã¯ã©ã¤ã¢ã³ãã«è¿ãã¾ããProxyãµã¼ãå ã§ã¯ã³ã³ãã³ãã®ãã£ãã·ã¥ãè¡ãªããã¾ãã
ã¨ãã£ããã¨ãå®ç¾ã§ãã¾ãã
ä¸è¨ã®Page Speedã¯ãã³ã³ãã³ãã®ç¡é§ãªé¨åãåé¤ãå§ç¸®ãä½å®¹éã®ç»åãã©ã¼ãããã¸ã®å¤æãªã©ãè¡ãæ©è½ã§ããGoogleã¯ãããã¾ã§ããTurbocharge your web site with Google's PageSpeed Serviceãã¨ãããªãã¼ã¹Proxyã®è©¦é¨ãµã¼ãã¹ãæä¾ãã¦ãã¾ãããä»åã¯ããã¨åæ§ã®ãã©ã¯ã¼ãProxyç¸å½ã®ãã®ã ã¨æããã¾ã(ããããAndroid端æ«åãã«ã³ã³ãã³ãå§ç¸®ã®æé©åãè¡ããã¦ããã§ãããï¼ã
SPDY Proxyæ©è½ã¯ã以åãããã¹ã¯ãããçã§ãæä¾ããã¦ããæ©è½ã§ãï¼SPDY & Secure Proxy Support in Google Chromeï¼ã åããå´ã®Proxyãµã¼ãããNode.jsã§ä½ã£ã試é¨çãªå®è£ ã(node-spdyproxy)ãå ¬éããã¦ãã¾ããä»åããã®Proxyæ©è½ã«ãPageSpeed+ãã£ãã·ã¥ç®¡çæ©è½ãã¤ãã¦Googleããµã¼ãã¹ãæä¾ãå§ãããã¨æããã°ããã§ãããï¼ãããã«Nodeã使ã£ã¦ããã¨ã¯æãã¾ãããï¼ã
éå»ãåæ§ã®æ©è½ã Amazon Silk ã Opera Turboï¼SPDY support for Turboï¼ ã§å®ç¾ããã¦ãã¾ããã ä»åããã® Google Chromeçãåºãã¨è¨ãã¾ãã
3. Chrome Beta for Android ã® SPDY Proxyã使ã
ã§ã¯æ©é使ã£ã¦ã¿ã¾ããããç¾å¨ææ°ã® Chrome Beta for Android (26.0.1410.26) ãã¤ã³ã¹ãã¼ã«ãã¦ã¿ã¾ãã
chrome://flags ã§ä¸è¨ã®éã Data Compression Proxy ã®æ©è½ãæå¹ããã¨ä½¿ãã¾ãã
ããã¤ãHTTPã®ãã¼ã¸ãé²è¦§ãã¦ãchrome://net-internals/#spdy ãè¦ã¦ã¿ã¾ãã
flywheel.ext.google.com å®ã«SPDYã»ãã·ã§ã³ãå¼µããã¦ãã¾ãããã®ãµã¼ã(flywheel.ext.google.com)ãã Data Compression Proxy ã§ãã
PageSpeed ã§ã©ãã ããã¼ã¿ãå§ç¸®ããã¦ããããããï¼ ããã¯ãchrome://net-internals/#bandwidth ã§è¦ããã¨ãã§ãã¾ãã
åé
ç®ã¯ããªãªã¸ãã«ã®ã³ã³ãã³ãã®å®¹éãå®éã«åãåã£ã容éãData Compression Proxyã§æ¸ã£ããã¼ã¿éãData Compression Proxyã§æ¸ã£ããã¼ã¿ã®å²åã表ãã¾ãã
ããã«ããã¨ãä¸è¨ã®å ´åä¸ã¤ã®æ¥ç¶ã§ãªãã¨72.6%ãåä¿¡ãã¼ã¿éãæ¸ãããã¨ãã§ããã®ã§ããData Compression Proxyãçµç±ããã¨ãªãªã¸ãã«ã®ãã¼ã¿éã®ã»ã¼1/4ã¾ã§å§ç¸®ãããã¨ã¯é©ãã§ã(Webp ã®æè¡è©³ç´°ã¯ã¾ã ä¸åå¼·ã§ç¥ããªãã®ã§ããããã£ã¨ãã®ããããªãã§ããããï¼ã
4. ã©ããªæãã§åãã¦ããã®ããªï¼
ã§ã¯ãã©ããªæãã§åãã¦ããã®ãããµã¼ãå´ãã¯ã©ã¤ã¢ã³ãå´ãããã¼ã¿ãè¦ãã¦æ¢ã£ã¦ã¿ã¾ãããã ããç»åãã¼ã¿ã®HTTPãµã¼ãå´ã®ãã±ãããã³ããåå¾ãã¾ããã
HTTPãµã¼ãã¸ã¢ã¯ã»ã¹ããã¯ã©ã¤ã¢ã³ãIPã¯ãå½ç¶Googleã®ãµã¼ãã®IPã«ãªã£ã¦ãã¾ãããã®æ¿ã X-Forwarded-For ã®ãããã«å®éã®ã¯ã©ã¤ã¢ã³ãã®IPã¢ãã¬ã¹ãè¨è¼ããã¦ãã¾ãããµã¼ãããè¿ããã¬ã¹ãã³ã¹ã®ãã¡ãéä¸ç·ã®é¨åãå¾ã§æ¸ãæãããã¡ããé¨åã§ãã
ä»åº¦ã¯ã¯ã©ã¤ã¢ã³ãå´ã§åä¿¡ããåãç»åãã¡ã¤ã«ã®ãã£ãã·ã¥ãã¼ã¿ããã¬ã¹ãã³ã¹ããããè¦ã¦ã¿ã¾ãã
Google Proxy ãçµç±ãããã¨ã§ãContent-Typeã jpeg ãã webp ã«å¤ãã£ã¦ãã¾ãï¼å½ç¶ç»åãã¼ã¿ã®ãã©ã¼ããããWebpã«å¤ãã£ã¦ããã¯ãï¼ãããã«ä¼´ãã Content-Length, Etagãå¤æ´ããã¦ãã¾ããããã¦æ°ãã« cache-control, vary, x-origin-content-length ã®ããããä»ä¸ããã¦ãã¾ããGoogleå´ããã¯ã©ã¤ã¢ã³ãã«æå®ãããã³ã³ãã³ããã£ãã·ã¥æéã¯ããã©ã«ãã§30åã®æ§ã§ãã
æ°ãã«ä»ãããã -origin-content-length ã¯ããµã¼ãå´ã§éã£ã content-length ã¨ä¸è´ãã¾ãã®ã§ããã£ã¨ããããªãªã¸ãã«ã®ãã¼ã¿å®¹éã表ããã®ã§ããããå ã»ã©ã® bandwidth ã®çµ±è¨æ å ±ã¯ããã®ã¯ã©ã¤ã¢ã³ãå´ã§åä¿¡ãã content-length 㨠x-origin-content-length ã®å¤ã®çµ±è¨ãåã£ããã®ã¨æããã¾ãã
ãããã試ãã¦ãµã¼ãå´ã§ç¢ºèªããã¨ãGoogle Proxyãµã¼ãå´ãã³ã³ãã³ããã£ãã·ã¥ãä¿æãã¦ããéã¯ãHTTPãµã¼ãå´ã« etag ã®å¤æ´ã確èªãã«æ¥ãããã§ããä¸åº¦ãã£ãã·ã¥ãããã¨ãå½å HTTPãµã¼ãå´ã 304(Not Modified)ãè¿ãã¾ãã ããããä½ã§ãããã§ããã£ãã·ã¥ããããã§ã¯ãªãããã§ãã HTTPãµã¼ãå´ã etag ãè¿ããªãã£ããããã¼ãã£ãã·ã¥ã®ããããè¿ãããããã¨ã Google Proxy çµç±ãã¦ãä½ããã¼ã¿å§ç¸®ãè¡ããã«ãã®ã¾ã¾ã¯ã©ã¤ã¢ã³ãã«åãå½¢å¼ã§ãã¼ã¿ãè¿ããã¾ããã
ä»æ¹ãHTMLãã¡ã¤ã«ã®ã¿ã¤ã ã¹ã¿ã³ãã ããå¤ã Etag ãæ´æ°ãã¦ã¿ãã¨ã HTMLãã¡ã¤ã«ã¯åå¾ããã®ã§ãããç»åãã¡ã¤ã«ãåå¾ãã«æ¥ã¾ããããã£ã±ãã³ã³ãã³ãã®ä¸èº«ãè¦ã¦ããã®ã§ããããï¼ï¼è¬ï¼
以ä¸ã詳細ä»æ§ã¯ä¸æã§ãããã§ããã ãã¯ã©ã¤ã¢ã³ãå´ã®ã¬ã¹ãã³ã¹ãæ©ãããã¤HTTPãµã¼ãå´ã®æ´æ°ã«ãåããããããªæ§ã ãªå·¥å¤«ãããã¦ããããã§ãã
5. å®ééããªãã®ï¼
ãããã©ã®ç¨åº¦æ©ããªãã®ãï¼ æ°ã«ãªãã¨ããã§ãã
以åæ¸ããè¨äºã個人のページでこっそりSPDYを使ってみたらãã®HTTPã®èªã¿è¾¼ã¿æ¸¬å®ããããã¼ã¸(http://html5.ohtsu.org/spdy_test_20130207/without_spdy/)ã使ã£ã¦ãã³ããã¦ã¿ã¾ãã
対象ãã¼ã¸ã¯64kbyteã®ç»åã30æè²¼ã£ã¦ããåç´ãªãã®ã§ãNavigation Timing API ã使ã£ã¦èªã¿è¾¼ã¿æéãåå¾ãã¦ãã¾ããåºå®ã®URLãªã®ã§ã¯ã©ã¤ã¢ã³ãå´ã®ãã£ãã·ã¥ã«æ®ã£ã¦ãã¾ãã¾ãããæ¯åã¯ã©ã¤ã¢ã³ãå´ã®Chromeãã¼ã¿ããã¼ã¿æ¶å»ãã¦æ¸¬å®ãã¾ããã
以ä¸ãé«éãªWIFIç°å¢ã¨ä½éãª3G(128kbps)ã§æ¯ã¹ãçµæã§ããData Compression Proxy æã¯ãSPDY Proxyã使ã£ã¦ããã®ã§å½ç¶TCPãã³ãã·ã§ã¤ã¯ã®ãªã¼ããããã¯ããã¾ããã
WIFIç°å¢ã§ã®ãã¼ã¸èªã¿è¾¼ã¿æéæ¯è¼
3G 128kbpsç°å¢ã§ã®ãã¼ã¸èªã¿è¾¼ã¿æéæ¯è¼
æï¼ç¡ ï¼ 0.18 : 1
çµæ§å¹æã表ãã¦ã¾ãï¼
ããããä½åã試ãã¨å¤ã«ãã©ã¤ããåºã¦ãæ¯åå¿ ããã Data Compression Proxy ã®æ¹ãéãã¨ã¾ã è¨ãåãã¾ãããçµæãå¤ããåå ã¨ãã¦ãGoogle Proxyãµã¼ãããã®RTTãã³ã³ãã³ããã£ãã·ã¥ã®æç¡ãPageSpeedå¤æå¹æããªã¼ãããããªã©æ§ã ãªè¦å ãèãããã¾ãã
ããã«ãè¤æ°ç«¯æ«ã®è©¦é¨ãè¡ãã¦ããªãã®ã§ããããã£ãã·ã¥ã¯è¤æ°ç«¯æ«éã§å
±æãããã®ãå¦ãã¨ããé¨åãæ°ã«ãªãã¾ãã
ããããã¨çã使ãã°å
¨é¨ãã£ãã·ã¥ããããã§ãç¥ããªã人ã¨ãã£ãã·ã¥ãå
±æããã®ã¯ããæ°æã¡æªããããã使ãã¨ãã¯ãæ©å¯ã³ã³ãã³ãã絶対ã«HTTPSã«ããªãã¨ãã¡ã§ããã
ã¾ã ã¾ã æªç¥æ°ãªé¨åã¯ãã£ã±ãããã¾ããããã°ãããã®ç¶æ ã§ä½¿ã£ã¦ã¿ã¦æ¬å½ã«é«éåãä½æã§ããã試ãã¦ã¿ããã¨æãã¾ãã