{"record":{"id":"88f2e40b58c06101","repo":"apache/druid","slug":"failed-to-deserialize-v-s-column-88f2e4","errorCode":null,"errorMessage":"Failed to deserialize V%s column.","messagePattern":"Failed to deserialize V(.+?) column\\.","errorType":"exception","errorClass":"RE","httpStatus":null,"severity":"critical","filePath":"processing/src/main/java/org/apache/druid/segment/serde/CompressedComplexColumnSupplier.java","lineNumber":93,"sourceCode":"            mapper\n        );\n\n        if (metadata.hasNulls()) {\n          columnBuilder.setHasNulls(true);\n          final ByteBuffer nullIndexBuffer = NestedCommonFormatColumnPartSerde.loadInternalFile(\n              mapper,\n              metadata.getFileNameBase(),\n              ColumnSerializerUtils.NULL_BITMAP_FILE_NAME\n          );\n          nullValues = metadata.getBitmapSerdeFactory().getObjectStrategy().fromByteBufferWithSize(nullIndexBuffer);\n        } else {\n          nullValues = metadata.getBitmapSerdeFactory().getBitmapFactory().makeEmptyImmutableBitmap();\n        }\n\n        return new CompressedComplexColumnSupplier<>(typeName, objectStrategy, compressedColumnSupplier, nullValues);\n      }\n      catch (IOException ex) {\n        throw new RE(ex, \"Failed to deserialize V%s column.\", version);\n      }\n    }\n    throw new RE(\"Unknown version \" + version);\n  }\n\n  private final String typeName;\n  private final ObjectStrategy<T> objectStrategy;\n  private final CompressedVariableSizedBlobColumnSupplier compressedColumnSupplier;\n  private final ImmutableBitmap nullValues;\n\n  private CompressedComplexColumnSupplier(\n      String typeName,\n      ObjectStrategy<T> objectStrategy,\n      CompressedVariableSizedBlobColumnSupplier compressedColumnSupplier,\n      ImmutableBitmap nullValues\n  )\n  {\n    this.typeName = typeName;","sourceCodeStart":75,"sourceCodeEnd":111,"githubUrl":"https://github.com/apache/druid/blob/9b90983fd291f26935af934383ce360473179e4d/processing/src/main/java/org/apache/druid/segment/serde/CompressedComplexColumnSupplier.java#L75-L111","documentation":"CompressedComplexColumnSupplier.read deserializes a compressed complex (nested/typed) column from a segment on disk. If reading the column data throws an IOException (truncated/corrupt file, IO error while inflating buffers), it is wrapped in this RE reporting the column format version (V3/V4). It indicates the segment column could not be loaded, not a bug in caller code.","triggerScenarios":"Opening a segment whose compressed complex column file is truncated, corrupted, or on unreadable storage; IOException during GenericIndexed/CompressedVariableSizedBlobColumn deserialization inside read().","commonSituations":"Disk corruption or partial segment writes from a crashed historical; segment files truncated during deep-storage download or manual rsync/copy; NFS/HDFS transient IO failures; running a Druid version whose read path hits unexpectedly stored data.","solutions":["Re-download or re-copy the affected segment files from deep storage and reload the segment.","Re-run the affected ingestion task or re-index the affected time chunk to regenerate the segment.","Verify filesystem/deep-storage health (disk space, mount, permissions) for the segment's segmentDir.","If reproducible on freshly generated segments, upgrade Druid/extension versions to match the segment writer's format."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":"try {\n    columnHolder = segmentStorageAdapter.getColumn(\"myCol\");\n} catch (RE e) {\n    if (e.getCause() instanceof IOException) {\n        log.warn(\"Segment %s unreadable, triggering reload\", segmentId, e);\n        segmentManager.dropSegment(segmentId); // let deep-storage reload repair it\n    } else {\n        throw e;\n    }\n}","preventionTips":["Monitor segment load errors on historicals and automate re-download of failed segments from deep storage.","Avoid manual file copies of segment dirs; use Druid's segment load/unload APIs.","Ensure deep storage and local disk health checks are in place."],"tags":["druid","segment","deserialization","io","corrupt-segment"],"backgroundTag":"file-read-failed","analyzedSha":"9b90983fd291f26935af934383ce360473179e4d","analyzedAt":"2026-09-07T13:32:30.957Z","contentChangedAt":"2026-09-07T13:32:30.957Z","schemaVersion":2},"datasetVersion":"2026-09-14T11:17:12.474Z"}