OOXML Processing Limits
Configure process-wide resource limits for DOCX, PPTX, and XLSX processing.
OOXML Processing Limits
GoodMem applies bounded resource policies while extracting text from DOCX, PPTX, and XLSX files and while rendering XLSX worksheets as page images. Deployment operators can replace individual limits at server startup with one versioned JSON value.
This is a process-wide safety policy. It cannot be changed through an ingestion request or an administrative API, and changes take effect only after the server restarts.
Counters are fresh for each library operation. When GoodMem both extracts text and renders page images for one document, each pass receives the same configured ceilings; the two passes do not share one partially consumed budget.
Configuration Precedence
OOXML limits follow GoodMem's standard server configuration precedence:
--ooxml-limits-jsoncommand-line optionGOODMEM_OOXML_LIMITS_JSONenvironment variable- Compiled GoodMem defaults
A blank environment value is treated as unset. A blank command-line value is rejected. The JSON
must contain "version": 1; every other field is optional and inherits its compiled default when
omitted.
For an installer-managed deployment, put the JSON on one line in the installation profile's
.env file, then run goodmem system stop followed by goodmem system start for that profile:
GOODMEM_OOXML_LIMITS_JSON={"version":1,"extraction":{"outputCharacters":33554432}}goodmem system upgrade adds this setting to older installer-managed profiles. If it warns that
your custom Compose configuration needs manual changes, make sure the environment variable is
passed through to the server container.
The equivalent direct server invocation is:
java -jar goodmem-server.jar \
--ooxml-limits-json='{"version":1,"extraction":{"outputCharacters":33554432}}'For a multi-instance deployment, apply the identical resolved policy to every instance and use a rolling restart. During the rollout, instances that have not restarted still enforce the previous policy, so ingestion behavior can differ temporarily. Compare the startup log fingerprint across instances to confirm that they resolved the same policy.
Version 1 Fields and Defaults
All numeric values must be positive integers. Zero never means unlimited.
Text Extraction
| Field | Default | Meaning |
|---|---|---|
packageEntries | 10,000 | Unique OOXML archive entries admitted |
zipEntryVisits | 100,000 | ZIP entry headers visited by instrumented passes |
inflatedBytes | 268,435,456 | Uncompressed bytes read by instrumented package streams |
materializedBytes | 268,435,456 | Bytes copied into bounded or retained package buffers |
worksheetVisits | 2,048 | XLSX worksheet occurrences visited |
xmlEvents | 20,000,000 | Events consumed at instrumented XML parser sites |
structuralWorkSteps | 20,000,000 | Instrumented layout and structural traversal work |
structuralNestingDepth | 64 | Maximum instrumented XML hierarchy depth |
rowVisits | 2,000,000 | XLSX rows visited during text extraction |
cellSlotVisits | 10,000,000 | XLSX addressable cell slots visited |
semanticEvents | 500,000 | XLSX controls, comments, and similar structured events |
outputCharacters | 16,777,216 | UTF-16 units retained in final extraction output |
textWorkCharacters | 268,435,456 | UTF-16 units copied, allocated, or scanned by instrumented helpers |
nestedPayloads | 256 | Nonempty embedded payload occurrences entered |
nestingDepth | 6 | Embedded traversal depth, with the outer package at depth zero |
textWorkCharacters counts text processed across multiple passes, so it can exceed the final
output size. It must be at least outputCharacters. Its exact count can change between versions.
These limits measure processing work and output size; they do not cap total RAM or temporary disk use. Large values and complex layouts can still use substantial memory. See document-ingestion scratch storage for disk capacity and configuration.
XLSX Page-Image Rendering
| Field | Default | Meaning |
|---|---|---|
maxWidthPixels | 7,680 | Maximum width of one worksheet image |
maxHeightPixels | 4,320 | Maximum height of one worksheet image |
maxPixelsPerImage | 33,177,600 | Maximum pixels in one worksheet image |
maxVisibleCellSlotsPerSheet | 100,000 | Row/column slots visited while building one sheet scene |
maxSceneElementsPerSheet | 500,000 | Drawing elements retained for one sheet scene |
maxImagesPerWorkbook | 20 | Worksheet images emitted from one workbook |
maxTotalPixelsPerWorkbook | 663,552,000 | Aggregate output pixels across one workbook |
GoodMem produces one page image per worksheet. A worksheet that exceeds the per-image raster bounds is rendered as a bounded top-left preview. Pictures and charts that cross the preview edge are clipped at their authored scale rather than squeezed into the image.
The current page-image API does not expose whether an XLSX image covers the full worksheet or a bounded preview. Consumers should therefore treat large XLSX page images as previews, even when their metadata looks like an ordinary worksheet image.
Workbook-level limits are hard ceilings. If a workbook exceeds the image-count or aggregate-pixel limit, XLSX page-image processing fails and GoodMem stores no partial set of worksheet images. Text extraction and the rest of memory ingestion are tracked separately and can still complete. A sheet can also fail page-image processing if it exceeds a scene-work ceiling.
XLSX workbook rendering concurrency remains fixed at one and is not configurable through this policy. The width, height, per-image pixel, image-count, and workbook-pixel settings are independent ceilings. It is valid for one stricter setting to make another ceiling unreachable.
Complete Example
{
"version": 1,
"extraction": {
"packageEntries": 10000,
"zipEntryVisits": 100000,
"inflatedBytes": 268435456,
"materializedBytes": 268435456,
"worksheetVisits": 2048,
"xmlEvents": 20000000,
"structuralWorkSteps": 20000000,
"structuralNestingDepth": 64,
"rowVisits": 2000000,
"cellSlotVisits": 10000000,
"semanticEvents": 500000,
"outputCharacters": 16777216,
"textWorkCharacters": 268435456,
"nestedPayloads": 256,
"nestingDepth": 6
},
"xlsxRendering": {
"maxWidthPixels": 7680,
"maxHeightPixels": 4320,
"maxPixelsPerImage": 33177600,
"maxVisibleCellSlotsPerSheet": 100000,
"maxSceneElementsPerSheet": 500000,
"maxImagesPerWorkbook": 20,
"maxTotalPixelsPerWorkbook": 663552000
}
}GoodMem rejects malformed JSON, duplicate or unknown fields, unsupported versions, non-integral values, numeric overflow, and invalid cross-field combinations before connecting to the database. To roll back an override, remove the command-line option or blank/remove the environment value and restart the server.