2019/02/15 Developers Summit 2019ã§ã®ã森廣ã®è¬æ¼è³æã«ãªãã¾ã
2019/02/15 Developers Summit 2019ã§ã®ã森廣ã®è¬æ¼è³æã«ãªãã¾ã
ISUCON8 ã®æ¬é¸åé¡ã¯ã競æè ãã³ã³ããã¼ã«ã§ããªãå¤é¨ API å¼ã³åºããå¤æ°å«ãã åºé¡å 容ã§ããã è¬è©ã§ã¯ã ãµã¼ãã¹ã®ç¹æ§ãé©åã«åæããä¸ã§ãã¾ã¨ããã¨ããã¯ã¾ã¨ããããé 延ãããã¨ããã¯é 延ããããªã© â¦â¦ã¨ããã£ã¨æ¸ããã¦ãã¾ãããå®éãããªãã¨ãçæéã§åæãããã¨ã¯å¯è½ãªã®ããï¼ã¨ãã話é¡ã競æå¾ã®æ親ä¼ã§ããã£ãã®ã§ããã AWS X-Ray ã§ã§ããããã¨ããã¨ã³ããªãã¾ã¨ãã¦ããããã¨æãã¾ãã ä»åã®è§£æ㯠Perl çã®åæå®è£ ã«å¯¾ãã¦è¡ã£ããã®ã§ããããªã Perl ãã¨ãã㨠AWS ã®å ¬å¼ SDK ã«ãªã X-Ray é¢é£ã® CPAN ã¢ã¸ã¥ã¼ã«ãèªåãæ¸ãã¦ããã®ã§ããã®å®£ä¼ãå ¼ãã¦ãã¾ãã(blogã¨ã³ããªæ¸ãã¦ãªãã£ã) AWS::XRay Plack::Middleware::XRay Devel::KYTProf::Logger::XRay
ã¯ããã¾ãã¦ããã¯ã·ãã§åºåé¢é£ã®ãããã¯ããéçºãã¦ããeastã§ããä»åã¯ã社å ã§éç¨ãã¦ããåºåé ä¿¡ãµã¼ãã¼ã®è² è·ãã¹ããå®æ½ããã®ã§ããã®è©±ããããã¨æãã¾ãã çµç·¯ ãã¯ã·ãã®åºåé ä¿¡ãµã¼ãã¼ã¯ãpixivæ¬ä½ãä¸å¿ã«è¤æ°ã®ãµã¼ãã¹ã«å¯¾ãã¦åºåé ä¿¡ãè¡ãªã£ã¦ãã¾ããç¾å¨ç§ã¯ãã®åºåé ä¿¡ãµã¼ãã¼ã®å¤§è¦æ¨¡æ¹ä¿®ãè¡ãªã£ã¦ããã®ã§ãããå æ¥ã¤ãã«åºåé ä¿¡ãµã¼ãã¼ã®æ¹ä¿®ãã»ã¼å®äºããã®ã§ã試ãã«è² è·è©¦é¨ãè¡ãªã£ã¦ã¿ããã¨æãç«ã¡ã¾ããã ç®æ¨ã¯æ¯ç§1ä¸ãªã¯ã¨ã¹ã ãã¯ã·ãã®åºåé ä¿¡ãµã¼ãã¼ã¸ã®ãªã¯ã¨ã¹ãæ°ã¯Daily㧠4ã6åreq ããããããã¯æ¯ç§å¹³åã«ç´ãã¨ç´ 5,000RPS(Request Per Second) ã«ãªãã¾ããããã«ããã¼ã¯ã¿ã¤ã ã§ããä¼æ¥ã®æ·±å¤å¸¯ã«ã¯ 12,000RPS ã«ãéãã¾ããã¤ã¾ãæ°ããåºåé ä¿¡ãµã¼ãã¼ã«ããæ¯ç§12,000ã®ãªã¯ã¨ã¹ããæãæ§è½ãå¿
æ¬æ¥ãç¡æWordPressãã¼ã Godios. ããªãªã¼ã¹ãã¾ããã å ¬å¼ãµã¤ããè¦ã¦ããã ããã¨ãããã¨æãã®ã§ãããã¼ã¸ãä¸ç¬ã§é·ç§»ãã¦ãã¾ãã ã©ãã§ããããdev.toã¨åããããéãããããªãã§ããããã ãã®è¨äºã§ã¯ãã¼ããé«éåããã«ããã£ã¦ç¨ãããã¯ããã¯ãæ¸ãã¦ããããã¨æãã¾ãã å§ç¸® ãã¼ãã«å«ã¾ãã¦ããç»åã»CSSã»JSãã¡ã¤ã«ã®å§ç¸®ã ç»åã¯Optimizillaã»TinyPNGãCSSã¯CSS MinifierãJSã¯JSCompressã使ç¨ãã¾ããã CSSã»JSãã¡ã¤ã«ã®é 延èªã¿è¾¼ã¿ ã¬ã³ããªã³ã°ããããã¯ãããã¡ã¤ã«ã大éã«ããã¨è¡¨ç¤ºãé ããªãã¾ãã®ã§ãJSãã¡ã¤ã«ã¯deferã¾ãã¯asyncå±æ§ãä»ä¸ããCSSãã¡ã¤ã«ã¯ã¤ã³ã©ã¤ã³ãã¾ãã¯JSã§éåæã«èªã¿è¾¼ãã§ãã¾ãã ç¡é§ãªSQLã¯ã¨ãªãæ¸ãã ãã¼ã¿ãã¼ã¹ã¸ã®ã¢ã¯ã»ã¹ãå¤ãã¨è² è·ãæããä¸ãé
ãã£ããè¨ã㨠ãªã¹ãæ§é ã®ãã¼ã¿ã«å¯¾ãã¦ã©ã³ãã ã¢ã¯ã»ã¹ã¯ãã¡ãã ãã ãããå ããã¨ã®ç´æã ï¼ çºç«¯ æ°å¹´åã«ä»é¨ç½²ã®æ¯æ´ã§ä½ã£ãJavaã®ã·ã¹ãã ã«ãã¡ãã£ã¨ãã«ãã®ãã¼ã¿ãçªã£è¾¼ãã ãããããªãã»ã©é ãã®ã§å©ãã¦ãããã¨é£çµ¡ãå ¥ã£ãã ã¾ãã¯ã¨ãªã¨ãã¤ã³ããã¯ã¹ãã¡ãã£ã¨è¦ãã°ç´ãã£ããã»ã»ã»ã¨é¼»ãã»ãããªããæ¯æ´ã«åãã£ãã å¦çå 容 é ãé¨åã®å¦çã¯ä»¥ä¸ã®ãããªãã®ã§ãã£ãã å¦ç対象ã®ãã¼ã¿ãListã§åãåãã ãããforã«ã¼ãã§1件ãã¤åå¦çããã å¦ççµæããªãã¸ã§ã¯ãã«æ ¼ç´ããORãããã¼ã§DBã«INSERTããã ããã ãï¼ ãããããã ãã ã並åå¦çãªãã¦é«ç´ãªãã¨ã¯ãã¡ãããã£ã¦ãªãã ã¤ã³ãã©èª¿æ» å¦çä¸ã®ãµã¼ãã®ãããã調æ»ãããä»åã®ã¤ã³ãã©ã¯å ¸åçãª3層3ãµã¼ãæ§æã WEBãµã¼ãã¯ãªã«ããããä½è£ã APãµã¼ãã§ã¯CPUã1ã¤ä½¿ãåã£ã¦ããã 14ã³ã¢
ã¿ãªããããã«ã¡ã¯ãLINEã®ãµã¼ãã¼ãµã¤ãã¨ã³ã¸ãã¢ã®é·è°·é¨ã§ããæ®æ®µã¯ãæè¿ã§ããã¨LINE Login ã LINE Customer Connect ãªã©ã®éçºãæ å½ãã¦ãã¾ãã 2018å¹´ã®å¹´å§ã« LINEã®ãå¹´ç ã¨ããã¤ãã³ããå®æ½ãããã®éçºãæ å½ãã¾ãããä»åã®è¨äºã§ã¯ãLINEã®ãå¹´çã®ã¢ã¼ããã¯ãã£ã®ç´¹ä»ããå½æ¥å®éã«çºçããåé¡(ãµã¼ãã¹éè² è·èµ·å ã®kafka consumeré 延)ãªã©ã®æ¯ãè¿ãã«ã¤ãã¦æ¸ããã¨æãã¾ãã LINEã®ãå¹´çã¨ã¯ ãå¹´çã¤ãã³ãæéä¸ã«ããå¹´çã¨LINEã¹ã¿ã³ããã»ããã§ããå¹´çã¤ãã¹ã¿ã³ããã¨ãã¦è²©å£²ãã¾ããã対象ã¹ã¿ã³ããè³¼å ¥ããã¦ã¼ã¶ã¼ããã¯ãã¹ã¿ã³ãè³¼å ¥æ° x 10å ã®ãå¹´çãä»ä¸ããã¾ãã ãããã£ãã¡ãã»ã¼ã¸ãåä¿¡ããã¾ã ã¦ã¼ã¶ã¼ã¯èªåããã£ã¦ãããå¹´çãåã ã¡ã«ç´æ¥éã£ããã°ã«ã¼ãã«éä¿¡ãããã¨ãã§ãããå¹´çãåãå
How a fix in Go 1.9 sped up our Gitaly service by 30x After noticing a worrying pattern in Gitaly's performance, we uncovered an issue with fork locking affecting virtual memory size. Here's how we figured out the problem and how to fix it. Gitaly is a Git RPC service that we are currently rolling out across GitLab.com, to replace our legacy NFS-based file-sharing solution. We expect it to be fast
Mercari Advent Calendar 2017 ã®15æ¥ç®ã¯ id:koemu ãã¨æè¤ãæ å½ãã¾ãã ããã«ã¡ã¯ãç§ã¯ããµã¼ããµã¤ãã®ã½ããã¦ã§ã¢ã¨ã³ã¸ãã¢ã¨ãã¦ãéå»ã¯ã¡ã«ã«ãª ç±³å½çã®éçºãç¾å¨ã¯æ¥æ¬çã®éçºã«æºãã£ã¦ãã¾ãã ãµã¼ããµã¤ãã®ã½ããã¦ã§ã¢ã¨ã³ã¸ãã¢ã«ã¨ã£ã¦ããµã¼ãã¹ã®æé·ã«ä¼´ããµã¼ãã®è² è·ã¨ã®æ¦ãã¯åã£ã¦ãåããªãåå¨ã§ããã¨ãç§ã¯èãã¦ãã¾ããåãããæ³å®ã§ããåé¡ãããã°ããµã¼ãã¹ãæé·ãã¦åãã¦æãã¿ã«ãªãåé¡ãããã¾ããæé·çã¨è¨ã£ã¦ãããããããã¾ããã ä»æ¥ã¯ãç§ãå½ç¤¾ã§åãã¦ãã¦æºãã£ãããµã¼ããµã¤ãã®ããã°ã©ã ã®ããã©ã¼ãã³ã¹ã«é¢ããäºè±¡ã«ã¤ãã¦ããSlave DBã¸ã®è¦æ±ã memcached ã«åãã¦ããããPHP ãããµãã·ã¹ãã ãå¼ã³åºããã¨ããã¨ãã®å·¥å¤«ãããã¦ãarray_merge()ã®å¤±æè«ãã®3ç¹ãããã¯ã¢ãããã¦ç´¹ä»ãã¾ã
An unedited version of article was originally published at HaydenJames.io and republished here with the authorâs permission. Letâs take a very quick look at how best to set up PHP-FPM for high throughput, low latency, and a more stable use of CPU and memory. By default, most setups have PHP-FPMâs PM (process manager) string set to dynamic and thereâs also the common advice to use ondemand if you s
å æ¥ããHow a single PostgreSQL config change improved slow query performance by 50xãã¨ããPostgreSQLã®SSDç°å¢ã§ã®ãã¥ã¼ãã³ã°ã®è¨äºãè¦ã¤ããã®ã§ããããããTweetãããRTãLikeãæ¯è¼çããããé ãã¾ããã How a single PostgreSQL config change improved slow query performance by 50x https://amplitude.engineering/how-a-single-postgresql-config-change-improved-slow-query-performance-by-50x-85593b8991b0 How a single PostgreSQL config change improved sl
æ¥æ¬çµæ¸æ°èã¯å½å ã代表ããçµæ¸èªã ããã®é»åçã¯webã§ã®ç¶ç¶èª²éã大æåããããã¾ã50ä¸ä»¥ä¸ã®ææä¼å¡ãæããã¢ã³ã¹ã¿ã¼ãµã¤ãã ã ãã®æ¥çµé»åçã11æ6æ¥ã«å ¨é¢ãªãã¥ã¼ã¢ã«ããã®ã ããå ¬éå¾ãwebæ¥çãã«ããã«ããã¤ããã表示é度ãçéã ã£ãã®ã ãæ¥çµå ¬å¼ãã¢ãã¤ã«ã§2åã®è¡¨ç¤ºé度ãéæããã¨å ã ã¨å®£è¨ãã¦ããã webãµã¼ãã¹ã¯ç¶ç¶çããç¥KPIã§ããã®ç¶ç¶çã«ã¯é度ã大ããå½±é¿ããã ããã¯ãã§ãããªãã¨ã¤ãã¤ã¨æããå人ã®kitakããã¨ã¹ãã¼ãã®ç§å¯ã調æ»ãã¦ã¿ãã Fastlyãã³ã³ãã³ããã£ãã·ã¥ã«ä½¿ãæ®ã©ã®ãã¼ã¿ã¯Fastlyãçµç±ãã¦åå¾ããã¦ãããFastlyã¯æè¿æ³¨ç®ãéãã¦ããCDNï¼ä¸çä¸ã«ã¨ãã¸ãµã¼ãã¼ãé ç½®ããé«éã«ã³ã³ãã³ããé ä¿¡ãããµã¼ãã¹ï¼ã§ãé常ã«é«æ©è½ã§ã¦ãã¼ã¯ãªãµã¼ãã¹ã ã ä¸è¬ã«ãCDNã¯ãã£ããä¸çä¸ã«ã³ã³ãã³ããã°ãã¾ãã¨ããããç¡
Webãµã¼ãã¹ãããæãã«ããã©ã¼ãã³ã¹ãã¥ã¼ãã³ã°ããã³ã³ãã¹ã ISUCON7äºé¸1æ¥ç®ã« @netmarkjp, @ishikawa84g, @matsuu ã§ãã¼ã ãããã¦ãã«ã¨ãã¦åå ãã¾ãããæçµã¹ã³ã¢ã¯ 205148 ã§ããã èå¯ netmarkjp ä¾å¹´éãã®å½¹å²åæ ããã£ããæ©è½ãã¦æ°æã¡ããã§ãã è¦ç¹ãå¤ãããä¼æ©ã¨ã£ãããããæãã«ã§ãã å»å¹´ã®ä½ãã§ããªãã£ãç¡å¿µã¯å¤å°ä¾é¤ã§ãã ç·´ç¿ããã¡ãã¨æ´»ããã ãã³ããå®å®ãã¦ã¦ãããããã£ã BGMã¯æ±äº¬ã¹ã«ãã©ãã¤ã¹ãªã¼ã±ã¹ãã©ã§ãã matsuu ãã©ãã£ãã¯ãããã«ããã¯ã«ãªãåé¡ããªããªã解決ã§ããã«ããããCache-Controlã«publicãå ¥ãããã¨ãæãã¤ãã 304å¿çãå®å®ãã¦çºçããªãçç±ãçæãããç»åã®æ´æ°æ¥æããµã¼ãæ¯ã«ç°ãªãããã§ãããã¨ã«æ°ã¥ããèªåãè¤ãã¦ãããã tcpdump
2017/02/16 Developers Summit 2017
Redisã¯å¤å½©ãªãã¼ã¿æ§é ããã¤1ã¤ã³ã¡ã¢ãªDBã§ãããæ¨ä»ã®Webã¢ããªã±ã¼ã·ã§ã³ã®ãã¼ã¿ã¹ãã¢ã®ä¸ã¤ã¨ãã¦ãåºãå©ç¨ããã¦ããã ããããä¸æ¹ã§ãæ§è½æ¹åã®ããã®ææ³ãä½ç³»çã«ã¾ã¨ããè³æãè¦å½ãããªãã¨æãã¦ããã å®éãæåã«CPUè² è·ãåé¡ã«ãªã£ãã¨ãã«ã©ããããã®ãã¨æ©ã¿ã調æ»ã¨è©¦è¡é¯èª¤ãç¹°ãè¿ããã ããã§ããã®è¨äºã§ã¯ãèªåã®çµé¨ãåºã«ãRedisãµã¼ãã®CPUè² è·å¯¾çããCPUè² è·åæ¸ããã¹ã±ã¼ã«ã¢ããããã¹ã±ã¼ã«ã¢ã¦ããã«åé¡ãããã¿ã¼ã³ã¨ãã¦ã¾ã¨ããã èæ¯ Redisã®CPUè² è·å¯¾çãã¿ã¼ã³ CPUè² è·åæ¸ multiã³ãã³ã Redisãã¤ãã©ã¤ãã³ã° Luaã¹ã¯ãªããã£ã³ã° Redisã¢ã¸ã¥ã¼ã«(夢) ã¹ã±ã¼ã«ã¢ãã ã¹ã±ã¼ã«ã¢ã¦ã åç §ç¨ã¹ã¬ã¼ã åç´åå² æ°´å¹³åå² Redis Clusterã«ããæ°´å¹³åå² ãã®ä» ã¹ã©ã¤ãè³æ ãã¨ãã åèè³æ èæ¯ R
ãªããSQLã¯éãããªãã®ãï¼ââãSQLããã©ã¼ãã³ã¹è©³è§£ãã®ç¿»è¨³è ãæããåå ã¨å¯¾ç ãSQLããã©ã¼ãã³ã¹è©³è§£ãã®ç¿»è¨³è ã®æ¾æµ¦é¼äººããã«ã8ã¤ã®ãSQLãéãããªãåå ã¨ãã®å¯¾çããèãã¾ãããã·ã¹ãã ã®ããã«ããã¯ã«ãªããããªãåé¡ã®ããSQLããåé¿ãããã¦ãã¦ãå¦ã³ã¾ãããã ãã¼ã¿ã®æä½ãå®ç¾©ãããè¨èªãSQLãã¯ãã©ã®ãããªé åãæ ãã¨ã³ã¸ãã¢ã«ã¨ã£ã¦ãå¿ ä¿®ç§ç®ã§ãããããããã®ä»æ§ããã¡ãã¨ç解ããããã©ã¼ãã³ã¹ã«åªããSQLãæ¸ããæ¹ã¯ããã»ã©å¤ãããã¾ãããåé¡ã®ããSQLãæ¸ãã¦ãã¾ããç¥ãã¬éã«ãããã·ã¹ãã ã®ããã«ããã¯ã«ãªã£ã¦ãã¾ãäºæ ã¯ããçºçãã¾ãã ã§ã¯ãã©ãããã°ããããäºæ ãåé¿ã§ããã®ã§ããããï¼ ãã®ãã¦ãã¦ãå¦ã¶ãããä»åã¯ãSQLããã©ã¼ãã³ã¹è©³è§£ãã®ç¿»è¨³è ã§ãããèªèº«ãã¨ã³ã¸ãã¢ã§ãããæ¾æµ¦é¼äººï¼ã¾ã¤ããã»ã¯ãã¨ï¼@dblmktï¼ããã«8ã¤
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}