[ https://issues.apache.org/jira/browse/HIVE-3323?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13448184#comment-13448184 ]
Travis Crawford commented on HIVE-3323: --------------------------------------- While making a number of thrift-related change, I've found testing has been a challenge because we didn't have a really comprehensive thrift struct with all the field types we wanted to test. Part of this change is a new struct that actually has an enum field, but also stuff like a binary field (which we now see has basically the same issue as enum, where the HeapByteBuffer is treated like a struct rather than byte[]), set fields (which I didn't realize until recently are not supported, etc. Now we'll have visibility into this stuff and can fix. {code} struct MegaStruct { 1: optional bool my_bool, 2: optional byte my_byte, 3: optional i16 my_16bit_int, 4: optional i32 my_32bit_int, 5: optional i64 my_64bit_int, 6: optional double my_double, 7: optional string my_string, 8: optional binary my_binary, 9: optional map<string, string> my_string_string_map, 10: optional map<string, MyEnum> my_string_enum_map, 11: optional map<MyEnum, string> my_enum_string_map, 12: optional map<MyEnum, MiniStruct> my_enum_struct_map, 13: optional map<MyEnum, list<string>> my_enum_stringlist_map, 14: optional map<MyEnum, list<MiniStruct>> my_enum_structlist_map, 15: optional list<string> my_stringlist, 16: optional list<MiniStruct> my_structlist, 17: optional list<MyEnum> my_enumlist, 18: optional set<string> my_stringset, 19: optional set<MyEnum> my_enumset, 20: optional set<MiniStruct> my_structset } {code} > ThriftSerde: Enable enum to string conversions > ---------------------------------------------- > > Key: HIVE-3323 > URL: https://issues.apache.org/jira/browse/HIVE-3323 > Project: Hive > Issue Type: Improvement > Affects Versions: 0.10.0 > Reporter: Travis Crawford > Assignee: Travis Crawford > Attachments: HIVE-3323_enum_to_string.1.patch, > HIVE-3323_enum_to_string.2.patch, HIVE-3323_enum_to_string.3.patch, > HIVE-3323_enum_to_string.4.patch, HIVE-3323_enum_to_string.5.patch > > > When using serde-reported schemas with the ThriftDeserializer, Enum fields > are presented as {{struct<value:int>}} > Many users expect to work with the string values, which is both easier and > more meaningful as the string value communicates what is represented. > Hive should provide a mechanism to optionally convert enum values to strings. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira