From 4ecf16d38739a7acedb49d611faebc2d15091aa5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B6=8C=ED=98=81=EC=84=B1?= Date: Fri, 13 Feb 2026 09:29:43 +0900 Subject: [PATCH] =?UTF-8?q?fix:quote=5Frevisions=20=EC=A1=B0=ED=9A=8C=20?= =?UTF-8?q?=EC=8B=9C=20MySQL=20Out=20of=20sort=20memory=20=EC=97=90?= =?UTF-8?q?=EB=9F=AC=20=ED=95=B4=EA=B2=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - quote_revisions(quote_id, tenant_id, revision_number) 복합 인덱스 추가 - previous_data JSON 대용량 컬럼 포함 정렬 시 filesort OOM 방지 Co-Authored-By: Claude Opus 4.6 --- ...mposite_index_to_quote_revisions_table.php | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 database/migrations/2026_02_13_092914_add_composite_index_to_quote_revisions_table.php diff --git a/database/migrations/2026_02_13_092914_add_composite_index_to_quote_revisions_table.php b/database/migrations/2026_02_13_092914_add_composite_index_to_quote_revisions_table.php new file mode 100644 index 0000000..4b5910a --- /dev/null +++ b/database/migrations/2026_02_13_092914_add_composite_index_to_quote_revisions_table.php @@ -0,0 +1,28 @@ +index(['quote_id', 'tenant_id', 'revision_number'], 'idx_quote_revisions_quote_tenant_revision'); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::table('quote_revisions', function (Blueprint $table) { + $table->dropIndex('idx_quote_revisions_quote_tenant_revision'); + }); + } +};