tetsuzawa / isucon13

0 stars 0 forks source link

競技が開始したらやること #2

Open tetsuzawa opened 11 months ago

tetsuzawa commented 11 months ago
mackee commented 11 months ago

SQL一覧

Details

```sql $ cat *.go | perl -nal -E 'say "L$.: $1" if /"((?:SELECT|DELETE|UPDATE|INSERT)[^"]*)"/' L87: SELECT * FROM livecomments WHERE livestream_id = ? ORDER BY created_at DESC L146: SELECT * FROM ng_words WHERE user_id = ? AND livestream_id = ? ORDER BY created_at DESC L191: SELECT * FROM livestreams WHERE id = ? L201: SELECT id, user_id, livestream_id, word FROM ng_words WHERE user_id = ? AND livestream_id = ? L233: INSERT INTO livecomments (user_id, livestream_id, comment, tip, created_at) VALUES (:user_id, :livestream_id, :comment, :tip, :created_at) L285: SELECT * FROM livestreams WHERE id = ? L294: SELECT * FROM livecomments WHERE id = ? L309: INSERT INTO livecomment_reports(user_id, livestream_id, livecomment_id, created_at) VALUES (:user_id, :livestream_id, :livecomment_id, :created_at) L362: SELECT * FROM livestreams WHERE id = ? AND user_id = ? L369: INSERT INTO ng_words(user_id, livestream_id, word, created_at) VALUES (:user_id, :livestream_id, :word, :created_at) L385: SELECT * FROM ng_words WHERE livestream_id = ? L393: SELECT * FROM livecomments L427: SELECT * FROM users WHERE id = ? L436: SELECT * FROM livestreams WHERE id = ? L458: SELECT * FROM users WHERE id = ? L467: SELECT * FROM livecomments WHERE id = ? L591: SELECT * FROM reservation_slots WHERE start_at >= ? AND end_at <= ? FOR UPDATE L597: SELECT slot FROM reservation_slots WHERE start_at = ? AND end_at = ? L618: UPDATE reservation_slots SET slot = slot - 1 WHERE start_at >= ? AND end_at <= ? L622: INSERT INTO livestreams (user_id, title, description, playlist_url, thumbnail_url, start_at, end_at) VALUES(:user_id, :title, :description, :playlist_url, :thumbnail_url, :start_at, :end_at) L635: INSERT INTO livestream_tags (livestream_id, tag_id) VALUES (:livestream_id, :tag_id) L669: SELECT id FROM tags WHERE name = ? L673: SELECT * FROM livestream_tags WHERE tag_id IN (?) ORDER BY livestream_id DESC L684: SELECT * FROM livestreams WHERE id = ? L740: SELECT * FROM livestreams WHERE user_id = ? L774: SELECT * FROM users WHERE name = ? L783: SELECT * FROM livestreams WHERE user_id = ? L832: INSERT INTO livestream_viewers_history (user_id, livestream_id, created_at) VALUES(:user_id, :livestream_id, :created_at) L866: DELETE FROM livestream_viewers_history WHERE user_id = ? AND livestream_id = ? L896: SELECT * FROM livestreams WHERE id = ? L935: SELECT * FROM livestreams WHERE id = ? L949: SELECT * FROM livecomment_reports WHERE livestream_id = ? L971: SELECT * FROM users WHERE id = ? L980: SELECT * FROM livestream_tags WHERE livestream_id = ? L987: SELECT * FROM tags WHERE id = ? L1259: SELECT IFNULL(SUM(tip), 0) FROM livecomments L1325: SELECT * FROM reactions WHERE livestream_id = ? ORDER BY created_at DESC L1391: INSERT INTO reactions (user_id, livestream_id, emoji_name, created_at) VALUES (:user_id, :livestream_id, :emoji_name, :created_at) L1416: SELECT * FROM users WHERE id = ? L1425: SELECT * FROM livestreams WHERE id = ? L1523: SELECT * FROM users WHERE name = ? L1533: SELECT * FROM users L1591: SELECT * FROM livestreams WHERE user_id = ? L1597: SELECT * FROM livecomments WHERE livestream_id = ? L1611: SELECT COUNT(*) FROM livestream_viewers_history WHERE livestream_id = ? L1664: SELECT * FROM livestreams WHERE id = ? L1673: SELECT * FROM livestreams L1681: SELECT COUNT(*) FROM livestreams l INNER JOIN reactions r ON l.id = r.livestream_id WHERE l.id = ? L1686: SELECT IFNULL(SUM(l2.tip), 0) FROM livestreams l INNER JOIN livecomments l2 ON l.id = l2.livestream_id WHERE l.id = ? L1721: SELECT COUNT(*) FROM livestreams l INNER JOIN reactions r ON r.livestream_id = l.id WHERE l.id = ? L1777: SELECT * FROM tags L1817: SELECT id FROM users WHERE name = ? L1826: SELECT * FROM themes WHERE user_id = ? L1940: SELECT * FROM users WHERE name = ? L1948: SELECT image FROM icons WHERE user_id = ? L1983: DELETE FROM icons WHERE user_id = ? L1987: INSERT INTO icons (user_id, image) VALUES (?, ?) L2026: SELECT * FROM users WHERE id = ? L2079: INSERT INTO users (name, display_name, description, password) VALUES(:name, :display_name, :description, :password) L2095: INSERT INTO themes (user_id, dark_mode) VALUES(:user_id, :dark_mode) L2134: SELECT * FROM users WHERE name = ? L2198: SELECT * FROM users WHERE name = ? L2243: SELECT * FROM themes WHERE user_id = ? L2248: SELECT image FROM icons WHERE user_id = ? ```

