jeecgboot/JeecgBoot · error · ParseException
Increment >= 7 : {incr}
Error message
Increment >= 7 : {incr} What it means
checkIncrementRange rejects a step value greater than 7 for DAY_OF_WEEK (weekdays range 1-7). A step like '/8' is invalid. Message echoes the increment.
Source
Thrown at jeecg-boot/jeecg-server-cloud/jeecg-visual/jeecg-cloud-xxljob/src/main/java/com/xxl/job/admin/business/scheduler/cron/CronExpression.java:734
i = checkNext(i, s, val, type);
return i;
}
} else {
throw new ParseException("Unexpected character: " + c, i);
}
return i;
}
private void checkIncrementRange(int incr, int type, int idxPos) throws ParseException {
if (incr > 59 && (type == SECOND || type == MINUTE)) {
throw new ParseException("Increment >= 60 : " + incr, idxPos);
} else if (incr > 23 && (type == HOUR)) {
throw new ParseException("Increment >= 24 : " + incr, idxPos);
} else if (incr > 31 && (type == DAY_OF_MONTH)) {
throw new ParseException("Increment >= 31 : " + incr, idxPos);
} else if (incr > 7 && (type == DAY_OF_WEEK)) {
throw new ParseException("Increment >= 7 : " + incr, idxPos);
} else if (incr > 12 && (type == MONTH)) {
throw new ParseException("Increment >= 12 : " + incr, idxPos);
}
}
protected int checkNext(int pos, String s, int val, int type)
throws ParseException {
int end = -1;
int i = pos;
if (i >= s.length()) {
addToSet(val, end, -1, type);
return i;
}
char c = s.charAt(pos);
View on GitHub (pinned to 96fb33f5ec)
Solutions
- Cap day-of-week steps at 7; common values are '/2' (every other day within the week).
- For 'every N weeks' there is no single cron field - schedule a job and skip runs in your code, or compute fire times explicitly.
- Clamp computed dow steps to 1-7.
Example fix
// before - day-of-week step > 7 String cron = "0 0 0 ? * 1/8"; // Increment >= 7 : 8 // after - valid dow step (every other day) String cron = "0 0 0 ? * 1/2";
Defensive patterns
Strategy: validation
Validate before calling
// DAY_OF_WEEK step must be <= 7.
public static String validateDowStep(String dowField) {
return validateStepRange(dowField, 7);
}
// (validateStepRange as defined in error 295) Type guard
public static boolean dowStepValid(String dowField) {
return stepWithinMax(dowField, 7);
} Try / catch
try {
new CronExpression(expr);
} catch (ParseException e) {
if (e.getMessage().startsWith("Increment >= 7")) {
return "Day-of-week steps must be <= 7; Quartz has no native multi-week step. " + e.getMessage();
}
throw e;
} Prevention
- Clamp day-of-week steps to 7.
- For 'every N weeks', filter runs in application code rather than using a dow step.
- Validate dow-step bounds in the cron builder.
When it happens
Trigger: Day-of-week step out of range: '0 0 0 ? * 1/8', or a computed weekly interval > 7 placed in the dow field.
Common situations: Confusing dow step with a multi-week interval (Quartz has no native 'every N weeks' via dow step beyond 7); dynamic step generation without bounds; off-by-one around 7.
Related errors
- Invalid Day-of-Week value: '{sub}'
- A numeric value between 1 and 5 must follow the '#' option
- '/' must be followed by an integer.
- Unexpected end of string.
- Increment >= 60 : {incr}
AI-assisted analysis of jeecgboot/JeecgBoot@96fb33f5ec (2026-08-14).
Data as JSON: /api/errors/870026ac765326cc.
Report an issue: GitHub.