niftyisucon / isucon13

0 stars 0 forks source link

Benchmark result on isu1 (4,674) #10

Open github-actions[bot] opened 10 months ago

github-actions[bot] commented 10 months ago
COUNT 1XX 2XX 3XX 4XX 5XX METHOD URI MIN MAX SUM AVG P90 P95 P99 STDDEV MIN(BODY) MAX(BODY) SUM(BODY) AVG(BODY)
708 0 705 0 3 0 GET /api/livestream 0.004 7.004 238.867 0.337 0.764 0.924 1.308 0.469 0.000 39370.000 5952571.000 8407.586
631 0 625 0 6 0 POST /api/livestream 0.004 12.733 196.461 0.311 0.332 0.596 3.692 0.919 0.000 2727.000 1113999.000 1765.450
2267 0 2265 0 2 0 GET /api/user/[a-zA-Z0-9]+/icon 0.004 1.180 187.072 0.083 0.192 0.280 0.536 0.109 0.000 88843.000 112898490.000 49800.834
7 0 2 0 5 0 GET /api/user/[a-zA-Z0-9]+/statistics 2.636 20.001 90.697 12.957 20.001 20.001 20.001 7.967 0.000 140.000 273.000 39.000
52 0 49 0 3 0 GET /api/livestream/search 0.036 3.664 67.337 1.295 2.388 2.688 3.664 0.848 0.000 126628.000 3589742.000 69033.500
213 0 210 0 2 1 POST /api/register 0.004 0.848 47.270 0.222 0.356 0.472 0.596 0.119 0.000 504.000 98418.000 462.056
101 0 97 0 4 0 POST /api/livestream/reservation 0.004 1.108 43.640 0.432 0.824 0.912 1.012 0.314 0.000 1472.000 109531.000 1084.465
210 0 209 0 1 0 POST /api/icon 0.016 1.120 32.048 0.153 0.320 0.436 0.748 0.149 0.000 16.000 3236.000 15.410
218 0 216 0 2 0 POST /api/login 0.004 0.820 17.116 0.079 0.220 0.316 0.600 0.119 0.000 64.000 128.000 0.587
1 0 1 0 0 0 POST /api/initialize 15.768 15.768 15.768 15.768 15.768 15.768 15.768 0.000 27.000 27.000 27.000 27.000
80 0 80 0 0 0 GET /api/tag 0.004 0.556 7.400 0.092 0.236 0.356 0.556 0.119 6089.000 6095.000 487402.000 6092.525
21 0 21 0 0 0 DELETE /api/livestream 0.008 0.212 1.544 0.074 0.184 0.196 0.212 0.070 0.000 0.000 0.000 0.000
6 0 6 0 0 0 GET /api/user/[a-zA-Z0-9]+/theme 0.008 0.260 0.436 0.073 0.260 0.260 0.260 0.097 38.000 38.000 228.000 38.000
1 0 1 0 0 0 GET /api/user/[a-zA-Z0-9]+$ 0.004 0.004 0.004 0.004 0.004 0.004 0.004 0.000 235.000 235.000 235.000 235.000
3 0 3 0 0 0 GET /api/user/me 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 235.000 247.000 729.000 243.000
1 0 1 0 0 0 GET /api/payment 0.000 0.000 0.000 0.000 0.000 0.000 0.000 0.000 21.000 21.000 21.000 21.000
github-actions[bot] commented 10 months ago
Reading from STDIN ...

# 32.7s user time, 200ms system time, 36.96M rss, 43.50M vsz
# Current date: Sat Nov 25 04:09:27 2023
# Hostname: ip-192-168-0-11
# Files: STDIN
# Overall: 513.92k total, 93 unique, 1.23k QPS, 1.00x concurrency ________
# Time range: 2023-11-25T04:01:06 to 2023-11-25T04:08:04
# Attribute          total     min     max     avg     95%  stddev  median
# ============     ======= ======= ======= ======= ======= ======= =======
# Exec time           419s     1us   446ms   815us     4ms     3ms    69us
# Lock time          847ms       0    61ms     1us     1us   134us       0
# Rows sent        201.40k       0   7.32k    0.40    0.99   17.52       0
# Rows examine      86.03M       0  14.02k  175.53   1.04k  668.02       0
# Query size        51.42M       5   1.94M  104.92  299.03   3.31k   31.70

