ワンクリックで
icon-caching
General techniques for optimizing user icon/avatar image serving in ISUCON web applications
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
General techniques for optimizing user icon/avatar image serving in ISUCON web applications
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
MCP tool reference — exec, benchmark_start, benchmark_status, note_write, etc. Use when: executing commands on VMs, running benchmarks, or recording findings
ISUCON13 contest manual — server topology, service management, benchmark execution, and rules. Use when: checking environment setup, running benchmarks, or understanding contest constraints
ISUPipe application manual — features, terms, constraints, and API specs. Use when: understanding the app domain, checking API behavior or MUST/MAY requirements
General strategy for identifying and adding missing database indexes in ISUCON web applications
General techniques for identifying and fixing N+1 query problems in ISUCON web applications
Install and use alp (Access Log Profiler) to identify slow nginx endpoints and analyze request patterns
SOC 職業分類に基づく
| name | icon-caching |
| description | General techniques for optimizing user icon/avatar image serving in ISUCON web applications |
ISUCON の Web アプリでは、ユーザーアイコンやプロフィール画像を DB (BLOB) に格納していることが多い。リクエストごとに大きな BLOB を読み出すのはボトルネックになりやすい。
If-None-Match ヘッダーとハッシュを比較304 Not Modified(ボディなし)200 OK + ETag ヘッダー付きで画像返却// 例: Go (echo)
hash := fmt.Sprintf("%x", sha256.Sum256(imageData))
if c.Request().Header.Get("If-None-Match") == fmt.Sprintf(`"%s"`, hash) {
return c.NoContent(http.StatusNotModified)
}
c.Response().Header().Set("ETag", fmt.Sprintf(`"%s"`, hash))
return c.Blob(http.StatusOK, "image/jpeg", imageData)
sendfile + etag on で直接配信POST /api/initialize でデータリセットされる場合、キャッシュも適切にクリアする