pentaho/pentaho-kettle · error · RuntimeException
Unable to determine SOAP use for operation: + operationName
Error message
Unable to determine SOAP use for operation: + operationName
What it means
In getSOAPBindingUse, after finding the BindingOperation, the code looks for a <soap:body> extensibility element on the input (and output) to read the use attribute. If neither carries a recognizable SOAPBody element, it cannot determine the use and throws RuntimeException 'Unable to determine SOAP use for operation: <name>'. The operation exists but its SOAP body configuration is missing or nonstandard.
Solutions
- Add <soap:body use="literal"/> (or encoded) to the operation's <input> (and <output>) in the binding of the WSDL.
- Regenerate the WSDL from the service tooling so the soap:body element is emitted for every operation.
- Ensure the correct SOAP namespace/extension registry is used so soap:body is parsed into SOAPBody (SOAP 1.2 needs SOAP12Body handling).
- As a workaround, inspect the raw WSDL to know the use and configure the step accordingly if the parser can be avoided.
Example fix
<!-- before: input without soap:body -->
<operation name="GetPrice">
<input><soap:header message="tns:hdr" part="auth" use="literal"/></input>
<!-- after -->
<operation name="GetPrice">
<input>
<soap:body use="literal"/>
</input> Defensive patterns
Strategy: validation
Validate before calling
// Ensure the operation's input/output declare a soap:body before resolving use
BindingOperation op = binding.getBindingOperation(operationName, null, null);
boolean hasSoapBody = op != null && op.getBindingInput() != null
&& WsdlUtils.findExtensibilityElements(op.getBindingInput(), "body").stream()
.anyMatch(x -> x instanceof SOAPBody || x instanceof javax.wsdl.extensions.soap12.SOAP12Body);
if (!hasSoapBody) throw new IllegalArgumentException("Operation '" + operationName + "' has no soap:body use configured"); Try / catch
try {
String use = WsdlUtils.getSOAPBindingUse(binding, opName);
} catch (RuntimeException re) {
if (re.getMessage() != null && re.getMessage().startsWith("Unable to determine SOAP use")) {
logError("Operation '" + opName + "' lacks a soap:body element in its binding", re);
}
throw re;
} Prevention
- Require <soap:body use="..."/> on every binding operation input
- Regenerate WSDLs with full soap:body configuration
- Register SOAP 1.2 extension factories when applicable
When it happens
Trigger: The binding operation has no <soap:body> extensibility element on its input/output, or the element was not deserialized as a SOAPBody instance (e.g., different SOAP version/namespace extension).
Common situations: Hand-edited or tool-generated WSDL omitting <soap:body use="..."/>; SOAP 1.2 operation sections using a namespace whose extension factory isn't registered; minimal WSDLs that leave off body configuration.
Related errors
- Binding type + soapBindingElem + encountered. The Web…
- Port name: ' + portName + ' was not found in the WSDL file.
- Can not find operation: + operationName
- ERROR0006
- ERROR0007
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/3e40224cfc7800c1.
Report an issue: GitHub.
Appendix: source
Thrown at engine/src/main/java/org/pentaho/di/trans/steps/webservices/wsdl/WsdlUtils.java:162
}
}
}
// if there was no input message try getting the use from the output message
BindingOutput bindingOutput = bindingOperation.getBindingOutput();
if ( bindingOutput != null ) {
ExtensibilityElement soapBodyElem =
WsdlUtils.findExtensibilityElement( bindingOutput, SOAP_BODY_ELEMENT_NAME );
if ( soapBodyElem != null ) {
if ( soapBodyElem instanceof SOAP12BodyImpl ) {
return ( (SOAP12BodyImpl) soapBodyElem ).getUse();
} else {
return ( (SOAPBody) soapBodyElem ).getUse();
}
}
}
throw new RuntimeException( "Unable to determine SOAP use for operation: " + operationName );
}
/**
* Get the Soap Action URI from the operation's soap:operation extensiblity element.
*
* @param operation
* A WSDL Operation.
* @return Soap action URI as string, null if not defined.
*/
protected static String getSOAPAction( BindingOperation operation ) {
ExtensibilityElement e = findExtensibilityElement( operation, SOAP_OPERATION_ELEMENT_NAME );
if ( e != null ) {
if ( e instanceof SOAP12Operation ) {
return ( (SOAP12Operation) e ).getSoapActionURI();
} else {
return ( (SOAPOperation) e ).getSoapActionURI();
}
}View on GitHub (pinned to f3058517a1)