# Profile
# Rank Query ID                           Response time Calls  R/Call V/M 
# ==== ================================== ============= ====== ====== ====
#    1 0x84B457C910C4A79FC9EBECB8B1065C66 72.0767 17.2%  13004 0.0055  0.01 SELECT icons
#    2 0xDA556F9115773A1A99AA0165670CE848 54.0258 12.9% 152490 0.0004  0.00 ADMIN PREPARE
#    3 0x42EF7D7D98FBCC9723BF896EBFC51D24 43.9650 10.5%   6273 0.0070  0.00 SELECT records
#    4 0xF1B8EF06D6CA63B24BFF433E06CCEB22 29.2268  7.0%   3738 0.0078  0.01 SELECT users livestreams livecomments
#    5 0xDB74D52D39A7090F224C4DEEAF3028C9 28.6360  6.8%   3740 0.0077  0.01 SELECT users livestreams reactions
#    6 0x3D83BC87F3B3A00D571FFC8104A6E50C 22.5022  5.4%   4597 0.0049  0.01 SELECT records
#    7 0x38BC86A45F31C6B1EE324671506C898A 20.5160  4.9%  10744 0.0019  0.00 SELECT themes
#    8 0x4ADE2DC90689F1C4891749AF54FB8D14 18.1438  4.3%  34154 0.0005  0.00 DELETE SELECT livecomments
#    9 0x59F1B6DD8D9FEC059E55B3BFD624E8C3 16.4321  3.9%    828 0.0198  0.01 SELECT reservation_slots
#   10 0xFFFCA4D67EA0A788813031B8BBC3B329 12.8986  3.1%   2435 0.0053  0.00 COMMIT
#   11 0x64CC8A4E8E4B390203375597CE4D611F 12.5780  3.0%    282 0.0446  0.01 SELECT ng_words
#   12 0xFBC5564AE716EAE82F20BFB45F6C37E7  9.2799  2.2%  26141 0.0004  0.00 SELECT tags
#   13 0x22279D81D51006139E0C76405B54C261  7.9069  1.9%   9706 0.0008  0.00 SELECT domains domainmetadata
#   14 0xDFFCC1D78939C4D781C7C58349101F50  6.3703  1.5%   1000 0.0064  0.00 INSERT users
#   15 0xD2A0864774622BA36F6557496405CF75  6.2283  1.5%   1210 0.0051  0.00 INSERT themes
#   16 0x8F7679D452333ED3C7D60D22131CEFD4  5.2562  1.3%  22303 0.0002  0.00 ADMIN RESET STMT
#   17 0xA3401CA3ABCC04C3AB221DB8AD5CBF26  4.2630  1.0%     97 0.0439  0.02 UPDATE reservation_slots
#   18 0xFD38427AE3D09E3883A680F7BAF95D3A  4.2587  1.0%  14992 0.0003  0.00 SELECT livestreams livecomments
#   19 0x7F9C0C0BA9473953B723EE16C08655F1  4.1039  1.0%     99 0.0415  0.02 SELECT reservation_slots
#   20 0xEA1E6309EEEFF9A6831AD2FB940FC23C  3.9856  1.0%  10528 0.0004  0.00 SELECT users
#   21 0xF7144185D9A142A426A36DC55C1D2623  3.8873  0.9%   6999 0.0006  0.00 SELECT livestream_tags
#   22 0xC499D81D570D361DB61FC43A94BB888A  3.7312  0.9%  14992 0.0002  0.00 SELECT livestreams reactions
#   23 0x9EAD6C0CE525E3693EE27FFC9AAF05A3  3.6398  0.9%     82 0.0444  0.01 SELECT livestreams
#   24 0x859BBB7E9D760686137A944406874C4D  3.2779  0.8%    210 0.0156  0.01 DELETE records
#   25 0x3A2B0EDA41C4E3576FCA6DA29A9B91DF  2.2874  0.5%    209 0.0109  0.01 INSERT icons
#   26 0xD6032FE08E1FE706A928B8B7CBA06B85  2.2585  0.5%   5368 0.0004  0.00 SELECT livestreams
#   27 0x9AC623FA477E73A44D191D296850A025  1.9910  0.5%    420 0.0047  0.00 SELECT records
#   28 0x07890000813C4CC7111FD2D3F3B3B4EB  1.9124  0.5% 152477 0.0000  0.00 ADMIN CLOSE STMT
#   29 0xEDE18C1523658A19E07525EAFCBA6BFE  1.5961  0.4%     29 0.0550  0.01 SELECT ng_words
#   30 0xF1E5C5B0483E8BF764220BFACAE7CD16  1.3289  0.3%    210 0.0063  0.01 DELETE icons
#   31 0xFFF66E9B3D962FA319C8068B5C1997CD  1.2423  0.3%   2276 0.0005  0.00 ROLLBACK
#   32 0x3F155F5E71EFF856F0CF7B8430DE8C23  1.1279  0.3%   2492 0.0005  0.00 SELECT users
#   33 0xB08B7B7486D2DFE2F2FE9CE78689FD79  1.0277  0.2%     23 0.0447  0.01 SELECT ng_words
#   34 0x9E2DA589A20EC24C34E11DDE0FBF5564  0.8721  0.2%   4513 0.0002  0.00 START
#   35 0xB78E63D0D9C72DDDAB7A3E53517FA04C  0.6742  0.2%    234 0.0029  0.00 SELECT livecomments
#   36 0xAD0C28443E1E5CFAFF1569DBB4F7E63A  0.6335  0.2%    268 0.0024  0.00 SELECT reactions
#   37 0x98F959E03B684A5538FD8402A0EE94AD  0.6177  0.1%    103 0.0060  0.00 INSERT tags
#   38 0x02B6A87E51A5A1B7646675DB67C57DE3  0.4457  0.1%      1 0.4457  0.00 INSERT ng_words
#   39 0x80E10371CE74ED05E09C79C72C73F8E1  0.4232  0.1%     98 0.0043  0.27 INSERT livestreams
#   40 0x0C1FCBB4E25B178AA3A46D4FECBA9BDC  0.4143  0.1%     22 0.0188  0.00 INSERT livestream_tags
#   41 0x77FB9E134D073862D1E78FEEC3436291  0.3441  0.1%   1490 0.0002  0.00 INSERT records
#   42 0x41F805E95754958A974F41AE07BEA625  0.2845  0.1%     30 0.0095  0.01 SELECT livecomments
#   43 0xF3A502CCF34F7DA288CC1B75AD5AFA37  0.2337  0.1%    281 0.0008  0.00 INSERT livecomments
#   44 0xB9AC05A7AE6C4E30B5B45F6F3CE05BE0  0.2064  0.0%    422 0.0005  0.01 SET
#   45 0x5D469B53C536D19CD15E40763ACC23C7  0.1738  0.0%    407 0.0004  0.01 INSERT livestream_tags
#   46 0xDF0AAE38E2AAFC85E6F50569CEF2285D  0.1591  0.0%      1 0.1591  0.00 INSERT reservation_slots
#   47 0x5AEB6E4A781A3854CF642125E293FEE0  0.1420  0.0%    248 0.0006  0.00 INSERT reactions
#   48 0x64052B1C32B30DF53AB3292208B783B4  0.1284  0.0%    211 0.0006  0.00 INSERT users
#   49 0x651E3772B8767A368CB47EE7389EEB33  0.1049  0.0%     14 0.0075  0.01 SELECT livestream_tags
#   50 0xDBB1C17D6ABA0156D8ABCE105DDDA1B2  0.0851  0.0%      1 0.0851  0.00 TRUNCATE TABLE users
#   51 0xE64D50F7AFC1AD5F465809A92DF4935E  0.0847  0.0%     27 0.0031  0.00 SELECT reactions
#   52 0x4B6FA79E206C6CED71D433A2FC998D69  0.0833  0.0%     89 0.0009  0.00 SELECT
#   53 0xEE4C51AE2BF74414C4892CBE11E894AA  0.0768  0.0%     28 0.0027  0.00 SELECT livecomments
#   54 0xBB7F4DC4E67BF30E0588D296FFAF009F  0.0558  0.0%      1 0.0558  0.00 TRUNCATE TABLE tags
#   55 0x19A1F14EFC0F221D30AFCB1E1344BEBD  0.0545  0.0%      7 0.0078  0.01 SELECT users
#   56 0x1FB70DBF74628C9F2E9F0C3478771936  0.0537  0.0%      1 0.0537  0.00 TRUNCATE TABLE ng_words
#   57 0x08A6ACD83D579DD8A808134B32AD376B  0.0536  0.0%      1 0.0536  0.00 TRUNCATE TABLE livestream_tags
#   58 0xAFFDC331C1D4BA089978A0B8DD00BFC8  0.0526  0.0%      1 0.0526  0.00 TRUNCATE TABLE livestreams
#   59 0x2AAED5867123C749367FD8E4BBD796D2  0.0518  0.0%      1 0.0518  0.00 TRUNCATE TABLE livecomments
#   60 0x544239977D2094F805A7B062DE95673A  0.0518  0.0%     80 0.0006  0.00 SELECT tags
#   61 0x253CA101A906B3D56A95D1B8DCEE28EF  0.0513  0.0%      1 0.0513  0.00 TRUNCATE TABLE icons
#   62 0x9C697B3F0446BBF7602663588252F020  0.0512  0.0%      1 0.0512  0.00 TRUNCATE TABLE livestream_viewers_history
#   63 0x93A42F50BF286ACA749DF5F342FAC07B  0.0507  0.0%      1 0.0507  0.00 TRUNCATE TABLE livecomment_reports
#   64 0x81E419F4B58AEB9B280B03DE44DD8B94  0.0485  0.0%    110 0.0004  0.00 SELECT livecomments
#   65 0xE623383C5D789800DC0946925F90039F  0.0482  0.0%    211 0.0002  0.00 SELECT domains
#   66 0xA7C2E59AEF14D03CB65B227F3E3BA469  0.0481  0.0%      1 0.0481  0.00 TRUNCATE TABLE reservation_slots
#   67 0xFB296F703ACC41C3F94A9B7D75044F3C  0.0466  0.0%      1 0.0466  0.00 TRUNCATE TABLE reactions
#   68 0xD2978B45C67B47B5D73AC532EB40A95E  0.0455  0.0%      1 0.0455  0.00 TRUNCATE TABLE themes
#   69 0x07F6C3FF39ADD79FC63923A7EE938953  0.0453  0.0%      1 0.0453  0.00 INSERT livecomments
#   70 0x74232BDFFB94C567F0340DBE3285E458  0.0286  0.0%      1 0.0286  0.00 INSERT reactions
#   71 0x050F7D44808F43E5D33D0B90BCF57CC9  0.0241  0.0%      2 0.0121  0.00 SELECT livestreams
#   72 0x24C44C3518CE12293EF12410AEDA2393  0.0231  0.0%     37 0.0006  0.00 SELECT livestreams
#   73 0x0C655718656DD9DDA39A0D11554A0C64  0.0199  0.0%     23 0.0009  0.00 INSERT ng_words
#   74 0xB871CC5B0472067402F5739D108B2C1C  0.0183  0.0%     23 0.0008  0.00 SELECT livestreams
#   75 0x8D589AFA4DFAEEED85FFF5AA78E5FF6A  0.0168  0.0%    211 0.0001  0.00 BEGIN
#   76 0xBF3194A2446AC20FC99B6CC7FA476A57  0.0155  0.0%     29 0.0005  0.00 INSERT livestream_viewers_history
#   77 0x827F41D30F8E37F04D8BDCD46C556FB3  0.0141  0.0%     44 0.0003  0.00 INSERT livecomment_reports
#   78 0x466EE4C87B17CAD4E692DE1D44EAD84D  0.0108  0.0%     39 0.0003  0.00 SELECT livecomment_reports
#   79 0xDFEFE5BA5D8654534DC8550C6E3DC9C0  0.0102  0.0%      1 0.0102  0.00 DELETE records
#   80 0xA0D956F292B7FEA0DCE68A5DD5F529E1  0.0080  0.0%     21 0.0004  0.00 DELETE livestream_viewers_history
#   81 0x2B760561C10B5D133155AA306D0F407C  0.0070  0.0%     18 0.0004  0.00 SELECT livecomments
#   82 0xF985E5835B84E84C7A721801818E98CE  0.0039  0.0%      2 0.0019  0.00 SELECT users livestreams reactions
#   83 0x49F80FBE1AC70F23A3DD076174FF1AA9  0.0022  0.0%      2 0.0011  0.00 SELECT users livestreams reactions
#   84 0x20CD15DC47AF2F861B8F3C25D195ABE9  0.0015  0.0%     14 0.0001  0.00 SELECT tags
#   85 0x2C17BCA1E1077820CDC2EC6106F4D93E  0.0012  0.0%     18 0.0001  0.00 SELECT livestream_viewers_history
#   86 0x0E7680C04FF2596BE3A3649C5FAC418D  0.0008  0.0%      9 0.0001  0.00 SELECT
#   87 0xEDBC971AEC392917AA353644DE4C4CB4  0.0008  0.0%    355 0.0000  0.00 ADMIN QUIT
#   88 0x8B2044ADAE690405979131C33185F22A  0.0007  0.0%      6 0.0001  0.00 SELECT users
#   89 0xC4625761E0CFD817F41B4802F152A489  0.0007  0.0%      1 0.0007  0.00 SELECT livecomments
#   90 0xEBE4AF9F935DE1D48BB5BB3558C7FCC4  0.0006  0.0%      2 0.0003  0.00 SELECT livestreams livecomments
#   91 0x8F885091E23CB955C051B1204EE7D91D  0.0005  0.0%      2 0.0002  0.00 SELECT livestreams reactions
#   92 0x394E66DDE2823A903078D4C0F235B948  0.0002  0.0%      2 0.0001  0.00 SELECT livestreams livecomment_reports
#   93 0xF085F31DC1964EA538732B713E4B4108  0.0002  0.0%      2 0.0001  0.00 SELECT livestreams livestream_viewers_history

