[FileBackend] Simplified fj_batch_id index
authorAaron <aschulz@wikimedia.org>
Wed, 11 Apr 2012 20:11:07 +0000 (13:11 -0700)
committerChad Horohoe <chadh@wikimedia.org>
Thu, 12 Apr 2012 22:26:41 +0000 (18:26 -0400)
If we want to sort the ops for a batch ID, we can just use a tiny to small filesort.
No need to make the index bigger.

Change-Id: Ibf7592930ec633a26e675e33d42aebe7763547b1

maintenance/archives/patch-filejournal.sql

index 8c2f6b9..114297c 100644 (file)
@@ -18,5 +18,5 @@ CREATE TABLE /*_*/filejournal (
   fj_timestamp varbinary(14) NOT NULL default ''
 );
 
-CREATE INDEX /*i*/fj_batch_id ON /*_*/filejournal (fj_batch_uuid,fj_id);
+CREATE INDEX /*i*/fj_batch_id ON /*_*/filejournal (fj_batch_uuid);
 CREATE INDEX /*i*/fj_timestamp ON /*_*/filejournal (fj_timestamp);