tetsuzawa commented 11 months ago

サービス一覧

Details

``` acpid.service loaded active running ACPI event daemon apparmor.service loaded active exited Load AppArmor profiles apport.service loaded active exited LSB: automatic crash report generation aws-env-isucon-subdomain-address.service loaded active exited run aws-env-isucon-subdomain-address once blk-availability.service loaded active exited Availability of block devices chrony.service loaded active running chrony, an NTP client/server cloud-config.service loaded active exited Apply the settings specified in cloud-config cloud-final.service loaded active exited Execute cloud user/final scripts cloud-init-local.service loaded active exited Initial cloud-init job (pre-networking) cloud-init.service loaded active exited Initial cloud-init job (metadata service crawler) console-setup.service loaded active exited Set console font and keymap cron.service loaded active running Regular background program processing daemon dbus.service loaded active running D-Bus System Message Bus envcheck.service loaded active exited Check Environments for ISUCON13 Contestants finalrd.service loaded active exited Create final runtime dir for shutdown pivot root getty@tty1.service loaded active running Getty on tty1 irqbalance.service loaded active running irqbalance daemon isupipe-go.service loaded active running isupipe-go keyboard-setup.service loaded active exited Set the console keyboard layout kmod-static-nodes.service loaded active exited Create List of Static Device Nodes lvm2-monitor.service loaded active exited Monitoring of LVM2 mirrors, snapshots etc. using dmeventd or progress polling multipathd.service loaded active running Device-Mapper Multipath Device Controller mysql.service loaded active running MySQL Community Server networkd-dispatcher.service loaded active running Dispatcher daemon for systemd-networkd nginx.service loaded active running A high performance web server and a reverse proxy server pdns.service loaded active running PowerDNS Authoritative Server plymouth-quit-wait.service loaded active exited Hold until boot process finishes up plymouth-quit.service loaded active exited Terminate Plymouth Boot Screen plymouth-read-write.service loaded active exited Tell Plymouth To Write Out Runtime Data polkit.service loaded active running Authorization Manager rsyslog.service loaded active running System Logging Service serial-getty@ttyS0.service loaded active running Serial Getty on ttyS0 setvtrgb.service loaded active exited Set console scheme snap.amazon-ssm-agent.amazon-ssm-agent.service loaded active running Service for snap application amazon-ssm-agent.amazon-ssm-agent snapd.apparmor.service loaded active exited Load AppArmor profiles managed internally by snapd snapd.seeded.service loaded active exited Wait until snapd is fully seeded snapd.service loaded active running Snap Daemon ssh.service loaded active running OpenBSD Secure Shell server systemd-binfmt.service loaded active exited Set Up Additional Binary Formats systemd-fsck-root.service loaded active exited File System Check on Root Device systemd-fsck@dev-disk-by\x2dlabel-UEFI.service loaded active exited File System Check on /dev/disk/by-label/UEFI systemd-journal-flush.service loaded active exited Flush Journal to Persistent Storage systemd-journald.service loaded active running Journal Service systemd-logind.service loaded active running User Login Management systemd-machine-id-commit.service loaded active exited Commit a transient machine-id on disk systemd-modules-load.service loaded active exited Load Kernel Modules systemd-networkd-wait-online.service loaded active exited Wait for Network to be Configured systemd-networkd.service loaded active running Network Configuration systemd-random-seed.service loaded active exited Load/Save Random Seed systemd-remount-fs.service loaded active exited Remount Root and Kernel File Systems systemd-resolved.service loaded active running Network Name Resolution systemd-sysctl.service loaded active exited Apply Kernel Variables systemd-sysusers.service loaded active exited Create System Users systemd-tmpfiles-setup-dev.service loaded active exited Create Static Device Nodes in /dev systemd-tmpfiles-setup.service loaded active exited Create Volatile Files and Directories systemd-udev-trigger.service loaded active exited Coldplug All udev Devices systemd-udevd.service loaded active running Rule-based Manager for Device Events and Files systemd-update-utmp.service loaded active exited Record System Boot/Shutdown in UTMP systemd-user-sessions.service loaded active exited Permit User Sessions ufw.service loaded active exited Uncomplicated firewall unattended-upgrades.service loaded active running Unattended Upgrades Shutdown user-runtime-dir@1100.service loaded active exited User Runtime Directory /run/user/1100 user@1100.service loaded active running User Manager for UID 1100 ```