# Query 1: 147.77 QPS, 0.82x concurrency, ID 0x84B457C910C4A79FC9EBECB8B1065C66 at byte 139905982
# This item is included in the report because it matches --limit.
# Scores: V/M = 0.01
# Time range: 2023-11-25T04:06:36 to 2023-11-25T04:08:04
# Attribute    pct   total     min     max     avg     95%  stddev  median
# ============ === ======= ======= ======= ======= ======= ======= =======
# Count          2   13004
# Exec time     17     72s    46us    58ms     6ms    18ms     6ms     3ms
# Lock time      3    29ms       0     2ms     2us     1us    29us     1us
# Rows sent      4   9.73k       0       1    0.77    0.99    0.42    0.99
# Rows examine   1   1.09M       0     202   88.09  183.58   60.16   80.10
# Query size     1 555.99k      41      44   43.78   42.48    0.30   42.48
# String:
# Databases    isupipe
# Hosts        localhost
# Users        isucon
# Query_time distribution
#   1us
#  10us  ###########
# 100us  ###################
#   1ms  ################################################################
#  10ms  #########################
# 100ms
#    1s
#  10s+
# Tables
#    SHOW TABLE STATUS FROM `isupipe` LIKE 'icons'\G
#    SHOW CREATE TABLE `isupipe`.`icons`\G
# EXPLAIN /*!50100 PARTITIONS*/
SELECT image FROM icons WHERE user_id = 1043\G

