Difference between revisions of "GCube Java 8 migration guide"

From Gcube Wiki
Jump to: navigation, search
(Created page with "This page collects the guidelines for the migration of D4Science infrastructure and the gCUbe software from Java 7 to Java 8. It also collects common issues (and their solutio...")
 
Line 1: Line 1:
 
This page collects the guidelines for the migration of D4Science infrastructure and the gCUbe software from Java 7 to Java 8. It also collects common issues (and their solution) experienced during the migration as reference for all gCube developers.
 
This page collects the guidelines for the migration of D4Science infrastructure and the gCUbe software from Java 7 to Java 8. It also collects common issues (and their solution) experienced during the migration as reference for all gCube developers.
 +
 +
NOTE
 +
 +
There are (few) documented incompatibilities between Java 7 and Java 8.
 +
 +
Running into one of them will require to refactor the component and release a new version of it.
 +
 +
Java 8 compatibility guide:
 +
http://www.oracle.com/technetwork/java/javase/8-compatibility-guide-2156366.html
  
 
= Source Code =
 
= Source Code =
  
 +
== Source Incompatibilities ==
 +
 +
* Detected at integration time (the component does not build)
 +
* animal-sniffer-maven-plugin can be used by developers to detect them at development time
 +
 +
== Behaviour Incompatibilities ==
 +
 +
* Cannot be detected at development and integration time
 +
* We will need to carefully test our artifacts
 +
 +
== Other Incompatibilities ==
 +
 +
*
  
 
= JVM =
 
= JVM =
Line 8: Line 30:
  
 
'''TODO''': not enough results to provide guidelines and instructions
 
'''TODO''': not enough results to provide guidelines and instructions
 +
 +
 +
= References =
 +
* Oracle releases plan
 +
http://www.oracle.com/technetwork/java/eol-135779.html
 +
 +
* New features in Java 8
 +
** http://www.oracle.com/technetwork/java/javase/8-whats-new-2157071.html
 +
** https://leanpub.com/whatsnewinjava8/read
 +
 +
* Compatibility guide
 +
http://www.oracle.com/technetwork/java/javase/8-compatibility-guide-2156366.html
 +
 +
* Animal Sniffer Plugin Guide
 +
https://blog.gvsig.org/2011/07/25/hunting-api-incompatibilities-with-the-animal-sniffer-project/

Revision as of 11:49, 16 January 2017

This page collects the guidelines for the migration of D4Science infrastructure and the gCUbe software from Java 7 to Java 8. It also collects common issues (and their solution) experienced during the migration as reference for all gCube developers.

NOTE

There are (few) documented incompatibilities between Java 7 and Java 8.

Running into one of them will require to refactor the component and release a new version of it.

Java 8 compatibility guide: http://www.oracle.com/technetwork/java/javase/8-compatibility-guide-2156366.html

Source Code

Source Incompatibilities

  • Detected at integration time (the component does not build)
  • animal-sniffer-maven-plugin can be used by developers to detect them at development time

Behaviour Incompatibilities

  • Cannot be detected at development and integration time
  • We will need to carefully test our artifacts

Other Incompatibilities

JVM

JVM memory management changed in Java 8: concept of PermGen space has been replaced by Metaspace. As consequence, startup options used in Java 7 (e.g. "-XX:MaxPermSize") rae not valid anymore in JVM 8.

TODO: not enough results to provide guidelines and instructions


References

  • Oracle releases plan

http://www.oracle.com/technetwork/java/eol-135779.html

  • Compatibility guide

http://www.oracle.com/technetwork/java/javase/8-compatibility-guide-2156366.html

  • Animal Sniffer Plugin Guide

https://blog.gvsig.org/2011/07/25/hunting-api-incompatibilities-with-the-animal-sniffer-project/