Where can I find the headless version of JDK7 for the linux-i586 architectures?
I couldn't find anything on Oracle's page, maybe I am just blind, or there is no such pre-compiled JDK...
The purpose is that I want to port the runtime library of the JDK to a operating system with a custom JVM, and I think this should be the one suiting best for my needs.
AFAIK there isn't a special headless version of Java 7. But you can easily tell ordinary Java to run in headless mode. For example:
java -Djava.awt.headless=true com.acme.project.Main
For more information on headless Java, read this Oracle page:
Using Headless Mode in the Java SE Platform
I would need this version to keep it as slim as possible.
Your only options would appear to be:
Ask Oracle if they can provide you with a special build (for money!!!).
Attempt to create your own stripped down build from the OpenJDK sources.
Beware that the Oracle binary distribution licence forbids you from distributing a JRE produced by "cutting down" a normal one. I don't know if this applies to a JRE that you have built from source code. Read the relevant license agreements carefully.
But my advice would be to just use a standard JRE installer.
Related
Java 11 does not come with a JRE for download, unlike past Java versions. I got an error "no java run-time environment" when running some Java-based software. To fix the problem, I had to install Java 8 JRE.
How can I get my PC to run Java 11 JRE given that there is no more JRE 11 to download?
I am using Windows 10.
The Answer by Stephen C is correct, and important.
Oracle no longer intends for end-users to be installing a JRE or a JDK. Java Applets in a browser and Java Web Start app delivery are both being phased out, leaving the end-user with no need for a JRE. Java-based apps are expected to bundle their own Java implementation. The only folks consciously installing a JDK will be developers & server-side sysadmins.
Important:
Understand clearly the nature of the OpenJDK project, as explained in Wikipedia
Read this white paper by Oracle of 2018-03, Java Client Roadmap Update
Read the white paper Java Is Still Free, authored by key members of the Java community.
Learn about:
Java Platform Module System
jlink (JEP 282)
jpackage (JEP 343)
Desktop apps are now expected to bundle their own Java runtime. Those tools listed above can create a very small runtime custom-fit to your particular app.
Here is a flowchart diagram that may help you finding and deciding amongst the various vendors providing a Java 11 implementation.
And a table mapping possible motivations or considerations leading to suggested vendors of Java.
Compatibility concerns
In the Comments, an question was raised, concern over compatibility issues between releases by various vendors.
Firstly, know that the OpenJDK project includes a vast suite of tests known as the OpenJDK Community Technology Compatibility Kit (TCK). Vendors are free to self-declare whether their release has passed those tests. These claims are not verified, and rely on the honor system. On my diagram above, I have check-marked "TCK" on the couple vendors I know have self-declared: Oracle JDK by Oracle & Zulu by Azul Systems.
All the products listed in the blue barrel area of my chart above are built almost directly on the OpenJDK source code. So generally, you should see virtually identical compatibility.
There are two areas of concern you might consider: Technology differences, and schedule of updates/patches.
As for technology differences, vendors using the OpenJDK project can ship with either the HotSpot engine or the OpenJ9 engine. These will differ on performance (faster/slower startup versus overall speed, more/less memory), but their behavior in terms of complying with the Java specifications should be identical. They could differ, and certainly either might present a flaw (that likely would be soon fixed) that the other lacked. Personally, I would not be concerned by this, but I mention it for completeness.
Another technology difference is the different kind of JVM used by Zing by Azul Systems and GraalVM by Oracle. Either of these might differ in some way from each other or from the other products, because they intentionally have a different kind of JVM implementation, to offer special features. But given the thoroughness of the Java specs, they should not be incompatible. If they were, you can expect any compatibility problem to be rapidly resolved. If I needed the special features of either of these products, I would use them with full confidence.
Another possible concern is the speed with which a vendor might update their own releases with certain bug fixes or security patches. For example, Oracle has stated that they reserve the right to immediately ship any ready patches to their own customers, while submitting those to the OpenJDK project for consideration. Certainly, any of the vendors providing commercial support are likely to rush a fix or patch to their paying customers. Those releases built as a courtesy to the community provided free-of-cost may take longer to update, likely after the OpenJDK project has incorporated a fix/patch.
And each vendor is free to modify their code base at will, as long as they comply with the Java specs. For example, the Corretto team at Amazon has already made improvements to their own release, and then shared those changes upstream to the OpenJDK project. There may a gap in time before OpenJDK incorporated those changes, if they decide to do so. So it is possible that various releases might differ. But at this point, all of the vendors in the Java community seem to have sincere commitments to work together to prevent fragmentation. So, again, I have no real concern here, but mention this for completeness.
Right now, there seem to be no free + easy Oracle-supported Java 11 JRE (only) options. Your options are:
Download and use an OpenJDK Java 11 JDK from the OpenJDK site.
Download and use an Oracle Java 11 JDK from the Oracle site ... and be sure that you fully understand the restrictions on "commercial use" that now apply to the Oracle Java 11+ releases.
Try to roll your own Windows JRE for Windows from the OpenJDK sources; see Create jre from OpenJDK Windows. (I wouldn't recommend doing this. There are better alternatives.)
Look into using the new jlink tool to create a custom image (basically a cut-down JRE) for your application. This seems to be the option that Oracle want 3rd-party application developers to use.
Talk to Oracle sales about a Java support contract, and specifically ask about how to get a JRE build. (I don't know what the answer will be. If someone does try this, and they get a positive response, please comment!)
Use a 3rd-party Java JRE distribution.
The list of Java vendors changes over time, but as of now it includes AdoptOpenJDK, Amazon, Azul, BellSoft, IBM, jClarity, Red Hat and SAP. See also: Difference between OpenJDK and Adoptium/AdoptOpenJDK
Some of these vendors offer JRE distros. Check their download sites.
Since (nearly) all Java vendors base their products on the same standard OpenJDK codebase that is used for Oracle Java, there is no reason to be concerned about the stability of a 3rd party JRE. Some vendors offer (paid for) support.
(Or switch from Windows to Linux. I can install an OpenJDK Java 11 JRE-only package from the distro package manager on recent versions of Ubuntu, Fedora, ...)
For those people who think that Oracle Java 11 and OpenJDK Java 11 are the same, please read the following from the Oracle download site:
Important changes in Oracle JDK 11 License
With JDK 11 Oracle has updated the license terms on which we offer the Oracle JDK. The new Oracle Technology Network License Agreement for Oracle Java SE is substantially different from the licenses under which previous versions of the JDK were offered. Please review the new terms carefully before downloading and using this product.
Oracle also offers this software under the GPL License on jdk.java.net/11
Notice that Oracle are saying that the licenses for Oracle Java and OpenJDK Java are different. (Not withstanding that the two are built from essentially the same source code base.) Ignore this at your peril!
You can use the "adoptopenjdk" project website to download latest jre and JDK https://github.com/AdoptOpenJDK/openjdk-jdk11
find latest link here > https://adoptopenjdk.net/releases.html?variant=openjdk11&jvmVariant=hotspot
Edit:
Problem has been fixed
I have used their night builds to workaround the problem of missing JRE in JDK package
https://adoptopenjdk.net/nightly.html?variant=openjdk11
zulu still maintains the jre (11 - 16) and it is recommended by some vendors.
you can download it on their site: https://www.azul.com/downloads/zulu/
I'm using java applet on my site. I want to provide correct applet tags which will work in modern browsers and in old IE versions (8+). As far as I understand, modern browsers use <embed> tag and <object> tag provides best experience for Internet Explorer. Internet Explorer even performs automatically silent Java installation, if user does not have installed Java without browser restart. That's very nice.
Now the problem is, most of the documentation regarding <object> tag is outdated. My applet compiles with Java 1.6 and works fine with it, but obviously I want users to install the latest Java. I can't find official documentation about silent installation for Java 8. If I specify classid="clsid:CAFEEFAC-0016-0000-FFFF-ABCDEFFEDCBA", probably that will install Java 1.6 and that's bad. I've found some urls for downloading .cab files and there are no urls for Java 8. Did Oracle remove that convenient method for Java 8?
What is the best approach to use for embedding Java Applets with modern Java with Internet Explorer?
See the Java Rich Internet Applications Deployment Advice for details of the deployment toolkit script. It should write whatever applet tags are recommended for that user agent.
If I specify classid="clsid:CAFEEFAC-0016-0000-FFFF-ABCDEFFEDCBA", probably that will install Java 1.6..
Not anymore. Oracle has dropped support for loading/using an older JRE. Apparently they have become sick of supporting older JREs with potential security bugs.
Why do we have two versions of Java ?
The jdk from Oracle and the one from OpenJDK.
And why is it that
OpenJDK is available only for Linux ?
And on Wikipedia,I find that
Java is open source .But ,I find a copyright information inside the
Oracles JDK saying everything restricted ???
Open JDK is trying to reinvent the wheel by giving you freedom of choice (you can use cool OpenJDK JVM or the mainstream Oracle one)
If something is that cool OBVIOUSLY it's only for linux
that question is out of SO scope, besides I'm not sure myself...
There are many java distributions. Oracle JDK is just the reference one, but others like Open JDK exist. IBM has its own, for example. While they all share the mandatory set of features, each one goes beyond that and implement their own proprietary set. Parts of Oracle JDK are not open source and it requires licensing for embedded devices, and this is why Open JDK exists - to provide a fully free Java implementation. Now, Java, as in "the spec" is open source and most of Oracle JDK is as well. Other companies are allowed to make their own implementations as long they pass Oracle's test that certify compatibility. Still, Oracle owns the Java trademark and I think the ability to certify other implementations. Somewhere there lies in the dispute with Google and their Java implementation (same with now defunct Apache Harmony).
As for the Open JDK on Windows, it can be done by building the sources (like this guy here did). The binaries do not exists probably because there was no demand. It's only Linux that imposes limitations on proprietary software.
What would be the use case of installing IBM Java on a Linux machine? We tested our application on Linux using Oracle Java but one of ours customers installed it on a machine which only has IBM Java and the application gives errors for some missing classes and jars.
I'm assuming that the IBM java would probably have been installed because some IBM products mandate use of IBM java but this should not be a deterrent to install Oracle Java in addition to IBM java. Is my understanding correct?
Please share your thoughts.
I believe IBM doesn't ship its Java as an independent package -- so, yes, if IBM Java is present it's because an IBM product was installed that came with the IBM Java environment. (IBM supports Java on some platforms Sun doesn't; I believe the reverse is also true -- I don't think IBM bothers producing its own Java for Solaris, for obvious reasons.)
There's no problem having multiple Java's installed, each in its own directory. In some Linuxes, the alternatives mechanism can be used to select which Java is the default when you type java at the command line; in others, you would have to manually change the path or adjust symbolic links appropriately (the later is what alternatives does semi-automagically).
If you're working in Eclipse, its configuration menus will let you pick which installed copy of Java it will use to execute/debug applications, either on a workspace-default level or per launch.
(I have something like eight JREs/JDKs installed on my Red Hat machine -- a mix between Sun and IBM. Some are for my own use, for testing code for compatibility or trying to reproduce customer bug reports. Some were installed because a particular tool shipped with its own JRE rather than risk possible incompatabilities with another version; that's the only reason I still have a Java 1.5 JRE installed, for example. It's an annoyance, and it slightly belies Java's original promise of "write once, run everywhere", but it does work.)
There is nothing stopping you from having multiple installs of Java on a single linux system. However when running your application, you need to make sure that you are using the oracle version of java and not the IBM version.
which java
and
java --version
can help you find which version of java you are using.
Java is usually installed under /usr/lib/jvm or something similar to that. Checking there can help you find which java installs you have available.
You are correct that IBM java comes with IBM product installation - IBM does not ship their Java as standalone product. However, they provide provision to download their JRE for Linux from developerworks.
Ideally product running on Oracle JRE should run on IBM JRE and vice versa. However, to ensure that each product on the system runs on the JRE they are tested on, set java home properly for respective products. In case both the products use the same system-wide environment variable (which should not be the case anyway) - you may need to tweak your product settings so it does not break any IBM product running on the system.
As long as you properly isolate multiple JREs as used by different products through product/system property settings, there should not be any issue.
I'm trying to get a rather JDK-sensitive piece of Oracle software working with Websphere, and I need to find some particular versions of the IBM JDK to try. The problem is that IBM doesn't really make these readily available like Sun/Oracle does with theirs, and all the versions I've been able to get my hands on haven't worked for one reason or another.
Specifically, I need one of:
IBM Java 5 SR9 for Windows (ideal)
IBM Java 5 SR2 for Windows
IBM Java 5 SR10 for Windows
How could I get these directly from IBM? My company has a support contract for Websphere, and I hopefully could have one of our Websphere engineers download it if I can tell them where to go.
I don't know if this is still true(but this was certainly true in the past), but here is the story.
Due to Java License restrictions earlier, the JDK cannot be provided alone by vendors like IBM.
I am unable to pull this info from any IBM site at the moment but i am pretty certain about these license restrictions in the past.
Here is a post by another gentleman in this space:
From : http://www.ibm.com/developerworks/forums/thread.jspa?messageID=14514070
Unfortunately you can get hold of the JDK only as part of another IBM product (say, Websphere or any Rational product) that you purchased. Our licensing agreement with Sun/Oracle forbids us from providing direct downloads of the IBM JDK on any platforms that Oracle/Sun also support (namely Windows and Linux). If you look at the Java downloads section of the developerWorks website, you'll only find SDKs for AIX, z/OS and Linux on System p/z, since those are IBM owned platforms that Oracle doesn't support.
Since the JDK is shipped along with Websphere/Rational/Tivoli products, you can use it if you already have one of them deployed(though even then you may have SR8 FP1, unless you also install the very latest fix packs for those products).
(Unless you work for IBM) there is no way to download the IBM JDK separately. It's shipped with the IBM Rational Suite of Software IBM develops.
The IBM JDK comes also with IBM Java Profiler (which isn't free).
The Eclipse Platform that is found here https://www.ibm.com/developerworks/eclipse/downloads/helios/#download is similar to the Eclipse download found on the Eclipse Site. IBM makes it easier for those who can't afford WebSphere Application Developer or Rational Application Developer (which are both Eclipse flavour) to use Eclipse.
Currently, (July 12 2017) you can find the older bundles for java 6, 7 and 7.1 here https://www.ibm.com/developerworks/java/jdk/eclipse/index.html
The latest one can be downloaded from here https://developer.ibm.com/javasdk/downloads/eclipse/
Yes IBM JRE/JDK is typically shipped with products, not stand-alone.
How about you get the WebSphere version that is the target for your activity and install that? Won't that give you what you need? The Single server edition is comparatively small footprint.
Here's a page with some IBM JDKs made available on developerWorks that may be useful to you.
https://www.ibm.com/developerworks/java/jdk/
the SR9 fix pack for WAS V6.1.0.25 is available here - http://www-01.ibm.com/support/docview.wss?uid=swg24023276. Click on the FTP link to download the PAK file (and rename to zip).
Previously I've found that the Eclipse bundles from IBM also contain the IBM JVM. This might still be the case but the bundles are too big for me to check now.
See http://www.ibm.com/developerworks/eclipse/downloads/
I hate to answer with the obvious... but if you have a support contract with IBM, why not just call IBM support? If you haven't seen it already, IBM's main JDK page is at: https://www.ibm.com/developerworks/java/jdk/.
However, the Windows offerings are pretty pitiful. IBM hasn't released a new JDK for the Windows platform since early-2006. That JDK was of the Java 5 generation, but there's no indication on the download page (or in the installer's file name) of an SR version. I can't install it and check for you, because of the other Windows caveat of which I hope you're aware: The IBM JDK will not install on a Windows machine unless the installer detects an IBM BIOS.
Given that IBM sold their PC division to Lenovo, I'm not even sure that it is possible AT ALL to install their standalone JDK on a contemporary box. I would contact IBM support if you have a contract... they might be able to tell you differently.
Either way, the preceding answer points at another possibility. IBM frequently bundles its JDK/JRE, without the crazy restrictions found in the standalone version, inside of other downloads. For instance, I know that WebSphere Community Edition (i.e. IBM's version of Apache Geronimo) comes with one. Good luck finding the specific version you need... but if you do, and don't mind the possibility of violating some license legalese, then you can just ZIP up that directory and copy it to the target machine.
This whole topic is a damn shame. In terms of bechmarks and runtime performance, the IBM JDK/JRE has always been awesome. However, on the larger "ecosystem" level it's always sucked.