pentaho/pentaho-kettle · error · SAXException

Invalid Transformation Name

Error message

Invalid Transformation Name

What it means

validateTransformation also verifies that /transformation_configuration/transformation/info/name exists, is a single simple text node (DeferredTextImpl), and is well-formed; otherwise SAXException 'Invalid Transformation Name' is thrown. The transformation name inside the configuration export failed these structural checks.

Solutions

  1. Open the posted XML and ensure <info><name>plain-text</name></info> exists with exactly one text child.
  2. Fix the generator producing the export so name is a simple text node (no CDATA, no nested tags).
  3. Re-export the transformation from the same/compatible Pentaho version rather than hand-editing.
  4. Trim whitespace/control characters from the name if the exporter emitted them.

Example fix

// before
<info><name></name></info>
// after
<info><name>My Transformation</name></info>
Defensive patterns

Strategy: validation

Validate before calling

import javax.xml.xpath.*;
import org.w3c.dom.*;
boolean hasSimpleTransName(Document doc) throws Exception {
  XPath xp = XPathFactory.newInstance().newXPath();
  Node n = (Node) xp.evaluate("/transformation_configuration/transformation/info/name", doc, XPathConstants.NODE);
  return n != null && n.getChildNodes().getLength() == 1 && n.getFirstChild() instanceof org.apache.xerces.dom.DeferredTextImpl;
}

Prevention

When it happens

Trigger: POST /kettle/registerTrans/ where the name node is missing, contains multiple child nodes (nested/mixed content), or is not a plain text node — e.g. CDATA, embedded elements, or an empty/absent <name> in the export.

Common situations: Hand-edited or third-party-generated configuration XML with an empty <name/> or wrapped elements; exports produced by different Pentaho versions with differing name node structure; XML built programmatically with attributes/children inside name.

Understand the failure class

Background: Schema validation failed / invalid input schema: payload rejected because its shape doesn't match the expected schema — this error's family across 28 libraries.

Related errors


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

Appendix: source

Thrown at engine/src/main/java/org/pentaho/di/www/RegisterTransServlet.java:87

      response.setStatus( HttpServletResponse.SC_INTERNAL_SERVER_ERROR );
      return new WebResult( WebResult.STRING_ERROR, ex.getMessage(), "" );
    }
  }

  public void validateTransformation( InputStream is ) throws IOException, ParserConfigurationException, SAXException,
    XPathExpressionException {
    DocumentBuilderFactory df = DocumentBuilderFactory.newInstance();
    df.setFeature( "http://xml.org/sax/features/external-general-entities", false );
    df.setFeature( "http://xml.org/sax/features/external-parameter-entities", false );
    DocumentBuilder builder = df.newDocumentBuilder();
    Document doc = builder.parse( is );
    if ( !doc.getDocumentElement().getNodeName().equals( "transformation_configuration" ) ) {
      throw new SAXException( "Invalid Transformation - Missing transformation_configuration tag" );
    }
    XPath xPath = XPathFactory.newInstance().newXPath();
    Node node = (Node) xPath.evaluate( "/transformation_configuration/transformation/info/name", doc, XPathConstants.NODE );
    if ( node == null  || node.getChildNodes().getLength() > 1 || !( node.getFirstChild() instanceof DeferredTextImpl ) ) {
      throw new SAXException( "Invalid Transformation Name" );
    }
  }

}

View on GitHub (pinned to f3058517a1)