pentaho/pentaho-kettle · error · KettleException
Log string is too long
Error message
Log string is too long
What it means
getLogText in GetTransStatusServlet stringifies the transformation's log buffer; an OutOfMemoryError during that conversion is rethrown as a KettleException 'Log string is too long'. It means the log text is too big to fit in memory as a String.
Solutions
- Increase JVM heap.
- Bound the log range requested (startLineNr/lastLineNr) or use tail-based log retrieval.
- Set KettleLogStore.getAppender().setMaxNumberOfLines(...) / KETTLE_LOG_BUFFER_SIZE env to cap buffer size.
- Lower the transformation's log level.
Example fix
// before appender.setMaxNumberOfLines(0); // unlimited // after appender.setMaxNumberOfLines(10000); // cap buffer, stringification stays within heap
Defensive patterns
Strategy: validation
Validate before calling
int last = KettleLogStore.getLastBufferLineNr(); boolean safeToFetch = (last - startLineNr) < 100_000; // bounded line window
Prevention
- Cap KettleLogStore.getAppender().setMaxNumberOfLines(...) on the server.
- Fetch tail windows only; never stringify the entire buffer.
- Increase -Xmx relative to worst-case log volume.
- Use Rowlevel logging sparingly on production transformations.
When it happens
Trigger: GET /kettle/transStatus/ (any mode calling logText) where KettleLogStore buffer for the trans channel exceeds available heap when converted with toString().
Common situations: High-volume transformations with row-count-per-line logging; long-running trans polled repeatedly; undersized -Xmx on Carte; KettleLogStore max-lines setting too high or unlimited.
Understand the failure class
Background: payload too large / request exceeds maximum size: why libraries cap bytes and how to fix oversize payloads — this error's family across 50 libraries.
Related errors
- GetJobStatusServlet.Error.LogStringIsTooLong
- Error executing Transformation: " + logging
- ExecuteTransServlet.Error.ErrorExecutingTrans
- Trans.Exception.ConnectionCouldNotBeFound
- Trans.Exception.ErrorCalculatingDateRange
AI-assisted analysis of pentaho/pentaho-kettle@f3058517a1 (2026-09-13).
Data as JSON: /api/errors/53c8b32e5e56586d.
Report an issue: GitHub.
Appendix: source
Thrown at engine/src/main/java/org/pentaho/di/www/GetTransStatusServlet.java:533
public String toString() {
return "Trans Status Handler";
}
public String getService() {
return CONTEXT_PATH + " (" + toString() + ")";
}
public String getContextPath() {
return CONTEXT_PATH;
}
private String getLogText( Trans trans, int startLineNr, int lastLineNr ) throws KettleException {
try {
return KettleLogStore.getAppender().getBuffer(
trans.getLogChannel().getLogChannelId(), false, startLineNr, lastLineNr ).toString();
} catch ( OutOfMemoryError error ) {
throw new KettleException( "Log string is too long", error );
}
}
}
View on GitHub (pinned to f3058517a1)