SlideShare a Scribd company logo
1 of 42
Download to read offline
Java 8
Good & Bad
Overview by Nicola Pedot - 26 giugno 2014
https://creativecommons.org/licenses/by/3.0/it
Status
On 2014, Java is one of the most used programming
language for client-server applications, with approximately
9 million developers.
Oracle Java Versions:
6 archived
7 production ready (java.net)
8 for developers (java.com)
Corporate Support
IBM
Oracle
Red Hat
Google
Java 8 Parts
Process
Development Kit- JDK
Virtual Machine VM
Language
Runtime Libraries - JRE
Editions - JEE, JSE, JME, JEmbedded
Java Community Process
The JCP remains the governing body for all standard Java
SE APIs and related interfaces. If a proposal accepted into
this process intends to revise existing standard interfaces,
or to define new ones, then a parallel effort to design,
review, and approve those changes must be undertaken in
the JCP, either as part of a Maintenance Review of an
existing JSR or in the context of a new JSR.
JDK Enhancement-Proposal
JEP 1: JDK Enhancement-Proposal & Roadmap Process
Author Mark Reinhold
Organization Oracle
Created 2011/6/23
Updated 2012/12/4
The primary goal of this process is to produce a regularly-updated list of
proposals to serve as the long-term Roadmap for JDK Release Projects and related
efforts.
This process is open to every OpenJDK Committer.
This process does not in any way supplant the Java Community Process.
Java JDK - OpenJDK
JDK 8 was the second part of "Plan B". The single driving
feature of the release was Project Lambda. (Project Jigsaw
was initially proposed for this release but later dropped).
Additional features proposed via the JEP Process were
included so long as they fit into the overall schedule
required for Lambda. Detailed information on the features
included in the release can be found on the features page.
The source is open and avaliable on Mercurial
repository.
Java VM - HotSpot
Below you will find the source code for the Java HotSpot virtual
machine, the best Java virtual machine on the planet.
The HotSpot code base has been worked on by dozens of people,
over the course of 10 years, so far. (That's good and bad.) It's
big. There are nearly 1500 C/C++ header and source files,
comprising almost 250,000 lines of code. In addition to the
expected class loader, bytecode interpreter, and supporting
runtime routines, you get two runtime compilers from bytecode to
native instructions, 3 (or so) garbage collectors, and a set of
high-performance runtime libraries for synchronization, etc.
Java 8 Hot Topics
Default Methods
Function Iterfaces (Closure, Lambda) or AntiScala
Streams
Parallel
Javascript Nashorn
Java Time
SNI IPV6
Security
Default methods
Default methods enable you to add new
functionality to the interfaces of your libraries
and ensure binary compatibility with code
written for older versions of those interfaces.
Note: interfaces do not have any state
Default method syntax
public interface oldInterface {
public void existingMethod();
default public void newDefaultMethod() {
System.out.println("New default method"
" is added in interface");
}
}
The following class will compile successfully in Java JDK 8,?
public class oldInterfaceImpl implements oldInterface {
public void existingMethod() {
// existing implementation is here…
}
}
If you create an instance of oldInterfaceImpl:?
oldInterfaceImpl obj = new oldInterfaceImpl ();
// print “New default method add in interface”
obj.newDefaultMethod();
Default method conflict
java: class Impl inherits unrelated defaults for defaultMethod() from types InterfaceA and InterfaceB
In order to fix this class, we need to provide default method implementation:
public class Impl implements InterfaceA, InterfaceB {
public void defaultMethod(){
// existing code here..
InterfaceA.super.defaultMethod();
}
}
Default method good
The great thing about using interfaces instead
of adapter classes is the ability to extend
another class than the particular adapter.
Simil multiple inheritance.
Finally, library developers are able to evolve
established APIs without introducing
incompatibilities to their user's code.
Default method bad
In a nutshell, make sure to never override a default
method in another interface. Neither with another
default method, nor with an abstract method.
Before Java 7, you would only need to look for the
actually invoked code by traversing down a linear
class hierarchy. Only add this complexity when you
really feel it is absolutely necessary.
Lambda: functional interface
A functional interface is any interface that
contains only one abstract method. (A
functional interface may contain one or more
default methods or static methods.)
Lambda syntax
//Prima:
List list1 = Arrays.asList(1,2,3,5);
for(Integer n: list1) {
System.out.println(n);
}
//Dopo:
List list2 = Arrays.asList(1,2,3,5);
list2.forEach(n -> System.out.println(n));// default method forEach
//Espressioni lambda e doppio due punti static method reference
list2.forEach(System.out::println);
Lambda syntax (2)
// Anonymous class
new CheckPerson() {
public boolean test(Person p) {
return p.getGender() == Person.Sex.MALE
&& p.getAge() >= 18
&& p.getAge() <= 25;
}
}
// Lambda
(Person p) -> p.getGender() == Person.Sex.MALE
&& p.getAge() >= 18
&& p.getAge() <= 25
Good: Stream sample
Map<Person.Sex, List<Person>> byGender =
roster.stream().collect(
Collectors.groupingBy(Person::getGender));
Good: Parallel Stream sample
ConcurrentMap<Person.Sex, List<Person>> byGender =
roster.parallelStream().collect(
Collectors.groupingByConcurrent(Person::getGender))
Stream Bad Parts
“Java 8 Streams API will be the single biggest source of
new Stack Overflow questions.”
With streams and functional thinking, we’ll run into a
massive amount of new, subtle bugs. Few of these bugs
can be prevented, except through practice and staying
focused. You have to think about how to order your
operations. You have to think about whether your streams
may be infinite. [14]
Stream Bad Parts (2)
“If evaluation of one parallel stream results in a very long running
task, this may be split into as many long running sub-tasks that
will be distributed to each thread in the pool. From there, no
other parallel stream can be processed because all threads will
be occupied.”
If a program is to be run inside a container, one must be very
careful when using parallel streams. Never use the default pool
in such a situation unless you know for sure that the container
can handle it. In a Java EE container, do not use parallel
streams. [15]
Parallel Lang Tools: StampedLock
The ReentrantReadWriteLock had a lot of shortcomings: It
suffered from starvation. You could not upgrade a read lock
into a write lock. There was no support for optimistic reads.
Programmers "in the know" mostly avoided using them.
StampedLock addresses all these shortcomings
Parallel Lang Tools:Concurrent Adders
Concurrent Adders:
this is a new set of classes for managing counters written
and read by multiple threads. The new API promises
significant performance gains, while still keeping things
simple and straightforward.
Bad Part
We’re paying the price for shorter, more
concise code with more complex debugging,
and longer synthetic call stacks.
The Reason
The reason is that while javac has been
extended to support Lambda functions, the
JVM still remains oblivious to them.
Javascript
Un nome per tutti: node.jar from Oracle
JavaScript from Java
package sample1;
import javax.script.ScriptEngine;
import javax.script.ScriptEngineManager;
public class Hello {
public static void main(String... args) throws Throwable {
ScriptEngine engine = new ScriptEngineManager().getEngineByName("nashorn");
engine.eval("function sum(a, b) { return a + b; }");
System.out.println(engine.eval("sum(1, 2);"));
engine.eval(new FileReader("src/sample1/greeter.js"));
System.out.println(invocable.invokeFunction("greet", "Julien"));
}
}
JavaScript DB Connection
var someDatabaseFun = function() {
var Properties = Java.type("java.util.Properties");
var Driver = Java.type("org.h2.Driver");
var driver = new Driver();
var properties = new Properties();
properties.setProperty("user", "sa");
properties.setProperty("password", "");
try {
var conn = driver.connect(
"jdbc:h2:~/test", properties);
// Database code here
}
finally {
try {
if (conn) conn.close();
} catch (e) {}
}
}
someDatabaseFun();
JavaScript with JOOQ
DSL.using(conn)
.select(
t.TABLE_SCHEMA,
t.TABLE_NAME,
count().as("CNT"))
.from(t)
.join(c)
.on(row(t.TABLE_SCHEMA, t.TABLE_NAME)
.eq(c.TABLE_SCHEMA, c.TABLE_NAME))
.groupBy(t.TABLE_SCHEMA, t.TABLE_NAME)
.orderBy(
t.TABLE_SCHEMA.asc(),
t.TABLE_NAME.asc())
// continue in next slide
JavaScript with stream
DSL.using(conn)
.select(...) // this is folded code.
// This fetches a List<Map<String, Object>> as
// your ResultSet representation
.fetchMaps()
// This is Java 8's standard Collection.stream()
.stream()
// And now, r is like any other JavaScript object
// or record!
.forEach(function (r) {
print(r.TABLE_SCHEMA + '.'
+ r.TABLE_NAME + ' has '
+ r.CNT + ' columns.');
});
Javascript Problem
In this case the bytecode code is dynamically
generated at runtime using a nested tree of
Lambda expressions. There is very little
correlation between our source code, and the
resulting bytecode executed by the JVM. The
call stack is now two orders of magnitude
longer.
The Hard Side
Haskell is good at preventing bugs.
Java without lambda has readable stacktrace.
In Groovy is harder reading exceptions,
Java8 Lambda is also harder,
Javascript is even harder.
JavaTime, JodaTime’s revenge
● The Calendar class was not type safe.
● Because the classes were mutable, they could not be
used in multithreaded applications.
● Bugs in application code were common due to the
unusual numbering of months and the lack of type
safety.
JodaTime syntax
import java.time.Instant;
Instant timestamp = Instant.now();
This class format follows the ISO-8601
2013-05-30T23:38:23.085Z
Come gestire le vecchie date?
Date.toInstant()
public static Date from(Instant instant)
Calendar.toInstant()
Other classes Clock, Period,...
SNI IPV6
Assigning a separate IP address for each site increases the cost of hosting since requests for IP addresses must be justified to the
regional internet registry and IPv4 addresses are now in short supply.
An extension to TLS called Server Name Indication (SNI) addresses this issue by sending the name of the virtual domain as part
of the TLS negotiation. <<Wikipedia>>
E’ possibile configurare in un webserver più
virtual host con diversi certificati SSL
utilizzando un solo indirizzo IP.
provocazione...in vista dell’esaurimento di IP di
InternetOfThings…. Java Everywhere?
Security
java.security.SecureRandom
This class provides a cryptographically strong random
number generator (RNG).
Others...
1. Process termination
Process destroyForcibly(); isAlive(); waitFor(long timeout, TimeUnit unit);
2. Optional Values
String name = computer.flatMap(Computer::getSoundcard)
.flatMap(Soundcard::getUSB)
.map(USB::getVersion)
.orElse("UNKNOWN");
3. Annotate Anything
Type Annotations are annotations that can be placed anywhere you use a type. This includes the new operator, type casts,
implements clauses and throws clauses
Others… (2)
4. Directory Walking
Interface DirectoryStream<T> extends Iterator
default void forEach(Consumer<? super T> action)
default Spliterator<T> spliterator()
New Domains
Java started simple by design, now it has to
gain complexity to model new domains.
from Static Object Orienteed to
->(functional) Parallel Event Orienteed
->(dynamic) Syntax & Check relaxed
== More fun & more dangerous times ahead!
from Java8 to Java9
from….
Enterprise Edition
Standard Edition
Embedded Edition
Mobile Edition
…. to Java9 complete module system
Compact Profiles
Java Compact Profiles,
A reasonably configured Java SE-Embedded 8 for ARMv5/Linux
compact1 profile comes in at less than 14MB
compact2 is about 18MB and
compact3 is in the neighborhood of 21MB.
For reference, the Java SE-Embedded 7u21 Linux environment requires 45MB.
Links
1. http://www.dzone.com/links/r/the_bad_parts_of_lambdas_in_java_8.html
2. http://docs.oracle.com/javase/tutorial/java/javaOO/lambdaexpressions.html
3. http://www.javacodegeeks.com/2014/04/15-must-read-java-8-tutorials.html
4. http://www.oracle.com/events/us/en/java8/index.html?msgid=3-9911533944
5. http://typesafe.com/blog/reactive-programming-patterns-in-akka-using-java-8
6. http://java.dzone.com/articles/java-8-will-revolutionize
7. http://openjdk.java.net/jeps/117
8. http://hg.openjdk.java.net/jdk8
9. http://it.wikipedia.org/wiki/Java_%28linguaggio_di_programmazione%29
10. http://java.dzone.com/articles/5-features-java-8-will-change
11. http://java.dzone.com/articles/10-features-java-8-you-havent
12. http://java.dzone.com/articles/java-lambda-expressions-vs
13. http://java.dzone.com/articles/java-8-default-methods-can
14. http://blog.informatech.cr/2013/03/11/java-infinite-streams/
15. http://java.dzone.com/articles/whats-wrong-java-8-part-iii

More Related Content

What's hot

Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov
Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov
Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov Nayden Gochev
 
Advance Java Topics (J2EE)
Advance Java Topics (J2EE)Advance Java Topics (J2EE)
Advance Java Topics (J2EE)slire
 
The features of java 11 vs. java 12
The features of  java 11 vs. java 12The features of  java 11 vs. java 12
The features of java 11 vs. java 12FarjanaAhmed3
 
Tech_Implementation of Complex ITIM Workflows
Tech_Implementation of Complex ITIM WorkflowsTech_Implementation of Complex ITIM Workflows
Tech_Implementation of Complex ITIM Workflows51 lecture
 
Software Uni Conf October 2014
Software Uni Conf October 2014Software Uni Conf October 2014
Software Uni Conf October 2014Nayden Gochev
 
An Introduction to Java Compiler and Runtime
An Introduction to Java Compiler and RuntimeAn Introduction to Java Compiler and Runtime
An Introduction to Java Compiler and RuntimeOmar Bashir
 
Java byte code & virtual machine
Java byte code & virtual machineJava byte code & virtual machine
Java byte code & virtual machineLaxman Puri
 
Whats New in Java 5, 6, & 7 (Webinar Presentation - June 2013)
Whats New in Java 5, 6, & 7 (Webinar Presentation - June 2013)Whats New in Java 5, 6, & 7 (Webinar Presentation - June 2013)
Whats New in Java 5, 6, & 7 (Webinar Presentation - June 2013)DevelopIntelligence
 
SoftwareUniversity seminar fast REST Api with Spring
SoftwareUniversity seminar fast REST Api with SpringSoftwareUniversity seminar fast REST Api with Spring
SoftwareUniversity seminar fast REST Api with SpringNayden Gochev
 
What's New in Java 8
What's New in Java 8What's New in Java 8
What's New in Java 8javafxpert
 
Advanced java programming-contents
Advanced java programming-contentsAdvanced java programming-contents
Advanced java programming-contentsSelf-Employed
 
55 New Features in Java SE 8
55 New Features in Java SE 855 New Features in Java SE 8
55 New Features in Java SE 8Simon Ritter
 
The Dark Side Of Lambda Expressions in Java 8
The Dark Side Of Lambda Expressions in Java 8The Dark Side Of Lambda Expressions in Java 8
The Dark Side Of Lambda Expressions in Java 8Takipi
 
Java Code Generation for Productivity
Java Code Generation for ProductivityJava Code Generation for Productivity
Java Code Generation for ProductivityDavid Noble
 
The Art of Metaprogramming in Java
The Art of Metaprogramming in Java  The Art of Metaprogramming in Java
The Art of Metaprogramming in Java Abdelmonaim Remani
 

What's hot (20)

Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov
Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov
Lecture from javaday.bg by Nayden Gochev/ Ivan Ivanov and Mitia Alexandrov
 
Advance Java Topics (J2EE)
Advance Java Topics (J2EE)Advance Java Topics (J2EE)
Advance Java Topics (J2EE)
 
The features of java 11 vs. java 12
The features of  java 11 vs. java 12The features of  java 11 vs. java 12
The features of java 11 vs. java 12
 
Tech_Implementation of Complex ITIM Workflows
Tech_Implementation of Complex ITIM WorkflowsTech_Implementation of Complex ITIM Workflows
Tech_Implementation of Complex ITIM Workflows
 
Software Uni Conf October 2014
Software Uni Conf October 2014Software Uni Conf October 2014
Software Uni Conf October 2014
 
An Introduction to Java Compiler and Runtime
An Introduction to Java Compiler and RuntimeAn Introduction to Java Compiler and Runtime
An Introduction to Java Compiler and Runtime
 
Java byte code & virtual machine
Java byte code & virtual machineJava byte code & virtual machine
Java byte code & virtual machine
 
Whats New in Java 5, 6, & 7 (Webinar Presentation - June 2013)
Whats New in Java 5, 6, & 7 (Webinar Presentation - June 2013)Whats New in Java 5, 6, & 7 (Webinar Presentation - June 2013)
Whats New in Java 5, 6, & 7 (Webinar Presentation - June 2013)
 
1.introduction to java
1.introduction to java1.introduction to java
1.introduction to java
 
SoftwareUniversity seminar fast REST Api with Spring
SoftwareUniversity seminar fast REST Api with SpringSoftwareUniversity seminar fast REST Api with Spring
SoftwareUniversity seminar fast REST Api with Spring
 
Java 8 features
Java 8 featuresJava 8 features
Java 8 features
 
What's New in Java 8
What's New in Java 8What's New in Java 8
What's New in Java 8
 
Advanced java programming-contents
Advanced java programming-contentsAdvanced java programming-contents
Advanced java programming-contents
 
55 New Features in Java SE 8
55 New Features in Java SE 855 New Features in Java SE 8
55 New Features in Java SE 8
 
Java 7 & 8
Java 7 & 8Java 7 & 8
Java 7 & 8
 
Complete Java Course
Complete Java CourseComplete Java Course
Complete Java Course
 
The Dark Side Of Lambda Expressions in Java 8
The Dark Side Of Lambda Expressions in Java 8The Dark Side Of Lambda Expressions in Java 8
The Dark Side Of Lambda Expressions in Java 8
 
Java Code Generation for Productivity
Java Code Generation for ProductivityJava Code Generation for Productivity
Java Code Generation for Productivity
 
The Art of Metaprogramming in Java
The Art of Metaprogramming in Java  The Art of Metaprogramming in Java
The Art of Metaprogramming in Java
 
Java 9, JShell, and Modularity
Java 9, JShell, and ModularityJava 9, JShell, and Modularity
Java 9, JShell, and Modularity
 

Viewers also liked

BDD & design paradoxes appunti devoxx2012
BDD & design paradoxes   appunti devoxx2012BDD & design paradoxes   appunti devoxx2012
BDD & design paradoxes appunti devoxx2012Nicola Pedot
 
BDD in DDD
BDD in DDDBDD in DDD
BDD in DDDoehsani
 
Sviluppare software a colpi di test – II appuntamento: “mani in pasta col BDD.
Sviluppare software a colpi di test – II appuntamento: “mani in pasta col BDD.Sviluppare software a colpi di test – II appuntamento: “mani in pasta col BDD.
Sviluppare software a colpi di test – II appuntamento: “mani in pasta col BDD.Open Campus Tiscali
 
Sviluppare software a colpi di test. Introduzione al BDD
Sviluppare software a colpi di test. Introduzione al BDDSviluppare software a colpi di test. Introduzione al BDD
Sviluppare software a colpi di test. Introduzione al BDDOpen Campus Tiscali
 
Behaviour Driven Development - Tutta questione di comunicazione
Behaviour Driven Development - Tutta questione di comunicazioneBehaviour Driven Development - Tutta questione di comunicazione
Behaviour Driven Development - Tutta questione di comunicazioneCodemotion
 

Viewers also liked (9)

BDD & design paradoxes appunti devoxx2012
BDD & design paradoxes   appunti devoxx2012BDD & design paradoxes   appunti devoxx2012
BDD & design paradoxes appunti devoxx2012
 
JavaEE6 my way
JavaEE6 my wayJavaEE6 my way
JavaEE6 my way
 
The BDD live show (ITA)
The BDD live show (ITA)The BDD live show (ITA)
The BDD live show (ITA)
 
BDD in DDD
BDD in DDDBDD in DDD
BDD in DDD
 
Bdd
BddBdd
Bdd
 
Sviluppare software a colpi di test – II appuntamento: “mani in pasta col BDD.
Sviluppare software a colpi di test – II appuntamento: “mani in pasta col BDD.Sviluppare software a colpi di test – II appuntamento: “mani in pasta col BDD.
Sviluppare software a colpi di test – II appuntamento: “mani in pasta col BDD.
 
Sviluppare software a colpi di test. Introduzione al BDD
Sviluppare software a colpi di test. Introduzione al BDDSviluppare software a colpi di test. Introduzione al BDD
Sviluppare software a colpi di test. Introduzione al BDD
 
Behaviour Driven Development - Tutta questione di comunicazione
Behaviour Driven Development - Tutta questione di comunicazioneBehaviour Driven Development - Tutta questione di comunicazione
Behaviour Driven Development - Tutta questione di comunicazione
 
dalTDDalBDD
dalTDDalBDDdalTDDalBDD
dalTDDalBDD
 

Similar to Java 8 Overview

Introduction of Java 8 with emphasis on Lambda Expressions and Streams
Introduction of Java 8 with emphasis on Lambda Expressions and StreamsIntroduction of Java 8 with emphasis on Lambda Expressions and Streams
Introduction of Java 8 with emphasis on Lambda Expressions and StreamsEmiel Paasschens
 
What is Java Technology (An introduction with comparision of .net coding)
What is Java Technology (An introduction with comparision of .net coding)What is Java Technology (An introduction with comparision of .net coding)
What is Java Technology (An introduction with comparision of .net coding)Shaharyar khan
 
New Features of JAVA SE8
New Features of JAVA SE8New Features of JAVA SE8
New Features of JAVA SE8Dinesh Pathak
 
Java/Servlet/JSP/JDBC
Java/Servlet/JSP/JDBCJava/Servlet/JSP/JDBC
Java/Servlet/JSP/JDBCFAKHRUN NISHA
 
Java 9 features
Java 9 featuresJava 9 features
Java 9 featuresshrinath97
 
Features java9
Features java9Features java9
Features java9srmohan06
 
eXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework IntroductioneXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework Introductionvstorm83
 
OBJECT ORIENTED PROGRAMMING LANGUAGE - SHORT NOTES
OBJECT ORIENTED PROGRAMMING LANGUAGE - SHORT NOTESOBJECT ORIENTED PROGRAMMING LANGUAGE - SHORT NOTES
OBJECT ORIENTED PROGRAMMING LANGUAGE - SHORT NOTESsuthi
 
Java2 platform
Java2 platformJava2 platform
Java2 platformSajan Sahu
 
imperative programming language, java, android
imperative programming language, java, androidimperative programming language, java, android
imperative programming language, java, androidi i
 
Java dev mar_2021_keynote
Java dev mar_2021_keynoteJava dev mar_2021_keynote
Java dev mar_2021_keynoteSuyash Joshi
 

Similar to Java 8 Overview (20)

Java basic
Java basicJava basic
Java basic
 
Introduction of Java 8 with emphasis on Lambda Expressions and Streams
Introduction of Java 8 with emphasis on Lambda Expressions and StreamsIntroduction of Java 8 with emphasis on Lambda Expressions and Streams
Introduction of Java 8 with emphasis on Lambda Expressions and Streams
 
Colloquium Report
Colloquium ReportColloquium Report
Colloquium Report
 
What is Java Technology (An introduction with comparision of .net coding)
What is Java Technology (An introduction with comparision of .net coding)What is Java Technology (An introduction with comparision of .net coding)
What is Java Technology (An introduction with comparision of .net coding)
 
Basic java part_ii
Basic java part_iiBasic java part_ii
Basic java part_ii
 
java new technology
java new technologyjava new technology
java new technology
 
New Features of JAVA SE8
New Features of JAVA SE8New Features of JAVA SE8
New Features of JAVA SE8
 
Java/Servlet/JSP/JDBC
Java/Servlet/JSP/JDBCJava/Servlet/JSP/JDBC
Java/Servlet/JSP/JDBC
 
Java 9 features
Java 9 featuresJava 9 features
Java 9 features
 
Java1
Java1Java1
Java1
 
Java
Java Java
Java
 
Panama.pdf
Panama.pdfPanama.pdf
Panama.pdf
 
Features java9
Features java9Features java9
Features java9
 
eXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework IntroductioneXo Platform SEA - Play Framework Introduction
eXo Platform SEA - Play Framework Introduction
 
Java 8
Java 8Java 8
Java 8
 
OBJECT ORIENTED PROGRAMMING LANGUAGE - SHORT NOTES
OBJECT ORIENTED PROGRAMMING LANGUAGE - SHORT NOTESOBJECT ORIENTED PROGRAMMING LANGUAGE - SHORT NOTES
OBJECT ORIENTED PROGRAMMING LANGUAGE - SHORT NOTES
 
Java2 platform
Java2 platformJava2 platform
Java2 platform
 
imperative programming language, java, android
imperative programming language, java, androidimperative programming language, java, android
imperative programming language, java, android
 
Java dev mar_2021_keynote
Java dev mar_2021_keynoteJava dev mar_2021_keynote
Java dev mar_2021_keynote
 
Javalecture 1
Javalecture 1Javalecture 1
Javalecture 1
 

More from Nicola Pedot

AI, ML e l'anello mancante
AI, ML e l'anello mancanteAI, ML e l'anello mancante
AI, ML e l'anello mancanteNicola Pedot
 
Say No To Dependency Hell
Say No To Dependency Hell Say No To Dependency Hell
Say No To Dependency Hell Nicola Pedot
 
Java al servizio della data science - Java developers' meeting
Java al servizio della data science - Java developers' meetingJava al servizio della data science - Java developers' meeting
Java al servizio della data science - Java developers' meetingNicola Pedot
 
Java 9-10 What's New
Java 9-10 What's NewJava 9-10 What's New
Java 9-10 What's NewNicola Pedot
 
Tom EE appunti devoxx2012
Tom EE   appunti devoxx2012 Tom EE   appunti devoxx2012
Tom EE appunti devoxx2012 Nicola Pedot
 
Presentazione+Android
Presentazione+AndroidPresentazione+Android
Presentazione+AndroidNicola Pedot
 

More from Nicola Pedot (11)

AI, ML e l'anello mancante
AI, ML e l'anello mancanteAI, ML e l'anello mancante
AI, ML e l'anello mancante
 
Ethic clean
Ethic cleanEthic clean
Ethic clean
 
Say No To Dependency Hell
Say No To Dependency Hell Say No To Dependency Hell
Say No To Dependency Hell
 
Java al servizio della data science - Java developers' meeting
Java al servizio della data science - Java developers' meetingJava al servizio della data science - Java developers' meeting
Java al servizio della data science - Java developers' meeting
 
Jakarta EE 2018
Jakarta EE 2018Jakarta EE 2018
Jakarta EE 2018
 
Lazy Java
Lazy JavaLazy Java
Lazy Java
 
Java 9-10 What's New
Java 9-10 What's NewJava 9-10 What's New
Java 9-10 What's New
 
Tom EE appunti devoxx2012
Tom EE   appunti devoxx2012 Tom EE   appunti devoxx2012
Tom EE appunti devoxx2012
 
Eclipse Svn
Eclipse SvnEclipse Svn
Eclipse Svn
 
Eclipse
EclipseEclipse
Eclipse
 
Presentazione+Android
Presentazione+AndroidPresentazione+Android
Presentazione+Android
 

Recently uploaded

A healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfA healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfMarharyta Nedzelska
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfAlina Yurenko
 
Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Velvetech LLC
 
Folding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesFolding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesPhilip Schwarz
 
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdfExploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdfkalichargn70th171
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Hr365.us smith
 
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024StefanoLambiase
 
Powering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsPowering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsSafe Software
 
Precise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalPrecise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalLionel Briand
 
How to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationHow to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationBradBedford3
 
SpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at RuntimeSpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at Runtimeandrehoraa
 
Sending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdfSending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdf31events.com
 
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Cizo Technology Services
 
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...confluent
 
Implementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureImplementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureDinusha Kumarasiri
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Matt Ray
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsAhmed Mohamed
 
CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceBrainSell Technologies
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfFerryKemperman
 

Recently uploaded (20)

Advantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your BusinessAdvantages of Odoo ERP 17 for Your Business
Advantages of Odoo ERP 17 for Your Business
 
A healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdfA healthy diet for your Java application Devoxx France.pdf
A healthy diet for your Java application Devoxx France.pdf
 
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdfGOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
GOING AOT WITH GRAALVM – DEVOXX GREECE.pdf
 
Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...Software Project Health Check: Best Practices and Techniques for Your Product...
Software Project Health Check: Best Practices and Techniques for Your Product...
 
Folding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a seriesFolding Cheat Sheet #4 - fourth in a series
Folding Cheat Sheet #4 - fourth in a series
 
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdfExploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
Exploring Selenium_Appium Frameworks for Seamless Integration with HeadSpin.pdf
 
Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)Recruitment Management Software Benefits (Infographic)
Recruitment Management Software Benefits (Infographic)
 
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
Dealing with Cultural Dispersion — Stefano Lambiase — ICSE-SEIS 2024
 