mackee commented 11 months ago

handler一覧

Details

```go // 初期化 e.POST("/api/initialize", initializeHandler) // top e.GET("/api/tag", getTagHandler) e.GET("/api/user/:username/theme", getStreamerThemeHandler) // livestream // reserve livestream e.POST("/api/livestream/reservation", reserveLivestreamHandler) // list livestream e.GET("/api/livestream/search", searchLivestreamsHandler) e.GET("/api/livestream", getMyLivestreamsHandler) e.GET("/api/user/:username/livestream", getUserLivestreamsHandler) // get livestream e.GET("/api/livestream/:livestream_id", getLivestreamHandler) // get polling livecomment timeline e.GET("/api/livestream/:livestream_id/livecomment", getLivecommentsHandler) // ライブコメント投稿 e.POST("/api/livestream/:livestream_id/livecomment", postLivecommentHandler) e.POST("/api/livestream/:livestream_id/reaction", postReactionHandler) e.GET("/api/livestream/:livestream_id/reaction", getReactionsHandler) // (配信者向け)ライブコメントの報告一覧取得API e.GET("/api/livestream/:livestream_id/report", getLivecommentReportsHandler) e.GET("/api/livestream/:livestream_id/ngwords", getNgwords) // ライブコメント報告 e.POST("/api/livestream/:livestream_id/livecomment/:livecomment_id/report", reportLivecommentHandler) // 配信者によるモデレーション (NGワード登録) e.POST("/api/livestream/:livestream_id/moderate", moderateHandler) // livestream_viewersにINSERTするため必要 // ユーザ視聴開始 (viewer) e.POST("/api/livestream/:livestream_id/enter", enterLivestreamHandler) // ユーザ視聴終了 (viewer) e.DELETE("/api/livestream/:livestream_id/exit", exitLivestreamHandler) // user e.POST("/api/register", registerHandler) e.POST("/api/login", loginHandler) e.GET("/api/user/me", getMeHandler) // フロントエンドで、配信予約のコラボレーターを指定する際に必要 e.GET("/api/user/:username", getUserHandler) e.GET("/api/user/:username/statistics", getUserStatisticsHandler) e.GET("/api/user/:username/icon", getIconHandler) e.POST("/api/icon", postIconHandler) ```

tetsuzawa commented 11 months ago

sql、ハンドラ一覧