# Query 2: 1.73k QPS, 0.61x concurrency, ID 0xDA556F9115773A1A99AA0165670CE848 at byte 42512622
# This item is included in the report because it matches --limit.
# Scores: V/M = 0.00
# Time range: 2023-11-25T04:06:36 to 2023-11-25T04:08:04
# Attribute    pct   total     min     max     avg     95%  stddev  median
# ============ === ======= ======= ======= ======= ======= ======= =======
# Count         29  152490
# Exec time     12     54s    23us   214ms   354us     1ms     1ms    80us
# Lock time      0       0       0       0       0       0       0       0
# Rows sent      0       0       0       0       0       0       0       0
# Rows examine   0       0       0       0       0       0       0       0
# Query size     8   4.36M      30      30      30      30       0      30
# String:
# Databases    isupipe (151226/99%), isudns (1264/0%)
# Hosts        localhost
# Users        isucon (151226/99%), isudns (1264/0%)
# Query_time distribution
#   1us
#  10us  ################################################################
# 100us  ###########################################
#   1ms  #########
#  10ms  #
# 100ms  #
#    1s
#  10s+
administrator command: Prepare\G

# Query 3: 15.01 QPS, 0.11x concurrency, ID 0x42EF7D7D98FBCC9723BF896EBFC51D24 at byte 149238099
# This item is included in the report because it matches --limit.
# Scores: V/M = 0.00
# Time range: 2023-11-25T04:01:06 to 2023-11-25T04:08:04
# Attribute    pct   total     min     max     avg     95%  stddev  median
# ============ === ======= ======= ======= ======= ======= ======= =======
# Count          1    6273
# Exec time     10     44s   717us    41ms     7ms    18ms     6ms     5ms
# Lock time      2    24ms       0     4ms     3us     1us    63us     1us
# Rows sent      0   1.15k       0       3    0.19    0.99    0.39       0
# Rows examine   9   8.34M   1.25k   1.46k   1.36k   1.39k   55.96   1.33k
# Query size     1 867.83k     127     209  141.66  158.58   11.66  136.99
# String:
# Hosts        localhost
# Users        isudns
# Query_time distribution
#   1us
#  10us
# 100us  #
#   1ms  ################################################################
#  10ms  #######################
# 100ms
#    1s
#  10s+
# Tables
#    SHOW TABLE STATUS FROM `isudns` LIKE 'records'\G
#    SHOW CREATE TABLE `isudns`.`records`\G
# EXPLAIN /*!50100 PARTITIONS*/
SELECT content,ttl,prio,type,domain_id,disabled,name,auth FROM records WHERE disabled=0 and name='mtanaka1.u.isucon.dev' and domain_id=2\G

