{"record":{"id":"0367b99fd59413ea","repo":"pentaho/pentaho-kettle","slug":"jobpgpdecryptfiles-error-exception-unableloadrep","errorCode":null,"errorMessage":"JobPGPDecryptFiles.Error.Exception.UnableLoadRep","messagePattern":"JobPGPDecryptFiles\\.Error\\.Exception\\.UnableLoadRep","errorType":"exception","errorClass":"KettleException","httpStatus":null,"severity":"error","filePath":"engine/src/main/java/org/pentaho/di/job/entries/pgpdecryptfiles/JobEntryPGPDecryptFiles.java","lineNumber":311,"sourceCode":"      add_moved_time = rep.getJobEntryAttributeBoolean( id_jobentry, \"add_moved_time\" );\n      SpecifyMoveFormat = rep.getJobEntryAttributeBoolean( id_jobentry, \"SpecifyMoveFormat\" );\n\n      // How many arguments?\n      int argnr = rep.countNrJobEntryAttributes( id_jobentry, \"source_filefolder\" );\n      allocate( argnr );\n\n      // Read them all...\n      for ( int a = 0; a < argnr; a++ ) {\n        source_filefolder[a] = rep.getJobEntryAttributeString( id_jobentry, a, \"source_filefolder\" );\n        passphrase[a] =\n          Encr\n            .decryptPasswordOptionallyEncrypted( rep.getJobEntryAttributeString( id_jobentry, a, \"passphrase\" ) );\n        destination_filefolder[a] = rep.getJobEntryAttributeString( id_jobentry, a, \"destination_filefolder\" );\n        wildcard[a] = rep.getJobEntryAttributeString( id_jobentry, a, \"wildcard\" );\n      }\n    } catch ( KettleException dbe ) {\n\n      throw new KettleException( BaseMessages.getString( PKG, \"JobPGPDecryptFiles.Error.Exception.UnableLoadRep\" )\n        + id_jobentry, dbe );\n    }\n  }\n\n  public void saveRep( Repository rep, IMetaStore metaStore, ObjectId id_job ) throws KettleException {\n    try {\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"gpglocation\", gpglocation );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"arg_from_previous\", arg_from_previous );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"include_subfolders\", include_subfolders );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"add_result_filesname\", add_result_filesname );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"destination_is_a_file\", destination_is_a_file );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"create_destination_folder\", create_destination_folder );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"nr_errors_less_than\", nr_errors_less_than );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"success_condition\", success_condition );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"add_date\", add_date );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"add_time\", add_time );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"SpecifyFormat\", SpecifyFormat );\n      rep.saveJobEntryAttribute( id_job, getObjectId(), \"date_time_format\", date_time_format );","sourceCodeStart":293,"sourceCodeEnd":329,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/engine/src/main/java/org/pentaho/di/job/entries/pgpdecryptfiles/JobEntryPGPDecryptFiles.java#L293-L329","documentation":"Thrown by JobEntryPGPDecryptFiles.loadRep when loading the job entry's settings from the Kettle repository fails with a KettleException (KettleDatabaseException base). It wraps the cause and appends the id_jobentry, indicating the PGP decrypt entry could not be read from the repository.","triggerScenarios":"rep.getJobEntryAttributeString(id_jobentry, nr, \"passphrase\"/\"destination_filefolder\"/\"wildcard\") throws because the repository database is unreachable, the entry rows are missing, or the repository schema is broken.","commonSituations":"Repository DB connection failure while opening a job; entry saved by an incompatible plugin version so expected attribute rows don't exist; corrupted R_JOBENTRY_ATTRIBUTE rows; insufficient DB privileges.","solutions":["Verify repository database connectivity and credentials.","Check R_JOBENTRY_ATTRIBUTE rows exist for this id_jobentry; re-save the entry from Spoon if missing.","Run repository repair/upgrade scripts for your Pentaho version.","Inspect the wrapped cause for the specific SQL error."],"exampleFix":"// before\n// (no fallback on load)\n// after: default values when attributes are absent\nString pass = rep.getJobEntryAttributeString( id_jobentry, \"passphrase\" );\nif ( pass == null ) {\n  logBasic( \"passphrase attribute missing for entry \" + id_jobentry + \"; using default\" );\n  pass = \"\";\n}","handlingStrategy":"try-catch","validationCode":"// check repository connectivity before loading jobs\nif ( !rep.getConnection().isAutoCommit() ) { /* connectivity test */ }\nrep.getJobEntryAttributeString( id_jobentry, \"name\" ); // probe read","typeGuard":null,"tryCatchPattern":"try {\n  jobEntry.loadRep( rep, metaStore, id_jobentry, databases, slaveServers );\n} catch ( KettleException e ) {\n  logError( \"Cannot load PGP entry from repository (id=\" + id_jobentry + \"): \" + e.getCause(), e );\n  // fall back to defaults or abort job setup\n}","preventionTips":["Check repository DB health before opening jobs.","Re-save entries after Pentaho upgrades.","Verify R_JOBENTRY_ATTRIBUTE rows for critical entries.","Grant sufficient DB read privileges to the repository user."],"tags":["database","repository","persistence","pgp"],"backgroundTag":"database-query-failed","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"}