mirror of
https://github.com/zkldi/Tachi.git
synced 2026-09-30 02:48:01 +03:00
Merge pull request #616 from TNG-dev:zkldi/issue-606
Add various game specific indexes to optimise more "odd" chart access methods.
This commit is contained in:
Vendored
+11
-1
@@ -70,7 +70,6 @@ const staticIndexes: Partial<Record<Databases, Index[]>> = {
|
||||
),
|
||||
index({ "data.hashSHA256": 1 }),
|
||||
],
|
||||
"charts-bms": [index({ "data.hashMD5": 1 }, UNIQUE), index({ "data.hashSHA256": 1 }, UNIQUE)],
|
||||
"bms-course-lookup": [index({ md5sums: 1 }, UNIQUE)],
|
||||
"api-tokens": [index({ token: 1 }, UNIQUE), index({ userID: 1 })],
|
||||
tables: [index({ tableID: 1, game: 1, playtype: 1 }, UNIQUE)],
|
||||
@@ -85,7 +84,18 @@ const staticIndexes: Partial<Record<Databases, Index[]>> = {
|
||||
counters: [index({ counterName: 1 }, UNIQUE)],
|
||||
"class-achievements": [index({ game: 1, playtype: 1, timeAchieved: 1 })],
|
||||
"api-clients": [index({ clientID: 1 }, UNIQUE)],
|
||||
"charts-bms": [index({ "data.hashMD5": 1 }, UNIQUE), index({ "data.hashSHA256": 1 }, UNIQUE)],
|
||||
"charts-popn": [index({ "data.hashSHA256": 1 }, UNIQUE)],
|
||||
"charts-sdvx": [index({ "data.inGameID": 1 }, UNIQUE)],
|
||||
"charts-maimai": [
|
||||
index({ "data.inGameID": 1 }, UNIQUE),
|
||||
index({ "data.inGameStrID": 1 }, UNIQUE),
|
||||
],
|
||||
"charts-museca": [index({ "data.inGameID": 1 }, UNIQUE)],
|
||||
"charts-chunithm": [index({ "data.inGameID": 1 }, UNIQUE)],
|
||||
"charts-gitadora": [index({ "data.inGameID": 1 }, UNIQUE)],
|
||||
"charts-wacca": [index({ isHot: 1 })],
|
||||
"charts-usc": [index({ "data.hashSHA1": 1 }, UNIQUE)],
|
||||
};
|
||||
|
||||
const indexes: Partial<Record<Databases, Index[]>> = staticIndexes;
|
||||
|
||||
Reference in New Issue
Block a user