pentaho/pentaho-kettle · error · KettleException

error reading step with id_step=

Error message

error reading step with id_step=<id_step> from the repository

What it means

DummyPluginMeta.readRep rehydrates the step's value (name, type, text, length, precision) from repository step attributes. Any KettleDatabaseException thrown while querying those attributes (rep.getStepAttributeString/Boolean/Integer) is wrapped in a KettleException with this message, carrying id_step for traceability. The database cause is chained.

Solutions

  1. Check the chained KettleDatabaseException for the JDBC error code/message (connection refused, table missing, lock timeout).
  2. Verify repository database connectivity (ping, test the DB connection in PDI's repository login).
  3. Re-open the transformation after connectivity is restored; the step data itself is usually fine.
  4. If persistent, repair/check the repository schema (repository upgrade script) for the step-attribute tables.
Defensive patterns

Strategy: retry

Validate before calling

// verify repository connectivity before loading
if ( !rep.isConnected() ) {
  rep.connect( "user", "pass" );
}
rep.getStepAttributeString( id_step, 0, "value_name" ); // probe read

Try / catch

try {
  meta.readRep( rep, id_step, databases, counters );
} catch ( KettleException e ) {
  if ( e.getCause() instanceof KettleDatabaseException ) {
    // transient DB issue: reconnect and retry
    rep.disconnect();
    rep.connect( user, pass );
    meta.readRep( rep, id_step, databases, counters );
  } else {
    throw e;
  }
}

Prevention

When it happens

Trigger: readRep(rep, id_step, ...) when the underlying repository connection fails mid-query, the R_ step-attribute table is locked/unavailable, or the repository schema is corrupted so getStepAttributeString/Integer/Boolean throws KettleDatabaseException.

Common situations: Repository DB (e.g. Postgres/MySQL/Oracle) down or restarted mid-load; network outage between PDI and repository DB; stale connection pool after DB failover; repository schema upgrade mismatch.

Understand the failure class

Background: Database query failed: Internal Server Error 500s wrapping SQL, Prisma, and connection failures — what to check first — this error's family across 16 libraries.

Related errors


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

Appendix: source

Thrown at plugins/dummy/core/src/main/java/org/pentaho/di/be/ibridge/kettle/dummy/DummyPluginMeta.java:161

      int length = (int) rep.getStepAttributeInteger( id_step, 0, "value_length" );
      int precision = (int) rep.getStepAttributeInteger( id_step, 0, "value_precision" );

      int type = ValueMetaFactory.getIdForValueMeta( typedesc );
      value = new ValueMetaAndData( new ValueMeta( name, type ), null );
      value.getValueMeta().setLength( length );
      value.getValueMeta().setPrecision( precision );

      if ( isnull ) {
        value.setValueData( null );
      } else {
        ValueMetaInterface stringMeta = new ValueMetaString( name );
        if ( type != ValueMetaInterface.TYPE_STRING ) {
          text = Const.trim( text );
        }
        value.setValueData( value.getValueMeta().convertData( stringMeta, text ) );
      }
    } catch ( KettleDatabaseException dbe ) {
      throw new KettleException( "error reading step with id_step=" + id_step + " from the repository", dbe );
    } catch ( Exception e ) {
      throw new KettleException( "Unexpected error reading step with id_step=" + id_step + " from the repository", e );
    }
  }

  @Override
  public void saveRep( Repository rep, ObjectId id_transformation, ObjectId id_step ) throws KettleException {
    try {
      rep.saveStepAttribute( id_transformation, id_step, "value_name", value.getValueMeta().getName() );
      rep.saveStepAttribute( id_transformation, id_step, 0, "value_type", value.getValueMeta().getTypeDesc() );
      rep.saveStepAttribute( id_transformation, id_step, 0, "value_text", value.getValueMeta().getString( value.getValueData() ) );
      rep.saveStepAttribute( id_transformation, id_step, 0, "value_null", value.getValueMeta().isNull( value.getValueData() ) );
      rep.saveStepAttribute( id_transformation, id_step, 0, "value_length", value.getValueMeta().getLength() );
      rep.saveStepAttribute( id_transformation, id_step, 0, "value_precision", value.getValueMeta().getPrecision() );
    } catch ( KettleDatabaseException dbe ) {
      throw new KettleException( "Unable to save step information to the repository, id_step=" + id_step, dbe );
    }
  }

View on GitHub (pinned to f3058517a1)