mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-28 09:03:53 +00:00
feat: add training retry time (#3187)
* feat: add training retry time * remoce log
This commit is contained in:
@@ -39,11 +39,13 @@ export async function generateQA(): Promise<any> {
|
||||
try {
|
||||
const data = await MongoDatasetTraining.findOneAndUpdate(
|
||||
{
|
||||
lockTime: { $lte: addMinutes(new Date(), -6) },
|
||||
mode: TrainingModeEnum.qa
|
||||
mode: TrainingModeEnum.qa,
|
||||
retryCount: { $gte: 0 },
|
||||
lockTime: { $lte: addMinutes(new Date(), -6) }
|
||||
},
|
||||
{
|
||||
lockTime: new Date()
|
||||
lockTime: new Date(),
|
||||
$inc: { retryCount: -1 }
|
||||
}
|
||||
)
|
||||
.select({
|
||||
|
Reference in New Issue
Block a user