{"record":{"id":"b84669da8b5c2576","repo":"pentaho/pentaho-kettle","slug":"not-found","errorCode":null,"errorMessage":"Not found:","messagePattern":"Not found:","errorType":"exception","errorClass":"ContentIOException","httpStatus":null,"severity":"error","filePath":"plugins/pentaho-reporting/impl/src/main/java/org/pentaho/di/trans/steps/pentahoreporting/urlrepository/FileObjectContentLocation.java","lineNumber":124,"sourceCode":"  }\n\n  /**\n   * Returns the content entity with the given name. If the entity does not exist, an Exception will be raised.\n   *\n   * @param name the name of the entity to be retrieved.\n   * @return the content entity for this name, never null.\n   * @throws ContentIOException if an repository error occured.\n   */\n  public ContentEntity getEntry( final String name ) throws ContentIOException {\n    try {\n      if ( RepositoryUtilities.isInvalidPathName( name ) ) {\n        throw new IllegalArgumentException( \"The name given is not valid.\" );\n      }\n\n      final FileObject file = getBackend();\n      final FileObject child = file.resolveFile( name );\n      if ( child.exists() == false ) {\n        throw new ContentIOException( \"Not found:\" + child );\n      }\n\n      if ( child.isFolder() ) {\n        return new FileObjectContentLocation( this, child );\n      } else if ( child.isFile() ) {\n        return new FileObjectContentItem( this, child );\n      } else {\n        throw new ContentIOException( \"Not File nor directory.\" );\n      }\n    } catch ( FileSystemException e ) {\n      throw new RuntimeException( e );\n    }\n  }\n\n  /**\n   * Creates a new data item in the current location. This method must never return null. This method will fail if an\n   * entity with the same name exists in this location.\n   *","sourceCodeStart":106,"sourceCodeEnd":142,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/plugins/pentaho-reporting/impl/src/main/java/org/pentaho/di/trans/steps/pentahoreporting/urlrepository/FileObjectContentLocation.java#L106-L142","documentation":"FileObjectContentLocation.getEntry(name) resolves the child FileObject for the given name and throws ContentIOException(\"Not found:\" + child) when the resolved child does not exist in the repository. Reading a report entry from the URL repository requires the entry to already exist; lookups are not lazy.","triggerScenarios":"Calling getEntry with a name that resolves (via backend.resolveFile(name)) to a non-existent child — name mismatch, wrong case, or the entry was never written.","commonSituations":"Requesting a report file that was never generated or was deleted; case-sensitivity mismatch on Linux filesystems; using an invalid name (also flagged by the preceding IllegalArgumentException for invalid names); stale cached references after the file was removed.","solutions":["List the location's content entities (getContentNames/getChildren) and use an exact existing name","Check filename case and extension — resolution is case-sensitive on most filesystems","Generate/write the entry before reading it (execute the export task first)","Guard the call: check file.resolveFile(name).exists() before getEntry"],"exampleFix":"// before\nContentEntity entity = location.getEntry( \"report.PDF\" );\n// after\nString name = \"report.pdf\";\nif ( !location.hasContentEntity( name ) ) {\n  throw new ContentIOException( \"Entry missing: \" + name );\n}\nContentEntity entity = location.getEntry( name );","handlingStrategy":"validation","validationCode":"String name = \"report.pdf\";\nif ( location.hasContentEntity( name ) == false ) {\n  throw new ContentIOException( \"Entry not present: \" + name );\n}","typeGuard":null,"tryCatchPattern":"try {\n  ContentEntity entity = location.getEntry( name );\n} catch ( ContentIOException e ) {\n  logError( \"Missing repository entry '\" + name + \"' in \"\n    + location.getBackend().getName().getURI(), e );\n}","preventionTips":["Verify entry names via getChildren/getContentNames before lookup","Respect filesystem case sensitivity when naming entries","Ensure the export task completed and wrote the entry before reading","Guard against external cleanup jobs deleting generated reports"],"tags":["vfs","reporting","resource-not-found"],"backgroundTag":"resource-not-found","analyzedSha":"f3058517a153da500bf4551f46d79b91bf8ec552","analyzedAt":"2026-09-13T14:04:16.340Z","contentChangedAt":"2026-09-13T14:04:16.340Z","schemaVersion":2},"datasetVersion":"2026-09-20T23:17:15.980Z"}