{"record":{"id":"bb465bc3f170c870","repo":"pentaho/pentaho-kettle","slug":"abortmeta-exception-unabletosavestepinfotorepository","errorCode":null,"errorMessage":"AbortMeta.Exception.UnableToSaveStepInfoToRepository","messagePattern":"AbortMeta\\.Exception\\.UnableToSaveStepInfoToRepository","errorType":"exception","errorClass":"KettleException","httpStatus":null,"severity":"error","filePath":"plugins/core/impl/src/main/java/org/pentaho/di/trans/steps/abort/AbortMeta.java","lineNumber":176,"sourceCode":"        // Backward compatibility\n        // existing transformations will have to maintain backward compatibility with yes\n        boolean abortWithError = rep.getStepAttributeBoolean( id_step, 0, \"abort_with_error\", true );\n        abortOption = abortWithError ? AbortOption.ABORT_WITH_ERROR : AbortOption.ABORT;\n      }\n    } catch ( Exception e ) {\n      throw new KettleException( BaseMessages.getString(\n        PKG, \"AbortMeta.Exception.UnexpectedErrorInReadingStepInfoFromRepository\" ), e );\n    }\n  }\n\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, \"row_threshold\", rowThreshold );\n      rep.saveStepAttribute( id_transformation, id_step, \"message\", message );\n      rep.saveStepAttribute( id_transformation, id_step, \"always_log_rows\", alwaysLogRows );\n      rep.saveStepAttribute( id_transformation, id_step, \"abort_option\", abortOption.toString() );\n    } catch ( Exception e ) {\n      throw new KettleException( BaseMessages.getString(\n        PKG, \"AbortMeta.Exception.UnableToSaveStepInfoToRepository\" )\n        + id_step, e );\n    }\n  }\n\n  public String getMessage() {\n    return message;\n  }\n\n  public void setMessage( String message ) {\n    this.message = message;\n  }\n\n  public String getRowThreshold() {\n    return rowThreshold;\n  }\n\n  public void setRowThreshold( String rowThreshold ) {","sourceCodeStart":158,"sourceCodeEnd":194,"githubUrl":"https://github.com/pentaho/pentaho-kettle/blob/f3058517a153da500bf4551f46d79b91bf8ec552/plugins/core/impl/src/main/java/org/pentaho/di/trans/steps/abort/AbortMeta.java#L158-L194","documentation":"AbortMeta.saveRep throws KettleException with this message when saving the Abort step's attributes (row_threshold, message, always_log_rows, abort_option) to the repository fails. The id_step is appended to the message for locating the failing record.","triggerScenarios":"rep.saveStepAttribute throwing on DB failure: connection loss, constraint violation, null abortOption (toString on null), or insufficient write privileges.","commonSituations":"Repository offline during save, abortOption field never initialized (null NPE wrapped as this error), DB out of space, concurrent edits locking rows.","solutions":["Check the wrapped cause for the SQL error and repair repository connectivity/privileges.","Ensure abortOption is non-null before saveRep (initialize to a default in the step's default constructor).","Verify DB disk space and that the repository user can write to R_STEP_ATTRIBUTE.","Retry the save once the repository is healthy."],"exampleFix":"// before\nrep.saveStepAttribute( id_transformation, id_step, \"abort_option\", abortOption.toString() );\n// after\nrep.saveStepAttribute( id_transformation, id_step, \"abort_option\",\n  abortOption != null ? abortOption.toString() : AbortOption.ABORT.toString() );","handlingStrategy":"validation","validationCode":"// ensure abortOption is initialized before saving\nif ( meta.getAbortOption() == null ) { meta.setAbortOption( AbortOption.ABORT ); }","typeGuard":null,"tryCatchPattern":"try { meta.saveRep( rep, metaStore, id_transformation, id_step ); } catch ( KettleException e ) { logError( \"saveRep failed for step \" + id_step + \": \" + e.getMessage(), e ); }","preventionTips":["Always construct AbortMeta with a non-null abortOption.","Ensure repository DB has free space and the user has write grants.","Serialize saves of the same transformation to avoid lock contention."],"tags":["repository","database","write-failed","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"}