iyils opened a new issue, #68309: URL: https://github.com/apache/doris/issues/68309
### Search before asking - [x] I had searched in the [issues](https://github.com/apache/doris/issues?q=is%3Aissue) and found no similar issues. ### Version master, commit_id:6b3ea1eb56dcf57c5f2dd5abb9f170e0fbcf1907 ### What's Wrong? FE BitmapValue.java does not handle BitmapTypeCode.SET (Flag = 5) in its deserialize() method. When BE has enable_set_in_bitmap_value=true, or after #65421 merges wider SET adoption, the FE throws RuntimeException: unknown bitmap type 5 when reading such bitmaps. This causes failures in Spark Load, Hive Catalog bitmap import (bitmap_from_base64), and any path that routes a BE-serialized bitmap through FE. ### What You Expected? FE should be able to deserialize all valid bitmap binary formats produced by BE, including SET type (Flag=5), without throwing an exception. The deserialized bitmap should contain the same set of values as the original bitmap serialized by BE. ### How to Reproduce? **Prerequisites:** - Apache Doris master branch (enable_set_in_bitmap_value=true by default since #35730) **Step 1: Export a SET-format bitmap from BE** On BE, a bitmap with 1–32 elements is serialized as SET type (Flag=5). Use bitmap_to_base64 to export the binary: ```sql SELECT bitmap_to_base64(bitmap_from_array([1, 3, 5])); -- Result: BQMFAAAAAAAAAEAAAAAAAAAAwAAAAAAAAA= -- The decoded bytes start with 0x05 (Flag=5 = SET type). ``` **Step 2: Try to parse the exported binary in FE** Pass the base64 string into any FE-side deserialization path, for example via a Java unit test: ```java byte[] bytes = Base64.getDecoder().decode("BQMFAAAAAAAAAEAAAAAAAAAAwAAAAAAAAA="); DataInput input = new DataInputStream(new ByteArrayInputStream(bytes)); BitmapValue bitmap = new BitmapValue(); bitmap.deserialize(input); // throws RuntimeException: unknown bitmap type 5 ``` ### Anything Else? _No response_ ### Are you willing to submit PR? - [x] Yes I am willing to submit a PR! ### Code of Conduct - [x] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
