MongoDB/Mongoose index make query faster or slow it down?
问题 I have an article model like this: var ArticleSchema = new Schema({ type: String ,title: String ,content: String ,hashtags: [String] ,comments: [{ type: Schema.ObjectId ,ref: 'Comment' }] ,replies: [{ type: Schema.ObjectId ,ref: 'Reply' }] , status: String ,statusMeta: { createdBy: { type: Schema.ObjectId ,ref: 'User' } ,createdDate: Date , updatedBy: { type: Schema.ObjectId ,ref: 'User' } ,updatedDate: Date ,deletedBy: { type: Schema.ObjectId, ref: 'User' } ,deletedDate: Date ,undeletedBy: {