pentaho/pentaho-kettle · error · KettleException
ExecuteJobServlet.Error.JobNotFoundInDirectory
ExecuteJobServlet.Error.JobNotFoundInDirectory
Error message
ExecuteJobServlet.Error.JobNotFoundInDirectory
What it means
KettleException thrown by ExecuteJobServlet.loadJob when repository.getJobId(name, directory) returns null — the job exists in the URL but no job metadata object with that name is stored in the resolved repository directory. The directory was found but the job inside it was not.
Solutions
- Verify the job name exists in the target directory via Spoon's repository explorer
- Correct the job parameter in the request URL to the actual job name
- Search the repository for the job and update clients to the new path/name
- If the job was deleted, redeploy or restore it
- Check for case-sensitivity or extra extension (.kjb) issues in the name
Example fix
// before String jobParam = "/home/admin/nightly_load"; // job was renamed // after String jobParam = "/home/admin/nightly_etl_load"; // matches repository name
Defensive patterns
Strategy: validation
Validate before calling
RepositoryDirectoryInterface dir = repo.loadRepositoryDirectoryTree().findDirectory( dirPath ); boolean exists = dir != null && repo.getJobId( jobName, dir ) != null;
Try / catch
try {
// executeJob request
} catch ( KettleException e ) {
LOG.error( "Job not found: " + jobName + " in " + dirPath + " — check rename/move", e );
} Prevention
- Look up job ObjectIds instead of hardcoding name/path in URLs
- Update all clients/schedulers when jobs are renamed or moved
- Verify job names with repository explorer before external execution
- Avoid embedding repository paths in long-lived scripts
When it happens
Trigger: HTTP GET /kettle/executeJob/ with job=/path/name pointing at a valid directory, but getJobId() finds no job named 'name' in that directory (job renamed, deleted, or never saved there).
Common situations: Job renamed or moved to another directory; wrong directory in the URL while the job lives elsewhere; request cached from before the job was deleted; name mismatch including extension or case.
Understand the failure class
Background: "Not found" and "does not exist" errors: why "Task not found", "No such folder", and "Can't find" fire when a lookup comes back empty — this error's family across 14 libraries.
Related errors
- ExecuteJobServlet.Error.DirectoryPathNotFoundInRepository
- ExecuteJobServlet.Error.UnableToFindRepository
- Repository required.
- Unable to find repository: " + repositoryName
- Unable to find transformation '" + name + "' in directory…
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/17dfc255fe050164.
Report an issue: GitHub.
Appendix: source
Thrown at engine/src/main/java/org/pentaho/di/www/ExecuteJobServlet.java:363
int lastSlash = job.lastIndexOf( RepositoryDirectory.DIRECTORY_SEPARATOR );
if ( lastSlash < 0 ) {
directoryPath = "/";
name = job;
} else {
directoryPath = job.substring( 0, lastSlash );
name = job.substring( lastSlash + 1 );
}
RepositoryDirectoryInterface directory =
repository.loadRepositoryDirectoryTree().findDirectory( directoryPath );
if ( directory == null ) {
String message = BaseMessages.getString( PKG, "ExecuteJobServlet.Error.DirectoryPathNotFoundInRepository", directoryPath );
throw new KettleException( message );
}
ObjectId jobID = repository.getJobId( name, directory );
if ( jobID == null ) {
String message = BaseMessages.getString( PKG, "ExecuteJobServlet.Error.JobNotFoundInDirectory", name, directoryPath );
throw new KettleException( message );
}
JobMeta jobMeta = repository.loadJob( jobID, null, parentVariableSpace );
return jobMeta;
}
}
@VisibleForTesting
Repository openRepository( String repositoryName, String user, String pass ) throws KettleException {
if ( Utils.isEmpty( repositoryName ) ) {
return null;
}
RepositoriesMeta repositoriesMeta = new RepositoriesMeta();
repositoriesMeta.readData();
RepositoryMeta repositoryMeta = repositoriesMeta.findRepository( repositoryName );
if ( repositoryMeta == null ) {
String message = BaseMessages.getString( PKG, "ExecuteJobServlet.Error.UnableToFindRepository", repositoryName );View on GitHub (pinned to f3058517a1)