Apache Thrift page suggests minimum java version requirement as 1.7 . My app uses java version 1.6.95. Still I was able to compile and use apache thrift. Anyone has any idea about what this minimum version requirement is for?
-
Did you build it with Java? I'd imagine you'd run into some wonderful "major-minor version" issues if you did it with 1.6.Makoto– Makoto2015-08-16 03:13:36 +00:00Commented Aug 16, 2015 at 3:13
-
If you mean "with-java=yes", then yes , java is active. In fact I have built a java client which is running perfectly fine. Thats what my concern is.Gaurav Joshi– Gaurav Joshi2015-08-16 03:42:11 +00:00Commented Aug 16, 2015 at 3:42
-
What "Apache Thrift page" are you talking about? Provide a link. I can't find one that talks about java version requirements.Stephen C– Stephen C2015-08-16 06:37:58 +00:00Commented Aug 16, 2015 at 6:37
1 Answer
The minimum Java version statement provided on the Apache Thrift web site is set by the community. This statement means that the committers will accept patches that use Java features which require Java 7. So while it may be the case that you can use 6 with the code version you have, you may also find that newer versions of Thrift will not work.
For example I think the TZLibTransport will be a problem as of 2015-05-29, it uses SYNC_FLUSH which is a 1.7 feature: https://github.com/apache/thrift/blob/bb98e97fd3c82117c87d23e3fb6b8bbd800784f2/lib/java/src/org/apache/thrift/transport/TZlibTransport.java.
New commits may create further incompatibilities with Java 6.
So if you are using Java 6 and everything is working for you that is good but I would be cautious when updating Thrift or using new parts of Thrift.
The referenced min ver doc page is: https://thrift.apache.org/docs/install/
which comes from: https://github.com/apache/thrift/blob/1568aef7d499153469131449ec682998598f0d3c/doc/install/README.md