select(livecomments): select ifnull(sum(tip), 0) from livecomments
insert(reactions): insert into reactions (user_id, livestream_id, emoji_name, created_at) values (:user_id, :livestream_id, :emoji_name, :created_at)
delete(livestream_viewers_history): delete from livestream_viewers_history where user_id = ? and livestream_id = ?
select(tags): select id from tags where name = ?
select(livestream_tags): select * from livestream_tags where tag_id in (?) order by livestream_id desc
select(livestreams): select * from livestreams where id = ?
select(livestreams): select * from livestreams order by id desc
select(themes): select * from themes where user_id = ?
select(icons): select image from icons where user_id = ?
select(users): select * from users where id = ?
select(livecomments): select * from livecomments where id = ?
select(reservation_slots): select * from reservation_slots where start_at >= ? and end_at <= ? for update
select(reservation_slots): select slot from reservation_slots where start_at = ? and end_at = ?
update(reservation_slots): update reservation_slots set slot = slot - 1 where start_at >= ? and end_at <= ?
insert(livestreams): insert into livestreams (user_id, title, description, playlist_url, thumbnail_url, start_at, end_at) values(:user_id, :title, :description, :playlist_url, :thumbnail_url, :start_at, :end_at)
insert(livestream_tags): insert into livestream_tags (livestream_id, tag_id) values (:livestream_id, :tag_id)
select(users): select * from users where id = ?
select(livestream_tags): select * from livestream_tags where livestream_id = ?
select(tags): select * from tags where id = ?
select(livestreams): select * from livestreams where id = ? and user_id = ?
insert(ng_words): insert into ng_words(user_id, livestream_id, word, created_at) values (:user_id, :livestream_id, :word, :created_at)
select(ng_words): select * from ng_words where livestream_id = ?
select(livecomments): select * from livecomments
select(livestreams): select * from livestreams where id = ?
select(livecomments): select * from livecomments where id = ?
insert(livecomment_reports): insert into livecomment_reports(user_id, livestream_id, livecomment_id, created_at) values (:user_id, :livestream_id, :livecomment_id, :created_at)
select(users): select * from users where name = ?
select(users): select * from users where name = ?
select(livestreams): select * from livestreams where id = ?
select(users): select * from users where name = ?
select(icons): select image from icons where user_id = ?
select(users): select * from users where name = ?
select(livestreams): select * from livestreams where user_id = ?
insert(livestream_viewers_history): insert into livestream_viewers_history (user_id, livestream_id, created_at) values(:user_id, :livestream_id, :created_at)
select(livestreams): select * from livestreams where id = ?
select(livecomment_reports): select * from livecomment_reports where livestream_id = ?
select(users): select * from users where id = ?
select(livecomments): select * from livecomments where livestream_id = ? order by created_at desc
select(ng_words): select * from ng_words where user_id = ? and livestream_id = ? order by created_at desc
delete(icons): delete from icons where user_id = ?
insert(icons): insert into icons (user_id, image) values (?, ?)
select(users): select * from users where name = ?
select(users): select * from users
select(users): 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.name = ?

select(livestreams): 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.name = ?

select(reactions): 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.name = ?

select(livestreams): select * from livestreams where user_id = ?
select(livecomments): select * from livecomments where livestream_id = ?
select(livestream_viewers_history): select count(*) from livestream_viewers_history where livestream_id = ?
select(users): select * from users where id = ?
select(livestreams): select * from livestreams where id = ?
select(reactions): select * from reactions where livestream_id = ? order by created_at desc
select(livestreams): select * from livestreams where id = ?
select(ng_words): select id, user_id, livestream_id, word from ng_words where user_id = ? and livestream_id = ?
insert(livecomments): insert into livecomments (user_id, livestream_id, comment, tip, created_at) values (:user_id, :livestream_id, :comment, :tip, :created_at)
select(tags): select * from tags
select(users): select * from users where id = ?
select(livestreams): select * from livestreams where id = ?
select(users): select id from users where name = ?
select(themes): select * from themes where user_id = ?
select(livestreams): select * from livestreams where user_id = ?
select(livestreams): select * from livestreams where id = ?
select(livestreams): select * from livestreams
select(livestreams): select count(*) from livestreams l inner join reactions r on l.id = r.livestream_id where l.id = ?
select(reactions): select count(*) from livestreams l inner join reactions r on l.id = r.livestream_id where l.id = ?
select(livestreams): select ifnull(sum(l2.tip), 0) from livestreams l inner join livecomments l2 on l.id = l2.livestream_id where l.id = ?
select(livecomments): select ifnull(sum(l2.tip), 0) from livestreams l inner join livecomments l2 on l.id = l2.livestream_id where l.id = ?
select(livestreams): select count(*) from livestreams l inner join livestream_viewers_history h on h.livestream_id = l.id where l.id = ?
select(livestream_viewers_history): select count(*) from livestreams l inner join livestream_viewers_history h on h.livestream_id = l.id where l.id = ?
select(livestreams): select ifnull(max(tip), 0) from livestreams l inner join livecomments l2 on l2.livestream_id = l.id where l.id = ?
select(livecomments): select ifnull(max(tip), 0) from livestreams l inner join livecomments l2 on l2.livestream_id = l.id where l.id = ?
select(livestreams): select count(*) from livestreams l inner join reactions r on r.livestream_id = l.id where l.id = ?
select(reactions): select count(*) from livestreams l inner join reactions r on r.livestream_id = l.id where l.id = ?
select(livestreams): select count(*) from livestreams l inner join livecomment_reports r on r.livestream_id = l.id where l.id = ?
select(livecomment_reports): select count(*) from livestreams l inner join livecomment_reports r on r.livestream_id = l.id where l.id = ?
insert(users): insert into users (name, display_name, description, password) values(:name, :display_name, :description, :password)
insert(themes): insert into themes (user_id, dark_mode) values(:user_id, :dark_mode)

