mirror of
https://github.com/PretendoNetwork/BOSS.git
synced 2026-03-21 17:34:19 -05:00
fix: add databases indexes so things aren't slow™️
Some checks failed
Build and Publish Docker Image / build-publish (push) Has been cancelled
Some checks failed
Build and Publish Docker Image / build-publish (push) Has been cancelled
This commit is contained in:
parent
00ceec5b46
commit
837cccd04f
|
|
@ -7,7 +7,9 @@ const CECDataSchema = new mongoose.Schema<ICECData, CECDataModel, ICECDataMethod
|
|||
data: String,
|
||||
data_hash: String,
|
||||
size: Number,
|
||||
created: BigInt
|
||||
created: { type: BigInt, index: true }
|
||||
});
|
||||
|
||||
CECDataSchema.index({ creator_pid: 1, game_id: 1 });
|
||||
|
||||
export const CECData = mongoose.model<ICECData, CECDataModel>('CECData', CECDataSchema);
|
||||
|
|
|
|||
|
|
@ -7,4 +7,6 @@ const CECSlotSchema = new mongoose.Schema<ICECSlot, CECSlotModel, ICECSlotMethod
|
|||
latest_data_id: String
|
||||
});
|
||||
|
||||
CECSlotSchema.index({ creator_pid: 1, game_id: 1 });
|
||||
|
||||
export const CECSlot = mongoose.model<ICECSlot, CECSlotModel>('CECSlot', CECSlotSchema);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user