{"record":{"id":"431b49f717a8ab5c","repo":"pentaho/pentaho-kettle","slug":"symmetriccryptotransmeta-exception-unabletosavestepinfo","errorCode":"SymmetricCryptoTransMeta.Exception.UnableToSaveStepInfo","errorMessage":"SymmetricCryptoTransMeta.Exception.UnableToSaveStepInfo + id_step","messagePattern":"SymmetricCryptoTransMeta\\.Exception\\.UnableToSaveStepInfo \\+ id_step","errorType":"exception","errorClass":"KettleException","httpStatus":null,"severity":"error","filePath":"engine/src/main/java/org/pentaho/di/trans/steps/symmetriccrypto/symmetriccryptotrans/SymmetricCryptoTransMeta.java","lineNumber":372,"sourceCode":"\n  public void saveRep( Repository rep, IMetaStore metaStore, ObjectId id_transformation, ObjectId id_step ) throws KettleException {\n    try {\n      rep.saveStepAttribute( id_transformation, id_step, \"operation_type\", getOperationTypeCode( operationType ) );\n      rep.saveStepAttribute( id_transformation, id_step, \"algorithm\", algorithm );\n      rep.saveStepAttribute( id_transformation, id_step, \"schema\", schema );\n\n      rep.saveStepAttribute( id_transformation, id_step, \"secretKeyField\", secretKeyField );\n      rep.saveStepAttribute( id_transformation, id_step, \"messageField\", messageField );\n      rep.saveStepAttribute( id_transformation, id_step, \"resultfieldname\", resultfieldname );\n\n      rep.saveStepAttribute( id_transformation, id_step, \"secretKey\", Encr\n        .encryptPasswordIfNotUsingVariables( secretKey ) );\n      rep.saveStepAttribute( id_transformation, id_step, \"secretKeyInField\", secretKeyInField );\n      rep.saveStepAttribute( id_transformation, id_step, \"readKeyAsBinary\", readKeyAsBinary );\n      rep.saveStepAttribute( id_transformation, id_step, \"outputResultAsBinary\", outputResultAsBinary );\n\n    } catch ( Exception e ) {\n      throw new KettleException( BaseMessages.getString(\n        PKG, \"SymmetricCryptoTransMeta.Exception.UnableToSaveStepInfo\" )\n        + id_step, e );\n    }\n  }\n\n  public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepinfo,\n    RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space,\n    Repository repository, IMetaStore metaStore ) {\n\n    CheckResult cr;\n\n    if ( prev != null && prev.size() > 0 ) {\n      cr =\n        new CheckResult(\n          CheckResult.TYPE_RESULT_OK, BaseMessages.getString(\n            PKG, \"SymmetricCryptoTransMeta.CheckResult.ConnectedStepOK\", String.valueOf( prev.size() ) ),\n          stepinfo );\n    } else {","sourceCodeStart":354,"sourceCodeEnd":390,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/engine/src/main/java/org/pentaho/di/trans/steps/symmetriccrypto/symmetriccryptotrans/SymmetricCryptoTransMeta.java#L354-L390","documentation":"SymmetricCryptoTransMeta.saveRep() persists step settings via rep.saveStepAttribute(...) (secretKey encrypted, secretKeyInField, readKeyAsBinary, outputResultAsBinary). If any repository save call throws, it is wrapped in a KettleException with this message plus the id_step, indicating the step configuration could not be saved. The original cause is chained.","triggerScenarios":"Saving a transformation to a repository when the connection is down, the database is read-only or out of space, a transaction fails, or attribute values exceed column limits.","commonSituations":"Repository database read-only mode or quota exceeded; network drop during save; long secret key overflowing the attribute column; concurrent save conflicts; permission revoked mid-session.","solutions":["Check repository DB connectivity, permissions, and free space, then re-save the transformation.","Run as a user with write privileges on the repository tables.","Verify the secret key length fits the repository attribute column; shorten or use a variable reference instead.","Save to file (.ktr) as a fallback while repository issues are resolved."],"exampleFix":"// before\nrep.save(transMeta, \"MyTrans\", null, true); // fails on read-only DB\n// after\ntry {\n  rep.save(transMeta, \"MyTrans\", null, true);\n} catch (KettleException e) {\n  transMeta.setFilename(\"/tmp/MyTrans.ktr\"); // file fallback\n  transMeta.exportResources();\n}","handlingStrategy":"try-catch","validationCode":"// Pre-check write access before saveRep runs\nif (!rep.testConnection() || rep.isReadOnly()) {\n  throw new IllegalStateException(\"Repository not writable\");\n}","typeGuard":null,"tryCatchPattern":"try {\n  rep.save(transMeta, \"MyTrans\", null, true);\n} catch (KettleException e) {\n  logError(\"Failed saving step info for id_step: \" + e.getCause(), e);\n  // fallback: save to file\n  transMeta.setFilename(\"/tmp/MyTrans.ktr\");\n}","preventionTips":["Ensure the DB user has INSERT/UPDATE rights on repository tables.","Monitor repository DB disk space and read-only states.","Keep long secret keys in variables rather than attribute columns."],"tags":["kettle","pdi","repository","persistence"],"backgroundTag":"database-write-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"}