[ https://issues.apache.org/jira/browse/THRIFT-2381?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13913457#comment-13913457 ]
Jens Geyer commented on THRIFT-2381: ------------------------------------ (1) The file you linked does not have any {{map<>}}s at all. You probably meant [the other one|http://svn.apache.org/viewvc/hbase/tags/0.94.3/src/main/resources/org/apache/hadoop/hbase/thrift/Hbase.thrift?view=co]?. Possible workaround (not tested, but very likely to work): On top of the thrift file, there's a section as follows: {code} // NOTE: all variables with the Text type are assumed to be correctly // formatted UTF-8 strings. This is a programming language and locale // dependent property that the client application is repsonsible for // maintaining. If strings with an invalid encoding are sent, an // IOError will be thrown. {code} In the code that is directly below that text, try to replace the line {code} typedef binary Text {code} by {code} typedef string Text {code} Ther are no guarantees, but it's worth a try. Have you had the time to look at the other ticket's patch? > code which generated by thrift2/hbase.thrift compile error > ---------------------------------------------------------- > > Key: THRIFT-2381 > URL: https://issues.apache.org/jira/browse/THRIFT-2381 > Project: Thrift > Issue Type: Bug > Environment: hbase-0.94.3 > thrift-0.9.1 > go version go1.1.2 linux/amd64 > ubuntu 3.5.0-23-generic > Reporter: sherlockhua > > command: > ./bin/thrift -gen go > ./hbase/hbase-thrift/src/main/resources/org/apache/hadoop/hbase/thrift2/hbase.thrift > complile error: > src/hbase/ttypes.go:1103: invalid map key type []byte > src/hbase/ttypes.go:1267: invalid map key type []byte > src/hbase/ttypes.go:1495: invalid map key type []byte > src/hbase/ttypes.go:1616: invalid map key type []byte > src/hbase/ttypes.go:1812: invalid map key type []byte > src/hbase/ttypes.go:1947: invalid map key type []byte > src/hbase/ttypes.go:2133: invalid map key type []byte > src/hbase/ttypes.go:2237: invalid map key type []byte > src/hbase/ttypes.go:2412: invalid map key type []byte > src/hbase/ttypes.go:2697: invalid map key type []byte > src/hbase/ttypes.go:2237: too many errors -- This message was sent by Atlassian JIRA (v6.1.5#6160)