Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
Description
In the new release, Kylin will check the value length when building trie dictionary, in class TrieDictionaryBuilder method buildTrieBytes, through method:
private void positiveShortPreCheck(int i, String fieldName) {
if (!BytesUtil.isPositiveShort)
}
public static boolean isPositiveShort(int i)
And 0xFFFF7000 in binary: 1111 1111 1111 1111 0111 0000 0000 0000, so the value length should be less than 0000 0000 0000 0000 0001 0000 0001 1111, values 4095 in decimalism.
I wonder why is 0xFFFF7000, should 0xFFFF8000 (1111 1111 1111 1111 1000 0000 0000 0000), support max length: 0000 0000 0000 0000 0111 1111 1111 1111 (32767)
be what you want?
Or 32767 may be too large, I prefer use 0xFFFFE000, 0xFFFFE000 (1111 1111 1111 1111 1110 0000 0000 0000), support max length: 0000 0000 0000 0000 0001 1111 1111 1111 (8191)
Attachments
Attachments
Issue Links
- Blocked
-
KYLIN-2907 Check if a number is a positive integer
- Closed