apache/seatunnel · error · IllegalArgumentException
The jobId must not be empty.
Error message
The jobId must not be empty.
What it means
CheckpointOverviewServlet.doGet extracts the jobId from path info; if pathInfo is null or just a slash it throws IllegalArgumentException because checkpoint overview data is per-job. The servlet serves a single job's checkpoint overview at GET .../<jobId>.
Source
Thrown at seatunnel-engine/seatunnel-engine-server/src/main/java/org/apache/seatunnel/engine/server/rest/servlet/CheckpointOverviewServlet.java:44
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
public class CheckpointOverviewServlet extends BaseServlet {
private final CheckpointMonitorRestService restService;
public CheckpointOverviewServlet(NodeEngineImpl nodeEngine) {
super(nodeEngine);
this.restService = new CheckpointMonitorRestService(nodeEngine);
}
@Override
protected void doGet(HttpServletRequest req, HttpServletResponse resp)
throws ServletException, IOException {
String jobIdStr = req.getPathInfo();
if (jobIdStr == null || jobIdStr.length() <= 1) {
throw new IllegalArgumentException("The jobId must not be empty.");
}
long jobId = Long.parseLong(jobIdStr.substring(1));
writeJson(resp, restService.getOverview(jobId));
}
}
View on GitHub (pinned to cf67b549a7)
Solutions
- Call the endpoint with a valid numeric job id in the path, e.g. /checkpoint-overview/882721898075455489
- Guard the client code so the request is only made when jobId is set
- Return HTTP 400 instead of an unhandled exception for blank ids
- Verify any URL-rewriting middleware preserves the path segment
Example fix
// before String url = "/checkpoint-overview"; // no jobId // after String url = "/checkpoint-overview/" + jobId.toString();
Defensive patterns
Strategy: validation
Validate before calling
if (jobId == null) throw new IllegalStateException("jobId not set; cannot query checkpoint overview"); Type guard
boolean hasJobId(String pathInfo) { return pathInfo != null && pathInfo.length() > 1; } Try / catch
try { overview = getOverview(jobId); } catch (IllegalArgumentException e) { renderUsageError("checkpoint-overview/<jobId>"); } Prevention
- Never call monitoring endpoints before job submission returns an id
- Guard UI code with jobId presence checks
- Keep the jobId in request-scoped state, not static state
When it happens
Trigger: GET the checkpoint-overview endpoint with no /<jobId> suffix, e.g. GET /checkpoint-overview/ or a request whose pathInfo resolves to null.
Common situations: Dashboards constructing the URL with an empty job variable; job id lost after restart of the calling tool; user hitting the servlet root directly in a browser.
Understand the failure class
Background: "must not be empty", "cannot be empty" — required-field validation errors across open-source libraries — this error's family across 41 libraries.
Related errors
- The jobId must not be empty.
- The jobId must not be empty.
- Parameter 'pluginName' cannot be empty.
- Page number must be greater than 0
- Page number exceeds total pages
AI-assisted analysis of apache/seatunnel@cf67b549a7 (2026-09-10).
Data as JSON: /api/errors/e74cbb5ee4e263db.
Report an issue: GitHub.