{"record":{"id":"7bd8986c69b8fe04","repo":"apache/druid","slug":"failed-to-initialize-descriptor","errorCode":null,"errorMessage":"Failed to initialize descriptor","messagePattern":"Failed to initialize descriptor","errorType":"exception","errorClass":"ParseException","httpStatus":null,"severity":"error","filePath":"extensions-core/protobuf-extensions/src/main/java/org/apache/druid/data/input/protobuf/InlineDescriptorProtobufBytesDecoder.java","lineNumber":74,"sourceCode":"\n  @Override\n  protected DescriptorProtos.FileDescriptorSet loadFileDescriptorSet()\n  {\n    try {\n      byte[] decodedDesc = StringUtils.decodeBase64String(descriptorString);\n\n      final var descriptorSet = DescriptorProtos.FileDescriptorSet.parseFrom(decodedDesc);\n      if (descriptorSet.getFileCount() == 0) {\n        throw new ParseException(null, \"No file descriptors found in the descriptor set\");\n      }\n\n      return descriptorSet;\n    }\n    catch (IllegalArgumentException e) {\n      throw new IAE(\"Descriptor string does not have valid Base64 encoding\");\n    }\n    catch (IOException e) {\n      throw new ParseException(descriptorString, e, \"Failed to initialize descriptor\");\n    }\n  }\n\n  @Override\n  public boolean equals(Object o)\n  {\n    if (this == o) {\n      return true;\n    }\n    if (o == null || getClass() != o.getClass()) {\n      return false;\n    }\n    if (!super.equals(o)) {\n      return false;\n    }\n    InlineDescriptorProtobufBytesDecoder that = (InlineDescriptorProtobufBytesDecoder) o;\n    return Objects.equals(getDescriptorString(), that.getDescriptorString());\n  }","sourceCodeStart":56,"sourceCodeEnd":92,"githubUrl":"https://github.com/apache/druid/blob/9b90983fd291f26935af934383ce360473179e4d/extensions-core/protobuf-extensions/src/main/java/org/apache/druid/data/input/protobuf/InlineDescriptorProtobufBytesDecoder.java#L56-L92","documentation":"Initialization failure wrapper in InlineDescriptorProtobufBytesDecoder.loadFileDescriptorSet: parsing the base64-decoded bytes into a FileDescriptorSet threw IOException, meaning the decoded bytes are not a valid protobuf descriptor set (corrupt or wrong content), so the inline descriptor cannot be initialized.","triggerScenarios":"Thrown at extensions-core/protobuf-extensions/src/main/java/org/apache/druid/data/input/protobuf/InlineDescriptorProtobufBytesDecoder.java:74 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Regenerate the base64 descriptor from a valid .proto file and verify by parsing it with protoc.","Confirm the base64 payload decodes to a FileDescriptorSet, not some other protobuf message.","Re-encode without transformations that could corrupt the bytes."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"9b90983fd291f26935af934383ce360473179e4d","analyzedAt":"2026-09-07T13:32:30.957Z","contentChangedAt":"2026-09-07T13:32:30.957Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}