DB Graph

node: テーブル 関数

edge: INSERT UPDATE DELETE SELECT 関数呼び出し

graph LR
  classDef table fill:#795548,fill-opacity:0.5
  classDef func fill:#1976D2,fill-opacity:0.5
  func:github.com/isucon/isucon13/webapp/go.getStreamerThemeHandler[getStreamerThemeHandler]:::func --> table:themes[themes]:::table
  func:github.com/isucon/isucon13/webapp/go.getStreamerThemeHandler[getStreamerThemeHandler]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.getMyLivestreamsHandler[getMyLivestreamsHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.getMyLivestreamsHandler[getMyLivestreamsHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.getUserHandler[getUserHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillUserResponse[fillUserResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.getUserHandler[getUserHandler]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.getNgwords[getNgwords]:::func --> table:ng_words[ng_words]:::table
  func:github.com/isucon/isucon13/webapp/go.getLivestreamStatisticsHandler[getLivestreamStatisticsHandler]:::func --> table:livecomment_reports[livecomment_reports]:::table
  func:github.com/isucon/isucon13/webapp/go.getLivestreamStatisticsHandler[getLivestreamStatisticsHandler]:::func --> table:livecomments[livecomments]:::table
  func:github.com/isucon/isucon13/webapp/go.getLivestreamStatisticsHandler[getLivestreamStatisticsHandler]:::func --> table:livestream_viewers_history[livestream_viewers_history]:::table
  func:github.com/isucon/isucon13/webapp/go.getLivestreamStatisticsHandler[getLivestreamStatisticsHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.getLivestreamStatisticsHandler[getLivestreamStatisticsHandler]:::func --> table:reactions[reactions]:::table
  func:github.com/isucon/isucon13/webapp/go.getUserLivestreamsHandler[getUserLivestreamsHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.getUserLivestreamsHandler[getUserLivestreamsHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.getUserLivestreamsHandler[getUserLivestreamsHandler]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.moderateHandler[moderateHandler]:::func --> table:livecomments[livecomments]:::table
  func:github.com/isucon/isucon13/webapp/go.moderateHandler[moderateHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.moderateHandler[moderateHandler]:::func --> table:ng_words[ng_words]:::table
  func:github.com/isucon/isucon13/webapp/go.moderateHandler[moderateHandler]:::func --> table:ng_words[ng_words]:::table
  func:github.com/isucon/isucon13/webapp/go.searchLivestreamsHandler[searchLivestreamsHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.searchLivestreamsHandler[searchLivestreamsHandler]:::func --> table:livestream_tags[livestream_tags]:::table
  func:github.com/isucon/isucon13/webapp/go.searchLivestreamsHandler[searchLivestreamsHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.searchLivestreamsHandler[searchLivestreamsHandler]:::func --> table:tags[tags]:::table
  func:github.com/isucon/isucon13/webapp/go.reserveLivestreamHandler[reserveLivestreamHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.reserveLivestreamHandler[reserveLivestreamHandler]:::func --> table:livestream_tags[livestream_tags]:::table
  func:github.com/isucon/isucon13/webapp/go.reserveLivestreamHandler[reserveLivestreamHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.reserveLivestreamHandler[reserveLivestreamHandler]:::func --> table:reservation_slots[reservation_slots]:::table
  func:github.com/isucon/isucon13/webapp/go.reserveLivestreamHandler[reserveLivestreamHandler]:::func --> table:reservation_slots[reservation_slots]:::table
  func:github.com/isucon/isucon13/webapp/go.reserveLivestreamHandler[reserveLivestreamHandler]:::func --> table:reservation_slots[reservation_slots]:::table
  func:github.com/isucon/isucon13/webapp/go.loginHandler[loginHandler]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.fillReactionResponse[fillReactionResponse]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.fillReactionResponse[fillReactionResponse]:::func --> func:github.com/isucon/isucon13/webapp/go.fillUserResponse[fillUserResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.fillReactionResponse[fillReactionResponse]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.fillReactionResponse[fillReactionResponse]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.getUserStatisticsHandler[getUserStatisticsHandler]:::func --> table:livecomments[livecomments]:::table
  func:github.com/isucon/isucon13/webapp/go.getUserStatisticsHandler[getUserStatisticsHandler]:::func --> table:livestream_viewers_history[livestream_viewers_history]:::table
  func:github.com/isucon/isucon13/webapp/go.getUserStatisticsHandler[getUserStatisticsHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.getUserStatisticsHandler[getUserStatisticsHandler]:::func --> table:reactions[reactions]:::table
  func:github.com/isucon/isucon13/webapp/go.getUserStatisticsHandler[getUserStatisticsHandler]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.getLivecommentReportsHandler[getLivecommentReportsHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivecommentReportResponse[fillLivecommentReportResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.getLivecommentReportsHandler[getLivecommentReportsHandler]:::func --> table:livecomment_reports[livecomment_reports]:::table
  func:github.com/isucon/isucon13/webapp/go.getLivecommentReportsHandler[getLivecommentReportsHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.postIconHandler[postIconHandler]:::func --> table:icons[icons]:::table
  func:github.com/isucon/isucon13/webapp/go.postIconHandler[postIconHandler]:::func --> table:icons[icons]:::table
  func:github.com/isucon/isucon13/webapp/go.getMeHandler[getMeHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillUserResponse[fillUserResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.getMeHandler[getMeHandler]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.postReactionHandler[postReactionHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillReactionResponse[fillReactionResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.postReactionHandler[postReactionHandler]:::func --> table:reactions[reactions]:::table
  func:github.com/isucon/isucon13/webapp/go.getIconHandler[getIconHandler]:::func --> table:icons[icons]:::table
  func:github.com/isucon/isucon13/webapp/go.getIconHandler[getIconHandler]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.fillUserResponse[fillUserResponse]:::func --> table:icons[icons]:::table
  func:github.com/isucon/isucon13/webapp/go.fillUserResponse[fillUserResponse]:::func --> table:themes[themes]:::table
  func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func --> func:github.com/isucon/isucon13/webapp/go.fillUserResponse[fillUserResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func --> table:livestream_tags[livestream_tags]:::table
  func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func --> table:tags[tags]:::table
  func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.fillLivecommentReportResponse[fillLivecommentReportResponse]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivecommentResponse[fillLivecommentResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.fillLivecommentReportResponse[fillLivecommentReportResponse]:::func --> func:github.com/isucon/isucon13/webapp/go.fillUserResponse[fillUserResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.fillLivecommentReportResponse[fillLivecommentReportResponse]:::func --> table:livecomments[livecomments]:::table
  func:github.com/isucon/isucon13/webapp/go.fillLivecommentReportResponse[fillLivecommentReportResponse]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.postLivecommentHandler[postLivecommentHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivecommentResponse[fillLivecommentResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.postLivecommentHandler[postLivecommentHandler]:::func --> table:livecomments[livecomments]:::table
  func:github.com/isucon/isucon13/webapp/go.postLivecommentHandler[postLivecommentHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.postLivecommentHandler[postLivecommentHandler]:::func --> table:ng_words[ng_words]:::table
  func:GetPaymentResult[GetPaymentResult]:::func --> table:livecomments[livecomments]:::table
  func:github.com/isucon/isucon13/webapp/go.getReactionsHandler[getReactionsHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillReactionResponse[fillReactionResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.getReactionsHandler[getReactionsHandler]:::func --> table:reactions[reactions]:::table
  func:github.com/isucon/isucon13/webapp/go.getLivestreamHandler[getLivestreamHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.getLivestreamHandler[getLivestreamHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.enterLivestreamHandler[enterLivestreamHandler]:::func --> table:livestream_viewers_history[livestream_viewers_history]:::table
  func:github.com/isucon/isucon13/webapp/go.registerHandler[registerHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillUserResponse[fillUserResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.registerHandler[registerHandler]:::func --> table:themes[themes]:::table
  func:github.com/isucon/isucon13/webapp/go.registerHandler[registerHandler]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.reportLivecommentHandler[reportLivecommentHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivecommentReportResponse[fillLivecommentReportResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.reportLivecommentHandler[reportLivecommentHandler]:::func --> table:livecomment_reports[livecomment_reports]:::table
  func:github.com/isucon/isucon13/webapp/go.reportLivecommentHandler[reportLivecommentHandler]:::func --> table:livecomments[livecomments]:::table
  func:github.com/isucon/isucon13/webapp/go.reportLivecommentHandler[reportLivecommentHandler]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.getLivecommentsHandler[getLivecommentsHandler]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivecommentResponse[fillLivecommentResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.getLivecommentsHandler[getLivecommentsHandler]:::func --> table:livecomments[livecomments]:::table
  func:github.com/isucon/isucon13/webapp/go.fillLivecommentResponse[fillLivecommentResponse]:::func --> func:github.com/isucon/isucon13/webapp/go.fillLivestreamResponse[fillLivestreamResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.fillLivecommentResponse[fillLivecommentResponse]:::func --> func:github.com/isucon/isucon13/webapp/go.fillUserResponse[fillUserResponse]:::func
  func:github.com/isucon/isucon13/webapp/go.fillLivecommentResponse[fillLivecommentResponse]:::func --> table:livestreams[livestreams]:::table
  func:github.com/isucon/isucon13/webapp/go.fillLivecommentResponse[fillLivecommentResponse]:::func --> table:users[users]:::table
  func:github.com/isucon/isucon13/webapp/go.getTagHandler[getTagHandler]:::func --> table:tags[tags]:::table
  func:github.com/isucon/isucon13/webapp/go.exitLivestreamHandler[exitLivestreamHandler]:::func --> table:livestream_viewers_history[livestream_viewers_history]:::table
  linkStyle 0,1,3,5,6,7,8,9,10,11,13,14,15,16,17,20,21,22,26,28,29,32,33,34,35,36,37,38,40,41,45,48,49,50,51,53,54,55,58,59,62,63,64,66,68,75,76,78,81,82,83 stroke:#78909C,stroke-width:2px
  linkStyle 2,4,12,19,23,30,31,39,44,46,52,56,57,60,65,67,70,73,77,79,80 stroke:#BBDEFB,stroke-width:2px
  linkStyle 18,24,25,43,47,61,69,71,72,74 stroke:#CDDC39,stroke-width:2px
  linkStyle 27 stroke:#FF9800,stroke-width:2px
  linkStyle 42,84 stroke:#F44336,stroke-width:2px
soudai commented 11 months ago

livecomment_handler.go.

L87: SELECT * FROM livecomments WHERE livestream_id = ? ORDER BY created_at DESC
L146: SELECT * FROM ng_words WHERE user_id = ? AND livestream_id = ? ORDER BY created_at DESC
L191: SELECT * FROM livestreams WHERE id = ?
L201: SELECT id, user_id, livestream_id, word FROM ng_words WHERE user_id = ? AND livestream_id = ?
L233: INSERT INTO livecomments (user_id, livestream_id, comment, tip, created_at) VALUES (:user_id, :livestream_id, :comment, :tip, :created_at)
L285: SELECT * FROM livestreams WHERE id = ?
L294: SELECT * FROM livecomments WHERE id = ?
L309: INSERT INTO livecomment_reports(user_id, livestream_id, livecomment_id, created_at) VALUES (:user_id, :livestream_id, :livecomment_id, :created_at)
L362: SELECT * FROM livestreams WHERE id = ? AND user_id = ?
L369: INSERT INTO ng_words(user_id, livestream_id, word, created_at) VALUES (:user_id, :livestream_id, :word, :created_at)
L385: SELECT * FROM ng_words WHERE livestream_id = ?
L393: SELECT * FROM livecomments
L427: SELECT * FROM users WHERE id = ?
L436: SELECT * FROM livestreams WHERE id = ?
L458: SELECT * FROM users WHERE id = ?
L467: SELECT * FROM livecomments WHERE id = ?