pentaho/pentaho-kettle · error · KettleException

There was an error posting the job on the remote server:

Error message

There was an error posting the job on the remote server: 

What it means

For non-exported (in-place XML) remote execution, sendToSlaveServer() serializes the JobConfiguration to XML and POSTs it to RegisterJobServlet. If the returned WebResult is not OK, the library throws a KettleException with this message plus the server's message: the Carte server failed to register/post the job.

Solutions

  1. Inspect webResult.getMessage() appended to the exception for the server-side root cause.
  2. Align Pentaho/Carte versions between client and remote server.
  3. Install any missing plugins/steps/job entries referenced by the job on the Carte server.
  4. Check Carte logs (catalina/carte log) at the time of the request for the real stack trace.
  5. Verify SlaveServer host/port/credentials and that RegisterJobServlet is reachable.

Example fix

// before: server lacks the plugin used by the job
String reply = slaveServer.sendXML(xml, RegisterJobServlet.CONTEXT_PATH + "/?xml=Y"); // non-OK
// after: pre-check plugin availability
if (!remoteHasPlugin(slaveServer, "my-custom-job-entry")) {
  throw new IllegalStateException("Install missing plugin on Carte first");
}
Defensive patterns

Strategy: try-catch

Validate before calling

if (!slaveServer.ping()) {
  throw new IllegalStateException("Carte unreachable before job registration");
}

Try / catch

try {
  return Job.sendToSlaveServer(jobMeta, execCfg, repo, metaStore);
} catch (KettleException e) {
  if (e.getMessage().contains("posting the job")) {
    log.error("Carte rejected job registration: {}", e.getMessage());
  }
  throw e;
}

Prevention

When it happens

Trigger: Calling sendToSlaveServer without resource export where slaveServer.sendXML(...) to RegisterJobServlet returns non-OK (server failed to parse/accept the JobConfiguration XML, authentication rejected, servlet missing).

Common situations: Carte version mismatch so the XML tag set is not understood; job XML references plugins not installed on the server; wrong Carte port/URL; Carte node busy or out of memory.

Understand the failure class

Background: "API error: {status}" and "HTTP 401/403/404/429/5xx" errors: non-2xx HTTP responses explained — this error's family across 27 libraries.

Related errors


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

Appendix: source

Thrown at engine/src/main/java/org/pentaho/di/job/Job.java:1770

          // Send the zip file over to the slave server...
          String result =
              slaveServer.sendExport( topLevelResource.getArchiveName(), RegisterPackageServlet.TYPE_JOB, topLevelResource
                  .getBaseResourceName() );
          WebResult webResult = WebResult.fromXMLString( result );
          if ( !webResult.getResult().equalsIgnoreCase( WebResult.STRING_OK ) ) {
            throw new KettleException( "There was an error passing the exported job to the remote server: " + Const.CR
                + webResult.getMessage() );
          }
          carteObjectId = webResult.getId();
        }
      } else {
        String xml = new JobConfiguration( jobMeta, executionConfiguration ).getXML();

        String reply = slaveServer.sendXML( xml, RegisterJobServlet.CONTEXT_PATH + "/?xml=Y" );
        WebResult webResult = WebResult.fromXMLString( reply );
        if ( !webResult.getResult().equalsIgnoreCase( WebResult.STRING_OK ) ) {
          throw new KettleException( "There was an error posting the job on the remote server: " + Const.CR + webResult
              .getMessage() );
        }
        carteObjectId = webResult.getId();
      }

      // Start the job
      //
      String reply =
          slaveServer.execService( StartJobServlet.CONTEXT_PATH + "/?name=" + URLEncoder.encode( jobMeta.getName(),
              "UTF-8" ) + "&xml=Y&id=" + carteObjectId );
      WebResult webResult = WebResult.fromXMLString( reply );
      if ( !webResult.getResult().equalsIgnoreCase( WebResult.STRING_OK ) ) {
        throw new KettleException( "There was an error starting the job on the remote server: " + Const.CR + webResult
            .getMessage() );
      }
      return carteObjectId;
    } catch ( KettleException ke ) {
      throw ke;

View on GitHub (pinned to f3058517a1)