# Query 4: 42.48 QPS, 0.33x concurrency, ID 0xF1B8EF06D6CA63B24BFF433E06CCEB22 at byte 95787067
# This item is included in the report because it matches --limit.
# Scores: V/M = 0.01
# Time range: 2023-11-25T04:06:36 to 2023-11-25T04:08:04
# Attribute    pct   total     min     max     avg     95%  stddev  median
# ============ === ======= ======= ======= ======= ======= ======= =======
# Count          0    3738
# Exec time      6     29s     1ms    58ms     8ms    28ms    10ms     1ms
# Lock time      1    15ms       0     5ms     4us     1us    77us     1us
# Rows sent      1   3.65k       1       1       1       1       0       1
# Rows examine   8   7.54M   1.96k   2.45k   2.07k   2.27k  142.99   1.96k
# Query size     1 601.58k     163     166  164.80  158.58       0  158.58
# String:
# Databases    isupipe
# Hosts        localhost
# Users        isucon
# Query_time distribution
#   1us
#  10us
# 100us
#   1ms  ################################################################
#  10ms  ###########################
# 100ms
#    1s
#  10s+
# Tables
#    SHOW TABLE STATUS FROM `isupipe` LIKE 'users'\G
#    SHOW CREATE TABLE `isupipe`.`users`\G
#    SHOW TABLE STATUS FROM `isupipe` LIKE 'livestreams'\G
#    SHOW CREATE TABLE `isupipe`.`livestreams`\G
#    SHOW TABLE STATUS FROM `isupipe` LIKE 'livecomments'\G
#    SHOW CREATE TABLE `isupipe`.`livecomments`\G
# EXPLAIN /*!50100 PARTITIONS*/
SELECT IFNULL(SUM(l2.tip), 0) FROM users u
        INNER JOIN livestreams l ON l.user_id = u.id    
        INNER JOIN livecomments l2 ON l2.livestream_id = l.id
        WHERE u.id = 196\G

