2011-04-10
2023å¹´03æ31æ¥è¿½è¨ï¼ãã®è¨äºãåºã«ã@sadnessOjisanãããããã³ã¼ãã¬ãã«ã«ããè¸ã¿è¾¼ãã ããã¤ãã°ãªã¼ã³ã¹ã¬ãããã¼ã¹ã®æ°ããWebãµã¼ãã¢ã¼ããã¯ãã£ãå«ãã¦æ´çãããè¨äº Webãµã¼ãã¼ã¢ã¼ããã¯ãã£é²åè«2023 | blog.ojisan.io ãå ¬éããã¾ããã 主ã«æ°åã®Webã¨ã³ã¸ãã¢åãã«ãå¤å ¸çãªWebãµã¼ãã¢ã¼ããã¯ãã£ãå¦ã¶éã®ãã¨ä»£è¡¨çãªå®è£ ã¢ãã«ã®æ¦è¦ãç´¹ä»ãã¾ãã ãã®è¾ºãã®è©±é¡ãWebçéã§æµè¡ã£ã¦ããã®ã¯æ°å¹´ä»¥ä¸åã¨ããã¤ã¡ã¼ã¸ã§ãããWebãµã¼ãã¹ã¯ç¸å¤ãããWebãµã¼ãã®ä¸ã§åãã¦ããã®ã§ãæµè¡ãå»ãé¢ä¿ãªãå¦ã¶ã¹ãå 容ã ã¨æã£ã¦ãã¾ãã ã¾ããHTTP/2ãããããRFCåããæ¢ã«h2oãtrusterdãªã©ã®HTTP/2ã®ãµã¼ãå®è£ ããããä»å¾Webãµã¼ãã¢ã¼ããã¯ãã£ãå訪ãããã¨ãå¢ãããããªæ°ããã¦ãã¾ãã ã¨ããããWe
第3ä¼FRESHåå¼·ä¼ã§çºè¡¨äºå®ã®ã¹ã©ã¤ããHTTPã«ã¤ãã¦è©³ãããªã人ã®ããã« HTTPã®æ¦è¦ããå æ¥RFCåãããHTTP/2ã®æ°æ©è½ã使ãã©ããã解説ãã¾ãã
Intro ä»æãã¤ãã«ãã£ã¨çå®ä½æ¥ãè¡ããã¦ãã HTTP/1.1 ã®å¾ç¶ä»æ§ã§ãã HTTP2 ã¨ã é¢é£ä»æ§ã§ãã HPACK ãã RFC ã¨ãã¦å ¬éããã¾ããã ã¤ãã« HTTP2 RFC 7540 åºãï¼ï¼ #http2study / ârfc7540.txtâ http://t.co/CuaVul98l3â Jxck (@Jxck_) 2015, 5æ 14 ããããçªå·ã¯ 7540 㨠7541 ã«ãªãã¾ãã RFC7540 - Hypertext Transfer Protocol Version 2 (HTTP/2) RFC7541 - HPACK: Header Compression for HTTP/2 ã¡ãªã¿ã« HTTP/2.0 ã§ã¯ãªã HTTP/2 ãæ£å¼å称ã§ãã(ãã¤ãã¼ãã¼ã¸ã§ã³ã¢ããã§ã® HTTP/2.1 ãªã©ã¯ããã¾ãã) äºå¹´å HTTP2 ã®
11. Frame ã®å®ç¾© 0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | R | Length (14) | Type (8) | Flags (8) | +-+-+-----------+---------------+-------------------------------+ |R| Stream Identifier (31) | +-+-------------------------------------------------------------+ | Frame Payload (0...) ... +----------------
When youâre developing with Ruby, itâs pretty inevitable that at some point you come across an HTTP API that doesnât have a gem available. While writing Hopefully Sunny I ran into just that situation with World Weather Onlineâs weather API. Itâs often really tempting to go searching for a different API to use instead, but itâs actually not so hard to just write your own wrapper library. Letâs take
HTTP header fields are a list of strings sent and received by both the client program and server on every HTTP request and response. These headers are usually invisible to the end-user and are only processed or logged by the server and client applications. They define how information sent/received through the connection are encoded (as in Content-Encoding), the session verification and identificat
ä»å¹´è²·ã£ãè¯ãã£ããã©ããåãããªããã® ãã®å£ç¯ã«ãªãã¨ãä»å¹´è²·ã£ã¦ããã£ããã®ãã¨ãã話é¡ã§ããã°ãSNSãè³ããã®ã ãã©ãä»å¹´ã«é¢ãã¦ã¯è²·ã£ã¦ããã£ããã®ä»¥åã«ããããããã¾ãè²·ãç©ãããªãã£ãã â¦ã¨è¨ããä»å¹´ã«éããããæ°å¹´ãæ¯ãè¿ã£ã¦ãå ¨ç¶å¤§ããªè²·ãç©ããã¦ããªããå¼·çã«æ¬²ãããã®ãâ¦
Ruby ä¸ã§ http ãå©ããéä¿¡è¦ããæã«ãæ¯ååãäºããã£ã¦ãã®ã§æ½è±¡åã㦠http-dump ã¨ããã©ã¤ãã©ãªãä½ã£ãã https://github.com/hotchpotch/http-dump $ gem install http-dump require 'net/http' require 'uri' require 'http-dump' HTTPDump.dump { Net::HTTP.get(URI('http://example.com')) } 㨠http ã§ããã¨ããã¦ãã³ã¼ãã block ã§å²ãã¨ã以ä¸ã®ããã«åºåãããã > GET http://example.com/ with headers {'Accept'=>'*/*', 'Accept-Encoding'=>'gzip;q=1.0,deflate;q=0.6,identity;q=
è¿½è¨ @jovi0608 ããã«é常ã«ä¸å¯§ã«ã³ã¡ã³ããããã ãã¾ããã https://gist.github.com/shigeki/ba7941d114344ddd4b01 æ¬æ CROSS 2014ã®æ¬¡ä¸ä»£Webã»ãã·ã§ã³ã«åå ããã ããããåºæ¿ãåããã®ã§ãç¹ã«ãWebã¢ããªã±ã¼ã·ã§ã³ãéçºã»éç¨ããä¸ã§ãä»å¾ã©ãå½±é¿ãã¦ããã ããã¿ãããªè¦ç¹ã§æ´çãããã¨ãæ¸ãã¦ã¿ãã 次ä¸ä»£Webã»ãã·ã§ã³ã¯å»å¹´ãUSTã§è¦ã¦ã¦ããã£ã¡ãé¢ç½ãã£ãã®ã§ãä»å¹´ã¯çã§èãã«æ¥ãã å»å¹´ã®ã»ãã·ã§ã³ã®è°è«ã¯ã naoyaããã®è¨äºãé°å²æ°ãããããããã£ãã Webã¯ã¤ã³ã¿ã¼ãããã«ãªã£ã - naoyaã®ã¯ã¦ãªãã¤ã¢ãªã¼ å»å¹´ãSPDYã®å 容ã¨ã追ã£ã¦ã¦ãHTTP/1.1ã¨ä½ãéãã®ãã¿ãããªãã¨ã調ã¹ã¦æ¸ããããã¦ãã SPDYã§è¤æ°ã®TCPã³ãã¯ã·ã§ã³ãã²ã¨ã¤ã«ã¾ã¨ããã¨ã¯ã©ããããã¨ã -
HTTP/2 (Hypertext Transfer Protocol version 2) ã¯ãWorld Wide Webã§ç¨ãããã¦ããHypertext Transfer Protocolã®ãã¼ã¸ã§ã³ã®ä¸ã¤ã§ããã HTTP/2ã¯IETFã®Hypertext Transfer Protocol Bis (httpbis)ã¯ã¼ãã³ã°ã°ã«ã¼ãã«ããã¦å¶å®ãã[1]ã2015å¹´2æ17æ¥ã«æ£å¼ãªä»æ§ã¨ãã¦æ¿èªãã[2]ã2015å¹´5æã« RFC 7540 ã¨ãã¦ææ¸åããããHTTP/2ã¯HTTP/1.1ã1999å¹´6æã« RFC 2616 ã¨ãã¦è¦å®ããã¦ä»¥æ¥16å¹´ã¶ãã®ãã¼ã¸ã§ã³ã¢ããã§ããã 2022å¹´ãå 容ãæ´æ°ãã RFC 9113 ãå ¬éãããã HTTP/2ã®ç®æ¨ã¯HTTP/1.1ã®ãã©ã³ã¶ã¯ã·ã§ã³ã»ã»ãã³ãã£ã¯ã¹ã¨ã®å®å ¨ãªå¾æ¹äºææ§ãç¶æããã¾ã¾éåæãªæ¥ç¶ã®å¤éåããã
HTTPã®ãªã¯ã¨ã¹ãã¯ãJava, JavaScript, PHP, Objective-Cãªã© æ§ã ãªè¨èªããã¬ã¼ã ã¯ã¼ã¯ã使ã£ã¦éä¿¡ãããµã¼ãã¹éçºããå¤ã è¡ã£ã¦ãã¾ããã ã§ããHTTPãªã¯ã¨ã¹ãã«ã¤ãã¦ã¡ããã¨ç¥ã£ã¦ããã¨è¨ãã¨ããã§ã¼ãªæãã§ã ä»åã¯ãHTTPãªã¯ã¨ã¹ãã«ã¤ãã¦å¦ãã ã®ã§ããã®å 容ãããã°ã«æ¸ãããã¨æãã¾ãã HTTPãªã¯ã¨ã¹ãã®æ§æ HTTPãªã¯ã¨ã¹ãã¯ã大ãã3ã¤ã®é¨åã«åãããããã§ãã HTTPãªã¯ã¨ã¹ãè¡ HTTPãããã¼è¡ HTTPããã£é¨ GETéä¿¡ã§ã¯ãä¸è¨ã®ãã¡ãHTTPãªã¯ã¨ã¹ãè¡ãã¨ãHTTPãããã¼è¡ããéä¿¡ãã¦ã POSTéä¿¡ã§ã¯ããHTTPãªã¯ã¨ã¹ãè¡ãã¨ãHTTPãããã¼è¡ãã¨ãHTTPããã£é¨ããéä¿¡ããããã§ãã å ·ä½çãªæ§é ã¯ä»¥ä¸ã¨ãªã£ã¦ããããã§ãã HTTPãªã¯ã¨ã¹ãã®ä¸èº«ã¯ãå ·ä½çã«ã¯ä»¥ä¸ã®ãããªå 容ã®ããã§ãã ï¼G
AWSã¢ããã³ã¹ãã³ã³ãµã«ãã£ã³ã°ãã¼ããã¼ã®ä¸å¡ã¨ãã¦æ´»åããæ ªå¼ä¼ç¤¾ã¹ã¿ã¤ã«ãºããAWSå°å ¥ã移è¡ãéçºãã»ãã¥ãªãã£ãéç¨ä¿å®ãªã©ããã¹ã¦ã®ãç¸è«ã«ä¹ããã¦ããã ãã¾ãã AWSãå°å ¥ããããä½ããå§ããããããããããªã æ¢åã®ãã³ãã¼ãæ°æè¡ã«å¼±ããè¯ãææ¡ãããããªã ã¯ã©ã¦ãã®å°å ¥ã«ã»ãã¥ãªãã£ã®ä¸å®ããã AWSãã¨ããããå°å ¥ããããããã«æ´»ç¨ãã¦ãããã 社å ã«AWSã®ç¥è¦ãæã£ã¦ãã人ãããªã AWSãªãã§ã¯ã®ã·ã¹ãã éçºã詳ããç¥ããã
éåæãªã¯ã¨ã¹ãã使ç¨ããã¨ãåºåãä½æãã¦ããããã¯ãããã¨ãªãè¤æ°ã®åºåãªã¯ã¨ã¹ããéä¿¡ã§ãã¾ãããªã¯ã¨ã¹ãå®äºå¾ã«å¼ã³åºãURLãæå®ããããã¾ãã¯ãªã¯ã¨ã¹ãã®ã¹ãã¼ã¿ã¹ã確èªãã¾ããåºåããªãã¡ã¬ã³ã¹ãã覧ãã ããã ããããªã¯ã¨ã¹ãã¯ãåºåã管çããããã®æãå¹ççãªæ¹æ³ã§ããããã¤ãã®ä¸è¬çãªãªã¯ã¨ã¹ããå®è¡ããããã«ä½¿ç¨ãã¾ãã éåæãªã¯ã¨ã¹ãä¾ãã°ãéåæãªã¯ã¨ã¹ãã»ããã®ã¹ãã¼ã¿ã¹ãåå¾ããã«ã¯æ¬¡ã®ããã«ãã¾ãã curl -G \ -d 'fields=name,success_count,error_count,is_completed' \ -d 'access_token=<ACCESS_TOKEN>' \ https://graph.facebook.com/v21.0/<REQUEST_SET_ID>ããã«ãããéåæãªã¯ã¨ã¹ãã»ããå ¨ä½ã®ã¹ãã¼ã¿ã¹ãJSO
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}