Powering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data StreamsPowering Real-Time Decisions with Continuous Data Streams
Powering Real-Time Decisions with Continuous Data Streams
 
Precise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive GoalPrecise and Complete Requirements? An Elusive Goal
Precise and Complete Requirements? An Elusive Goal
 
How to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion ApplicationHow to submit a standout Adobe Champion Application
How to submit a standout Adobe Champion Application
 
SpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at RuntimeSpotFlow: Tracking Method Calls and States at Runtime
SpotFlow: Tracking Method Calls and States at Runtime
 
Sending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdfSending Calendar Invites on SES and Calendarsnack.pdf
Sending Calendar Invites on SES and Calendarsnack.pdf
 
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
Global Identity Enrolment and Verification Pro Solution - Cizo Technology Ser...
 
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
Catch the Wave: SAP Event-Driven and Data Streaming for the Intelligence Ente...
 
Implementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with AzureImplementing Zero Trust strategy with Azure
Implementing Zero Trust strategy with Azure
 
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
Open Source Summit NA 2024: Open Source Cloud Costs - OpenCost's Impact on En...
 
Unveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML DiagramsUnveiling Design Patterns: A Visual Guide with UML Diagrams
Unveiling Design Patterns: A Visual Guide with UML Diagrams
 
CRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. SalesforceCRM Contender Series: HubSpot vs. Salesforce
CRM Contender Series: HubSpot vs. Salesforce
 
Introduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdfIntroduction Computer Science - Software Design.pdf
Introduction Computer Science - Software Design.pdf
 

Java 8 Overview

  • 1. Java 8 Good & Bad Overview by Nicola Pedot - 26 giugno 2014 https://creativecommons.org/licenses/by/3.0/it
  • 2. Status On 2014, Java is one of the most used programming language for client-server applications, with approximately 9 million developers. Oracle Java Versions: 6 archived 7 production ready (java.net) 8 for developers (java.com)
  • 4. Java 8 Parts Process Development Kit- JDK Virtual Machine VM Language Runtime Libraries - JRE Editions - JEE, JSE, JME, JEmbedded
  • 5. Java Community Process The JCP remains the governing body for all standard Java SE APIs and related interfaces. If a proposal accepted into this process intends to revise existing standard interfaces, or to define new ones, then a parallel effort to design, review, and approve those changes must be undertaken in the JCP, either as part of a Maintenance Review of an existing JSR or in the context of a new JSR.
  • 6. JDK Enhancement-Proposal JEP 1: JDK Enhancement-Proposal & Roadmap Process Author Mark Reinhold Organization Oracle Created 2011/6/23 Updated 2012/12/4 The primary goal of this process is to produce a regularly-updated list of proposals to serve as the long-term Roadmap for JDK Release Projects and related efforts. This process is open to every OpenJDK Committer. This process does not in any way supplant the Java Community Process.
  • 7. Java JDK - OpenJDK JDK 8 was the second part of "Plan B". The single driving feature of the release was Project Lambda. (Project Jigsaw was initially proposed for this release but later dropped). Additional features proposed via the JEP Process were included so long as they fit into the overall schedule required for Lambda. Detailed information on the features included in the release can be found on the features page. The source is open and avaliable on Mercurial repository.
  • 8. Java VM - HotSpot Below you will find the source code for the Java HotSpot virtual machine, the best Java virtual machine on the planet. The HotSpot code base has been worked on by dozens of people, over the course of 10 years, so far. (That's good and bad.) It's big. There are nearly 1500 C/C++ header and source files, comprising almost 250,000 lines of code. In addition to the expected class loader, bytecode interpreter, and supporting runtime routines, you get two runtime compilers from bytecode to native instructions, 3 (or so) garbage collectors, and a set of high-performance runtime libraries for synchronization, etc.
  • 9. Java 8 Hot Topics Default Methods Function Iterfaces (Closure, Lambda) or AntiScala Streams Parallel Javascript Nashorn Java Time SNI IPV6 Security
  • 10. Default methods Default methods enable you to add new functionality to the interfaces of your libraries and ensure binary compatibility with code written for older versions of those interfaces. Note: interfaces do not have any state
  • 11. Default method syntax public interface oldInterface { public void existingMethod(); default public void newDefaultMethod() { System.out.println("New default method" " is added in interface"); } } The following class will compile successfully in Java JDK 8,? public class oldInterfaceImpl implements oldInterface { public void existingMethod() { // existing implementation is here… } } If you create an instance of oldInterfaceImpl:? oldInterfaceImpl obj = new oldInterfaceImpl (); // print “New default method add in interface” obj.newDefaultMethod();
  • 12. Default method conflict java: class Impl inherits unrelated defaults for defaultMethod() from types InterfaceA and InterfaceB In order to fix this class, we need to provide default method implementation: public class Impl implements InterfaceA, InterfaceB { public void defaultMethod(){ // existing code here.. InterfaceA.super.defaultMethod(); } }
  • 13. Default method good The great thing about using interfaces instead of adapter classes is the ability to extend another class than the particular adapter. Simil multiple inheritance. Finally, library developers are able to evolve established APIs without introducing incompatibilities to their user's code.
  • 14. Default method bad In a nutshell, make sure to never override a default method in another interface. Neither with another default method, nor with an abstract method. Before Java 7, you would only need to look for the actually invoked code by traversing down a linear class hierarchy. Only add this complexity when you really feel it is absolutely necessary.
  • 15. Lambda: functional interface A functional interface is any interface that contains only one abstract method. (A functional interface may contain one or more default methods or static methods.)
  • 16. Lambda syntax //Prima: List list1 = Arrays.asList(1,2,3,5); for(Integer n: list1) { System.out.println(n); } //Dopo: List list2 = Arrays.asList(1,2,3,5); list2.forEach(n -> System.out.println(n));// default method forEach //Espressioni lambda e doppio due punti static method reference list2.forEach(System.out::println);
  • 17. Lambda syntax (2) // Anonymous class new CheckPerson() { public boolean test(Person p) { return p.getGender() == Person.Sex.MALE && p.getAge() >= 18 && p.getAge() <= 25; } } // Lambda (Person p) -> p.getGender() == Person.Sex.MALE && p.getAge() >= 18 && p.getAge() <= 25
  • 18. Good: Stream sample Map<Person.Sex, List<Person>> byGender = roster.stream().collect( Collectors.groupingBy(Person::getGender));
  • 19. Good: Parallel Stream sample ConcurrentMap<Person.Sex, List<Person>> byGender = roster.parallelStream().collect( Collectors.groupingByConcurrent(Person::getGender))
  • 20. Stream Bad Parts “Java 8 Streams API will be the single biggest source of new Stack Overflow questions.” With streams and functional thinking, we’ll run into a massive amount of new, subtle bugs. Few of these bugs can be prevented, except through practice and staying focused. You have to think about how to order your operations. You have to think about whether your streams may be infinite. [14]
  • 21. Stream Bad Parts (2) “If evaluation of one parallel stream results in a very long running task, this may be split into as many long running sub-tasks that will be distributed to each thread in the pool. From there, no other parallel stream can be processed because all threads will be occupied.” If a program is to be run inside a container, one must be very careful when using parallel streams. Never use the default pool in such a situation unless you know for sure that the container can handle it. In a Java EE container, do not use parallel streams. [15]
  • 22. Parallel Lang Tools: StampedLock The ReentrantReadWriteLock had a lot of shortcomings: It suffered from starvation. You could not upgrade a read lock into a write lock. There was no support for optimistic reads. Programmers "in the know" mostly avoided using them. StampedLock addresses all these shortcomings
  • 23. Parallel Lang Tools:Concurrent Adders Concurrent Adders: this is a new set of classes for managing counters written and read by multiple threads. The new API promises significant performance gains, while still keeping things simple and straightforward.
  • 24. Bad Part We’re paying the price for shorter, more concise code with more complex debugging, and longer synthetic call stacks.
  • 25. The Reason The reason is that while javac has been extended to support Lambda functions, the JVM still remains oblivious to them.
  • 26. Javascript Un nome per tutti: node.jar from Oracle
  • 27. JavaScript from Java package sample1; import javax.script.ScriptEngine; import javax.script.ScriptEngineManager; public class Hello { public static void main(String... args) throws Throwable { ScriptEngine engine = new ScriptEngineManager().getEngineByName("nashorn"); engine.eval("function sum(a, b) { return a + b; }"); System.out.println(engine.eval("sum(1, 2);")); engine.eval(new FileReader("src/sample1/greeter.js")); System.out.println(invocable.invokeFunction("greet", "Julien")); } }
  • 28. JavaScript DB Connection var someDatabaseFun = function() { var Properties = Java.type("java.util.Properties"); var Driver = Java.type("org.h2.Driver"); var driver = new Driver(); var properties = new Properties(); properties.setProperty("user", "sa"); properties.setProperty("password", ""); try { var conn = driver.connect( "jdbc:h2:~/test", properties); // Database code here } finally { try { if (conn) conn.close(); } catch (e) {} } } someDatabaseFun();
  • 29. JavaScript with JOOQ DSL.using(conn) .select( t.TABLE_SCHEMA, t.TABLE_NAME, count().as("CNT")) .from(t) .join(c) .on(row(t.TABLE_SCHEMA, t.TABLE_NAME) .eq(c.TABLE_SCHEMA, c.TABLE_NAME)) .groupBy(t.TABLE_SCHEMA, t.TABLE_NAME) .orderBy( t.TABLE_SCHEMA.asc(), t.TABLE_NAME.asc()) // continue in next slide
  • 30. JavaScript with stream DSL.using(conn) .select(...) // this is folded code. // This fetches a List<Map<String, Object>> as // your ResultSet representation .fetchMaps() // This is Java 8's standard Collection.stream() .stream() // And now, r is like any other JavaScript object // or record! .forEach(function (r) { print(r.TABLE_SCHEMA + '.' + r.TABLE_NAME + ' has ' + r.CNT + ' columns.'); });
  • 31. Javascript Problem In this case the bytecode code is dynamically generated at runtime using a nested tree of Lambda expressions. There is very little correlation between our source code, and the resulting bytecode executed by the JVM. The call stack is now two orders of magnitude longer.
  • 32. The Hard Side Haskell is good at preventing bugs. Java without lambda has readable stacktrace. In Groovy is harder reading exceptions, Java8 Lambda is also harder, Javascript is even harder.
  • 33. JavaTime, JodaTime’s revenge ● The Calendar class was not type safe. ● Because the classes were mutable, they could not be used in multithreaded applications. ● Bugs in application code were common due to the unusual numbering of months and the lack of type safety.
  • 34. JodaTime syntax import java.time.Instant; Instant timestamp = Instant.now(); This class format follows the ISO-8601 2013-05-30T23:38:23.085Z Come gestire le vecchie date? Date.toInstant() public static Date from(Instant instant) Calendar.toInstant() Other classes Clock, Period,...
  • 35. SNI IPV6 Assigning a separate IP address for each site increases the cost of hosting since requests for IP addresses must be justified to the regional internet registry and IPv4 addresses are now in short supply. An extension to TLS called Server Name Indication (SNI) addresses this issue by sending the name of the virtual domain as part of the TLS negotiation. <<Wikipedia>> E’ possibile configurare in un webserver più virtual host con diversi certificati SSL utilizzando un solo indirizzo IP. provocazione...in vista dell’esaurimento di IP di InternetOfThings…. Java Everywhere?
  • 36. Security java.security.SecureRandom This class provides a cryptographically strong random number generator (RNG).
  • 37. Others... 1. Process termination Process destroyForcibly(); isAlive(); waitFor(long timeout, TimeUnit unit); 2. Optional Values String name = computer.flatMap(Computer::getSoundcard) .flatMap(Soundcard::getUSB) .map(USB::getVersion) .orElse("UNKNOWN"); 3. Annotate Anything Type Annotations are annotations that can be placed anywhere you use a type. This includes the new operator, type casts, implements clauses and throws clauses
  • 38. Others… (2) 4. Directory Walking Interface DirectoryStream<T> extends Iterator default void forEach(Consumer<? super T> action) default Spliterator<T> spliterator()
  • 39. New Domains Java started simple by design, now it has to gain complexity to model new domains. from Static Object Orienteed to ->(functional) Parallel Event Orienteed ->(dynamic) Syntax & Check relaxed == More fun & more dangerous times ahead!
  • 40. from Java8 to Java9 from…. Enterprise Edition Standard Edition Embedded Edition Mobile Edition …. to Java9 complete module system
  • 41. Compact Profiles Java Compact Profiles, A reasonably configured Java SE-Embedded 8 for ARMv5/Linux compact1 profile comes in at less than 14MB compact2 is about 18MB and compact3 is in the neighborhood of 21MB. For reference, the Java SE-Embedded 7u21 Linux environment requires 45MB.
  • 42. Links 1. http://www.dzone.com/links/r/the_bad_parts_of_lambdas_in_java_8.html 2. http://docs.oracle.com/javase/tutorial/java/javaOO/lambdaexpressions.html 3. http://www.javacodegeeks.com/2014/04/15-must-read-java-8-tutorials.html 4. http://www.oracle.com/events/us/en/java8/index.html?msgid=3-9911533944 5. http://typesafe.com/blog/reactive-programming-patterns-in-akka-using-java-8 6. http://java.dzone.com/articles/java-8-will-revolutionize 7. http://openjdk.java.net/jeps/117 8. http://hg.openjdk.java.net/jdk8 9. http://it.wikipedia.org/wiki/Java_%28linguaggio_di_programmazione%29 10. http://java.dzone.com/articles/5-features-java-8-will-change 11. http://java.dzone.com/articles/10-features-java-8-you-havent 12. http://java.dzone.com/articles/java-lambda-expressions-vs 13. http://java.dzone.com/articles/java-8-default-methods-can 14. http://blog.informatech.cr/2013/03/11/java-infinite-streams/ 15. http://java.dzone.com/articles/whats-wrong-java-8-part-iii