Skip to content

Commit

Permalink
THRIFT-5653: Fix Java UUID typeid
Browse files Browse the repository at this point in the history
It should be 16 not 17 according to the spec.

Currently ENUM holds 16, it's not in TBinaryProtocol spec and seems to
be a Java implementation detail somehow got mixed inside TType, move
that to 255 for now. Someone more familiar with Java can probably remove
it from TType completely in the future.

client: java
  • Loading branch information
fishy committed Aug 10, 2023
1 parent 0e872c8 commit a34f08b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions lib/java/src/main/java/org/apache/thrift/protocol/TType.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,9 @@ public final class TType {
public static final byte MAP = 13;
public static final byte SET = 14;
public static final byte LIST = 15;
public static final byte ENUM = 16;
public static final byte UUID = 17;
public static final byte UUID = 16;

// This is not part of the TBinaryProtocol spec but Java specific
// implementation detail.
public static final byte ENUM = 255;
}

0 comments on commit a34f08b

Please sign in to comment.