I have a question about Apache Commons projects
. We know there are many nice classes and methods are available in Apache Commons Projects
. But it is related to particular Java edition, I think. If I start use Apache Commons projects now, when Java updates itself to 1.8, I have to make sure Apache Co开发者_JAVA百科mmons projects has the similar update before I update to Java version 1.8? Having some 3rdparty libs is a good thing but I always worry about the compatibility between them and the main programming language I am using.
In general Java is fully backwards compatible, so if you start using e.g. commons-io in JSE1.6 it's going to work in JSE1.8 as well. Working with Java since 1999 I've never seen any issues regarding backwards compatibility.
EDIT: As long as Oracle does not change its compatibility policy, you should not run into trouble. If you later run into trouble anyway, you still have the source to fix it on your own (but may have to give back to the community depending on the license).
The Apache Commons projects update a lot more often than the JDK does. I would strongly advise to keep you libraries current. Even if only to get the newest fixes. That will also take care of any possible problems with JDK versions (which are backwards-compatible and have changed very little over the years and could be considered rather stable).
But it is related to particular Java edition, I think.
The only case where I have ever seen this be true with Apache Commons, Jakarta Anything or Spring was when one version used new JVM and/or compiler features. For example, Spring 2.5 had several jars which were for 1.5 and newer which means that in theory they would work on Java 5 through Java 8 without any bugs caused by the platform. You just couldn't use them on a Java 3 or 4 VM.
This is pretty much the norm throughout the Java community, for SE anyway. JavaEE compatibility may break because it's a matter of library compatibility and development methodology.
精彩评论