pentaho/pentaho-kettle · error · KettleException

XBaseInputMeta.Exception.UnexpectedErrorReadingMetaDataFromR…

Error message

XBaseInputMeta.Exception.UnexpectedErrorReadingMetaDataFromRepository

What it means

Thrown by XBaseInputMeta.readRep() when loading step attributes from the Pentaho Repository fails. Any exception while reading the step's stored attributes (row number, filename, wildcard, accept settings) is wrapped in a KettleException with this localized message. It signals a repository access problem or corrupt stored step metadata.

Solutions

  1. Verify repository connectivity (database repository up, or file repository accessible) and retry opening the transformation.
  2. Check the chained cause for the exact repository error (SQL error, connection refused).
  3. Re-save the step from Spoon to repopulate missing attributes.
  4. Inspect R_STEP_ATTRIBUTE rows for the step's id_step if using a database repository.
  5. Restore the transformation from a repository backup if attributes are lost.

Example fix

// before: opening transformation from an unreachable repository
TransMeta tm = new TransMeta( repository, "path/to/trans" );

// after: verify repository connection first
if ( !repository.isConnected() ) {
  repository.connect( username, password );
}
TransMeta tm = new TransMeta( repository, "path/to/trans" );
Defensive patterns

Strategy: try-catch

Validate before calling

if ( repository == null || !repository.isConnected() ) {
  throw new KettleException( "Repository is not connected; cannot read step metadata" );
}

Try / catch

try {
  TransMeta tm = new TransMeta( repository, path, monitor );
} catch ( KettleException e ) {
  logError( "Repository read failed: " + e.getCause(), e );
  // check repository connectivity and attribute rows, then retry
}

Prevention

When it happens

Trigger: Loading an XBase Input step definition from a repository via readRep(); Repository.getStepAttributeBoolean/String calls throw, or the id_step points to missing/incomplete attributes, and the exception is wrapped with this message.

Common situations: Repository database connectivity issues, step rows missing in R_STEP_ATTRIBUTE due to interrupted saves or manual deletion, repository version mismatch, permissions on repository tables.

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/3e2d9dcaff349a30. Report an issue: GitHub.

Appendix: source

Thrown at engine/src/main/java/org/pentaho/di/trans/steps/xbaseinput/XBaseInputMeta.java:395

  @Override
  public void readRep( Repository rep, IMetaStore metaStore, ObjectId id_step, List<DatabaseMeta> databases ) throws KettleException {
    try {
      dbfFileName = rep.getStepAttributeString( id_step, "file_dbf" );
      rowLimit = (int) rep.getStepAttributeInteger( id_step, "limit" );
      rowNrAdded = rep.getStepAttributeBoolean( id_step, "add_rownr" );
      rowNrField = rep.getStepAttributeString( id_step, "field_rownr" );

      includeFilename = rep.getStepAttributeBoolean( id_step, "include" );
      filenameField = rep.getStepAttributeString( id_step, "include_field" );
      charactersetName = rep.getStepAttributeString( id_step, "charset_name" );

      acceptingFilenames = rep.getStepAttributeBoolean( id_step, "accept_filenames" );
      acceptingField = rep.getStepAttributeString( id_step, "accept_field" );
      acceptingStepName = rep.getStepAttributeString( id_step, "accept_stepname" );

    } catch ( Exception e ) {
      throw new KettleException( BaseMessages.getString(
        PKG, "XBaseInputMeta.Exception.UnexpectedErrorReadingMetaDataFromRepository" ), e );
    }
  }

  @Override
  public void saveRep( Repository rep, IMetaStore metaStore, ObjectId id_transformation, ObjectId id_step ) throws KettleException {
    try {
      rep.saveStepAttribute( id_transformation, id_step, "file_dbf", dbfFileName );
      rep.saveStepAttribute( id_transformation, id_step, "limit", rowLimit );
      rep.saveStepAttribute( id_transformation, id_step, "add_rownr", rowNrAdded );
      rep.saveStepAttribute( id_transformation, id_step, "field_rownr", rowNrField );

      rep.saveStepAttribute( id_transformation, id_step, "include", includeFilename );
      rep.saveStepAttribute( id_transformation, id_step, "include_field", filenameField );
      rep.saveStepAttribute( id_transformation, id_step, "charset_name", charactersetName );

      rep.saveStepAttribute( id_transformation, id_step, "accept_filenames", acceptingFilenames );
      rep.saveStepAttribute( id_transformation, id_step, "accept_field", acceptingField );

View on GitHub (pinned to f3058517a1)