I was using the jxls-2 library, but when I finish my work I've seen that I can't use it with my java version (java 6.22). Do you know if I can solve my problem without change my code? Or in the other side, if I decide to use a jxls older version, I'd have problems with my java version?
That's my first question, by this reason, I'm so sorry if I don't ask correctly.
Thank you!
If you cannot update to Java 7 or to Java 8 (strongly recommended) you have two options:
Use older Jxls 1.x version. Depending on your use case Jxls 1.x may be enough for you.
Checkout the source code for Jxls-2 and change the source/target java version in Maven compiler plugin from Java 7 to Java 6. Possibly you will need to do some minor code changes to compile it but it may also work out of the box.
Related
Why is it that I can't keep the latest version of Java, that I have to downgrade to Java 8 for almost all Apache Projects?
Is Java not backward compatible?
A program compiled to ByteCode on a older JDK should be run perfectly well on the JVM of a newer JDK.
Why is it that I have to go through the pains of building from source?
I thought this was one of the things that Java was supposed to overcome!
This problem is not exclusive to Apache projects. With the newer Java Versions it's not so much about 'understanding the older code' but more about 'am I allowed to use these features the old way' (modularization).
In some cases the older code also uses features that are just not part of the latest JDK any more (e.g. removal of JEE Modules). I'd recommend to read Oracles Migation Guide for more on this topic.
For (bigger) projects the Migration to >Java8 is something that needs to be planned and organized and takes a lot of time.
I have a doubt about java upgrading
I have applications running in java 6, for example.
And I wanto to upgrade my java to a 7 or 8
My doubt is: What is the best way to upgrade mi current java version?
Or how can I do it?
This applications currently are productive, so this means I has to upgrade the java version witouth affectate it.
I'm very confused about this, hope you can help me
There's only one way to do it:
Upgrade the JVM
Recompile the code and fix any errors that the JVM complains about.
Regression test the code running under the new JVM and make sure the functionality is unchanged.
Take the opportunity to see if there are any advantages to adding new features (e.g. java.time package, lambdas, java.util.function package, etc.)
No one should be running on any JVM other than 8 or 9. JDKs older than 8 have passed the end of their support lives. They are not getting any more security patches.
You are making the excuse that everyone tries when faced with currency issues: "The code is working fine. Why change it?"
Unfortunately there's a price to falling behind.
I'd advise you to upgrade as soon as possible. Stop the excuses.
JDK 9 is the current version. Current or current-1 is usually acceptable; current-3 is not.
I have been searching for quite some time to read an "official statement" on this matter, but found none. Therefore, could anyone please indicate a reference or point to some news on this? What version of JasperReports has support for Java 8, or at least is there partial support available? (or is it "trial and error"?)
Some posts on the Jasper community forum seem to indicate that iReport and JasperReports Server does not provide Java 8 support yet. On the other hand, I see some indications that it does, at least in part (http://community.jaspersoft.com/jasperreports-server/issues/3498). It is a bit confusing.
As far as i know, JasperReport does not support Java 8 yet, just like you said. In this post a member of JasperSoft staff clearly states that they will introduce it on later versions of their library, so i would trust him: JasperReport - Java 8 compatibility.
We are not aware of any issue with running JasperReports Library on Java 8.
At some point we needed to upgrade the JDT compiler to support Java 8, but after doing so, there were no other issues we know about.
Yes Java 8 support jasper report i am using jasperreport version 6.0.0 with java 8 and it is working as per expectation
I've recently been messing around with an open-source Java web app. I'm using JDK 7 locally but I know that the upstream builds using JDK 6.
I want to write some code that uses classes that only exist in JDK 7 (currently, ThreadLocalRandom). I can do that on my local system just fine, but when I want to send patches upstream I have to hunt down any such references and translate them to the equivalent JDK6-safe code, which is a pain in the butt.
Is there a way to have both JDK6 and JDK7 source in the project, and have Eclipse automatically use the appropriate version at compile time based on the project target? I would like something that's easy for both myself and the upstream maintainer, so nothing like weird build scripts or text replacement.
The project does use Guice, if that helps, although I think doing it at runtime might be too late (because then the maintainer wouldn't be able to compile using JDK6 tools).
I'm only at "dabbler" level in Java, so please use small words.
I need a little clarification regarding JRE. Is it downward compatible? I mean if I develop an application using java5 and if the target has the latest java6 will my application be able to run?
unless you are using the incompatibilities listed in sun documents Compatibility
Yes, provided you're not using really old deprecated APIs (like, ones deprecated in v1.1)...and maybe even then.
That's APIs. The bytecode is absolutely forward-compatible. It's been revised a couple of times, but always in a forward-compatible way. So code compiled with JDK 1.4 runs fine in the latest; but code compiled with the latest may not run with an older JVM.
Yes - Java's very good about that.
I'm writing about it here java backwards compatibility.
The bytecodes generated can be run in future releases of jvm however the compiler is not backward compatible as bytecodes generated with higher version won't run in older version. This is a good read on Sun site here