import { model, Schema } from 'mongoose';
const branchStatsSchema = new Schema({
    collectionName: { type: String, required: true },
    project: { type: String, required: true },
    repositoryId: { type: String, required: true },
    name: { type: String, required: true },
    date: { type: Date, required: true },
    aheadCount: { type: Number, required: true },
    behindCount: { type: Number, required: true },
    isBaseVersion: { type: Boolean, required: true },
}, { timestamps: true });
branchStatsSchema.index({
    collectionName: 1,
    project: 1,
    repositoryId: 1,
});
export const BranchModel = model('Branch', branchStatsSchema);
