pentaho/pentaho-kettle · error · KettleException

SalesforceUpdateMeta.Exception.ErrorSavingToRepository

Error message

SalesforceUpdateMeta.Exception.ErrorSavingToRepository

What it means

This KettleException wraps any failure while persisting the Salesforce Update step's configuration to the Pentaho repository in saveRep. Every rep.saveStepAttribute call is inside a try/catch; a failure (dead repository connection, read-only repository, constraint violation) is rethrown with this message including the id_step. The step's settings are then not saved.

Solutions

  1. Inspect the chained cause for the real database/repository error and address it (reconnect, free space, unlock).
  2. Re-save the transformation after confirming the repository connection is alive.
  3. If the repository is read-only, switch to a writable repository or export to a .ktr file instead.
  4. Retry the save once — transient connection drops are a common cause.

Example fix

// before
stepMeta.getStepMetaInterface().saveRep(repository, metaStore, transMeta.getObjectId(), stepMeta.getObjectId());
// after
try {
  stepMeta.getStepMetaInterface().saveRep(repository, metaStore, transMeta.getObjectId(), stepMeta.getObjectId());
} catch (KettleException e) {
  logError("Save failed, attempting repository reconnect");
  repository.connect();
  stepMeta.getStepMetaInterface().saveRep(repository, metaStore, transMeta.getObjectId(), stepMeta.getObjectId());
}
Defensive patterns

Strategy: try-catch

Validate before calling

if (!repository.isConnected()) repository.connect(); // verify before save

Try / catch

try { meta.saveRep(rep, metaStore, idTrans, idStep); } catch (KettleException e) { log.error("ErrorSavingToRepository for step " + idStep + ", cause: " + e.getCause(), e); throw e; }

Prevention

When it happens

Trigger: Calling saveRep (e.g. when the user clicks Save in Spoon) while the Repository saveStepAttribute calls throw — repository connection lost, repository read-only/quota exceeded, database constraint violation, id_transformation/id_step invalid.

Common situations: Saving a transformation when the database repository session has expired; repository DB out of disk space or locked by backups; sharing a transformation across repositories with incompatible schemas.

Related errors


AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13). Data as JSON: /api/errors/0dcfdd1a9cbdc86b. Report an issue: GitHub.

Appendix: source

Thrown at plugins/salesforce/core/src/main/java/org/pentaho/di/trans/steps/salesforceupdate/SalesforceUpdateMeta.java:285

        PKG, "SalesforceUpdateMeta.Exception.ErrorReadingRepository" ), e );
    }
  }

  public void saveRep( Repository rep, IMetaStore metaStore, ObjectId id_transformation, ObjectId id_step ) throws KettleException {
    super.saveRep( rep, metaStore, id_transformation, id_step );
    try {
      rep.saveStepAttribute( id_transformation, id_step, "batchSize", getBatchSize() );

      for ( int i = 0; i < updateLookup.length; i++ ) {
        rep.saveStepAttribute( id_transformation, id_step, i, "field_name", getUpdateLookup()[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "field_attribut", getUpdateStream()[i] );
        rep.saveStepAttribute( id_transformation, id_step, i, "field_useExternalId", getUseExternalId()[i]
          .booleanValue() );

      }
      rep.saveStepAttribute( id_transformation, id_step, "rollbackAllChangesOnError", isRollbackAllChangesOnError() );
    } catch ( Exception e ) {
      throw new KettleException( BaseMessages.getString(
        PKG, "SalesforceUpdateMeta.Exception.ErrorSavingToRepository", "" + id_step ), e );
    }
  }

  public void check( List<CheckResultInterface> remarks, TransMeta transMeta, StepMeta stepMeta,
    RowMetaInterface prev, String[] input, String[] output, RowMetaInterface info, VariableSpace space,
    Repository repository, IMetaStore metaStore ) {
    super.check( remarks, transMeta, stepMeta, prev, input, output, info, space, repository, metaStore );
    CheckResult cr;

    // See if we get input...
    if ( input != null && input.length > 0 ) {
      cr =
        new CheckResult( CheckResult.TYPE_RESULT_ERROR, BaseMessages.getString(
          PKG, "SalesforceUpdateMeta.CheckResult.NoInputExpected" ), stepMeta );
    } else {
      cr =
        new CheckResult( CheckResult.TYPE_RESULT_OK, BaseMessages.getString(

View on GitHub (pinned to f3058517a1)