# Query 5: 42.50 QPS, 0.33x concurrency, ID 0xDB74D52D39A7090F224C4DEEAF3028C9 at byte 73611690
# This item is included in the report because it matches --limit.
# Scores: V/M = 0.01
# Time range: 2023-11-25T04:06:36 to 2023-11-25T04:08:04
# Attribute    pct   total     min     max     avg     95%  stddev  median
# ============ === ======= ======= ======= ======= ======= ======= =======
# Count          0    3740
# Exec time      6     29s     1ms    67ms     8ms    28ms    10ms     1ms
# Lock time      1    15ms       0     2ms     3us     1us    61us     1us
# Rows sent      1   3.65k       1       1       1       1       0       1
# Rows examine   8   7.54M   1.96k   2.40k   2.06k   2.27k  143.08   1.96k
# Query size     1 528.85k     143     146  144.80  143.84    0.88  143.84
# String:
# Databases    isupipe
# Hosts        localhost
# Users        isucon
# Query_time distribution
#   1us
#  10us
# 100us
#   1ms  ################################################################
#  10ms  ###########################
# 100ms
#    1s
#  10s+
# Tables
#    SHOW TABLE STATUS FROM `isupipe` LIKE 'users'\G
#    SHOW CREATE TABLE `isupipe`.`users`\G
#    SHOW TABLE STATUS FROM `isupipe` LIKE 'livestreams'\G
#    SHOW CREATE TABLE `isupipe`.`livestreams`\G
#    SHOW TABLE STATUS FROM `isupipe` LIKE 'reactions'\G
#    SHOW CREATE TABLE `isupipe`.`reactions`\G
# EXPLAIN /*!50100 PARTITIONS*/
SELECT COUNT(*) FROM users u
        INNER JOIN livestreams l ON l.user_id = u.id
        INNER JOIN reactions r ON r.livestream_id = l.id
        WHERE u.id = 87\G