Java SE, Java EE, JDK, JRE, OpenJDK quelles différences ?

Java SE

Java SE est une spécification dont l’implémentation la plus connnue est le JDK d’Oracle. Java SE contient les classes et concepts de bases de la plateforme Java. Chaque version du JSE contient :

JavaSE_Software_ArchitectureImage provenant de Wikipedia.

Java EE

Java EE (Enterprise Edition) est une spécification. Elle comprend entre autres :

  • Servlet
  • JSTL,
  • JPA
  • JMX
  • JSF
  • EJB
  • JTA
  • JAX-RS

Les serveurs d’applications (Glassfish, JBoss, Tomcat …) sont les implémentation concrètes de cette spécification.

BalusC de stackowerflow :

Your Glassfish server is the concrete Java EE implementation. Note that OpenJDK is
a concrete Java SE implementation. Also note that whenever you download Java EE
from Oracle site, basically all you get is Glassfish along with a bunch of
documents and examples.

Java EE is indeed an abstract specification. The concrete implementations are the
so-called application servers, like Glassfish, JBoss AS, WebLogic, WebSphere, etc.
There are also servletcontainers which implement only the JSP/Servlet part of the
huge Java EE API, such as Tomcat, Jetty, etc. The Java EE SDK download from
Oracle.com contains basically the Glassfish server along a bunch of documentation
and examples and optionally also the Netbeans IDE. EJB is part of the Java EE
specification. Look, it’s in the Java EE API. Fullfledged Java EE application
servers support it out the box, but simple JSP/Servlet containers not.

 

JRE

Le Java Runtime Environnement fourni les librairies, la machine virtuelle et les composants nécessaires pour exécuter les applets et les applications Java. Extrait de la documentation d’Oracle :

Java Runtime Environment (JRE) The Java Runtime Environment (JRE) provides the libraries, the Java Virtual Machine, and other components to run applets and applications written in the Java programming language. In addition, two key deployment technologies are part of the JRE: Java Plug-in, which enables applets to run in popular browsers; and Java Web Start, which deploys standalone applications over a network. It is also the foundation for the technologies in the Java 2 Platform, Enterprise Edition (J2EE) for enterprise software development and deployment. The JRE does not contain tools and utilities such as compilers or debuggers for developing applets and applications.

JDK

Le Java Development Kit est un superset du JRE. En plus du JRE, il contient les outils nécessaires au développement de code java (compilateur / debuggeur notamment). Extrait de la documentation d’Oracle :

Java Development Kit (JDK) The JDK is a superset of the JRE, and contains everything that is in the JRE, plus tools such as the compilers and debuggers necessary for developing applets and applications.

OpenJDK

OpenJDK est l’implémentation libre du standard Java SE, tel que défini par le Java Community Process.Il est développé par la communauté, ainsi que par Oracle et IBM. OpenJDK est l’implémentation de référence de Java SE 7. Il a été initialement développé pour java 7 ; OpenJDK6 est un fork de OpenJDK 7 dans lequel tout le code spécifique à la version 7 a été supprimé pour être compatible avec la spécification java 6.

OpenJDK est le point de départ du Oracle JDK et des autres fournisseurs de JDK (IcedTea). Henrik Stahl sur le blog d’Oracle indique que le processus de build de d’Oracle consiste à ajouter des « patchs » à OpenJDK.
Extrait :

Q: What is the difference between the source code found in the OpenJDK repository, and the code you use to build the Oracle JDK?
A: It is very close – our build process for Oracle JDK releases builds on OpenJDK 7 by adding just a couple of pieces, like the deployment code, which includes Oracle’s implementation of the Java Plugin and Java WebStart, as well as some closed source third party components like a graphics rasterizer, some open source third party components, like Rhino, and a few bits and pieces here and there, like additional documentation or third party fonts. Moving forward, our intent is to open source all pieces of the Oracle JDK except those that we consider commercial features such as JRockit Mission Control (not yet available in Oracle JDK), and replace encumbered third party components with open source alternatives to achieve closer parity between the code bases.

La réponse de Marc sur stackowerflow résume bien OpenJDK :

  • OpenJDK is a reference implementation and does not change unless the spec changes : il y a en effet deux projets : OpenJDK et OpenJDK Update.
  • There is an OpenJDK update project which implements all updates in source (http://openjdk.java.net/projects/jdk7u/, source http://hg.openjdk.java.net/jdk7u/jdk7u-dev)
  • OpenJDK will not provide any compiled or packaged updates. In fact, OpenJDK provided binaries for the initial release just as a convenience.
  • It is the responsibility of third party OS/distributors to compile and package Java. E.g. RedHat and Ubuntu
  • No third party has yet released updates for Java 7
  • These third parties typically use IcedTea to do the compilation and packaging, but IcedTea itself does not do so. http://icedtea.classpath.org/wiki/Main_Page
  • s (e.g. Ubuntu). Now we have to install it by hand or script it, and maintain it, on all our servers.

Le projet OpenJDK Update reçoit bien les security fixes de Oracle.

 

Sources :

http://stackoverflow.com/questions/11060856/openjdk-to-develop-javaee
http://stackoverflow.com/questions/7295096/what-exactly-is-java-ee/
http://stackoverflow.com/questions/11547458/what-is-differences-between-jvm-jdk-jre-openjdk/11580321#11580321
http://www.oracle.com/technetwork/java/javase/tech/index-jsp-140763.html
http://www.infoq.com/news/2009/01/jdk-openjdk-icedtea
http://openjdk.java.net/projects/jdk7u/qanda.html
http://stackoverflow.com/questions/8705061/is-the-openjdk-jvm-the-same-as-the-oracle-java-se-jvm/8711844#8711844
http://stackoverflow.com/questions/8562293/where-are-the-java-7-updates-for-openjdk/8604005#8604005

Laisser un commentaire


7 − six =


NOTE - Vous pouvez utiliser les éléments et attributs HTML tags and attributes:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>