08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
Java EE8 - by Kito Mann
1. Java EE 8
Why We Need to Take Action to
Move Forward
Kito D. Mann
Virtua, Inc.
2. Kito D. Mann
@kito99
• Principal Consultant at Virtua (http://virtua.tech)
• Training, consulting, architecture, mentoring
• PrimeFaces, JSF, Java EE, Polymer, Web
Components, Liferay, etc.
• Official US PrimeFaces partner
• Author, JavaServer Faces in Action
• Founder, JSF Central (http://www.jsfcentral.com)
3. Kito D. Mann
@kito99
• Co-host, Enterprise Java Newscast
• http://enterprisejavanews.com
• Internationally recognized speaker
• JavaOne, JavaZone, Devoxx, Devnexus,
NFJS, etc.
• JCP Member
• JSF, MVC, JSF Portlet Bridge, Portlets
4. Agenda
• Overview of the specifications that are part of
Java EE 8, provide current status
• Examples of Proposed Enhancements and New
Features
• What the current status of Java EE 8 progress is
and what you can do to help
5. The Importance of Java
EE to the Ecosystem
https://javaee-guardians.io/java-ee-adoption-surveys
8. Java EE
Past, Present, Future
J2EE 1.2
Servlet,
JSP, EJB,
JMS, RMI
J2EE 1.3
CMP,
JCA
J2EE 1.4
Web
Services,
Mgmt,
Deplymnt
Java EE 5
Ease of
Use,
EJB 3,
JPA, JSF,
JAXB,
JAX-WS
Java EE 6
Pruning,
Ease of Use,
JAX-RS,
CDI,
Bean-
Validation
Servlet 3,
EJB 3.1 Lite
Java EE 7
JMS 2, Batch,
TX,
Concurrency,
Web-Sockets,
JSON
Java EE 8
SERVLET 4,
JSON-B,
JSON-P 1.1,
JSF 2.3, CDI
2.0, JAX-RS
2.1,
SECURITY,
MVC,
MANAGEMENT
9. Java EE Past, Present, &
Future
J2EE 1.3
CMP,
JCA
J2EE 1.4
Web
Services,
Mgmt,
Deplymnt
Java EE 5
Ease of
Use,
EJB 3,
JPA, JSF,
JAXB,
JAX-WS
Java EE 6
Pruning,
Ease of
Use,
JAX-RS,
CDI,
Bean-
Validation
Servlet 3,
EJB 3.1
Lite
Java EE 7
JMS 2,
Batch, TX,
Concurr,
Web-
Sockets,
JSON
JAX-RS 2
JAX-RPC, CMP/
BMP, JSR 88
J2EE 1.2
Servlet,
JSP, EJB,
JMS, RMI
10. Java EE Past, Present, &
Future
Java EE 5
Ease of
Use,
EJB 3,
JPA, JSF,
JAXB,
JAX-WS
Java EE 6
Pruning,
Ease of
Use,
JAX-RS,
CDI,
Bean-
Validation
Web Profile
Servlet 3,
EJB 3.1
Lite
Java EE 7
JMS 2,
Batch, TX,
Concurr,
Web-
Sockets,
JSON
Web Profile
JAX-RS 2
JAX-RPC, CMP/
BMP, JSR 88
J2EE 1.3
CMP,
JCA
J2EE 1.4
Web
Services,
Mgmt,
Deplymnt
J2EE 1.2
Servlet,
JSP, EJB,
JMS, RMI
11. Java EE Past, Present, &
Future
J2EE 1.3
CMP,
JCA
J2EE 1.4
Web
Services,
Mgmt,
Deplymnt
Java EE 5
Ease of
Use,
EJB 3,
JPA, JSF,
JAXB,
JAX-WS
Java EE 6
Pruning,
Ease of
Use,
JAX-RS,
CDI,
Bean-
Validation
Web Profile
Servlet 3,
EJB 3.1
Lite
Java EE 7
JMS 2,
Batch, TX,
Concurr,
Web-
Sockets,
JSON
JAX-RS 2
JAX-RPC, CMP/
BMP, JSR 88
J2EE 1.2
Servlet,
JSP, EJB,
JMS, RMI
12. Java EE Past, Present, &
Future
J2EE 1.3
CMP,
JCA
J2EE 1.4
Web
Services,
Mgmt,
Deplymnt
Java EE 5
Ease of
Use,
EJB 3,
JPA, JSF,
JAXB,
JAX-WS
Java EE 6
Pruning,
Ease of
Use,
JAX-RS,
CDI,
Bean-
Validation
Web Profile
Servlet 3,
EJB 3.1
Lite
Java EE 7
JMS 2,
Batch, TX,
Concurr,
Web-
Sockets,
JSON
Web Profile
JAX-RS 2
JAX-RPC, CMP/
BMP, JSR 88
J2EE 1.2
Servlet,
JSP, EJB,
JMS, RMI
13. Java EE 8 Community Survey
https://java.net/downloads/javaee-spec/JavaEE8_Community_Survey_Results.pdf
https://blogs.oracle.com/ldemichiel/entry/results_from_the_java_ee
14. Java EE 8: Original
Plan
• Continued Enhancements for Web Standards
Alignment
• HTTP2, JSON Binding, JSON-P, MVC
• Cloud enhancements
• Security, RESTful Management API
• CDI Programming Model
• Ease of use, EJB via CDI
• Smaller, but Important Features
• Caching, Better Messaging
• Alignment with Java SE 8
17. Java EE 9: New Proposal
Expected release: Q4 2018
• Increased focus on microservices and cloud
• Proposed new features:
• Multi-tenancy
• Circuit-breaker
• Reactive programming support
19. Servlet 4.0
• Principal goal to support HTTP 2
• Modernization of internet protocol
• Boost web performance
• Early Draft has been published
• Join mailing list or follow expert group (JSR 369)
• Keep tabs on Ed Burns’ presentations, although
not anything new since JavaOne 2015
20. Servlet 4.0
• HTTP 2 Support -> Major Update
• Why do we need HTTP 2?
• Problems with HTTP 1.1
• Head-of-Line Blocking
• HTTP Pipelining, File Concatenation, &
Image Sprites
22. Servlet 4.0
Exposing HTTP 2
• Stream Prioritization
• New class Priority
• Enhance HttpServletRequest and
HttpServletResponse to accommodate
• Server Push
• Not replacing WebSockets
23. Servlet 4.0
Newer HttpClient API (Java SE
9)
• Plans to provide easy to use API
• Support both HTTP/1.1 and 2
• Builds on existing Java API Classes
24. JMS 2.1
(Proposed for Removal)
• JSR 368 - In early stages
• No builds available for testing, as yet.
• Planning: https://java.net/projects/jms-
spec/pages/JMS21Planning
25. JMS 2.1
• JMS 2.0 was a major overhaul
• Continuation of API Modernization
• Declarative Message Listeners
• Alternative to MDB
• More Powerful Features
• Available to all Beans
26. JMS 2.1
• JMS Provider Portability Improvements
• Dead Message Queues
• Redelivery Behavior on JMS MDB Rollback
(delays, max # consecutive)
29. JAX-RS 2.1
• JSR 370 - In Early Stages
• No builds available for testing
• Follow JSR-370 EG and Mailing Lists
30. JAX-RS 2.1
• Hypermedia API
• Reactive API
• Security API
• Support for SSE (Server Sent Events)
• Improved CDI Integration
• Support for Non-Blocking IO in Providers
31. JAX-RS 2.1
• Conditional JAXB on Runtimes
• Integration with JSON-B
• Support for CDI in Java SE
32. JSF 2.3
• JSR 372 - in active progress
• Milestones available for testing
• Read, Test, Supply Feedback
35. JSF 2.3
Enhanced CDI Integration
• Wider Support of Injection into JSF Artifacts
• javax.faces.convert.Converter
• javax.faces.validator.Validator
• javax.faces.component.behavior.Behavior
• Upgraded to CDI qualifiers
36. CDI 2.0
• JSR 365 - in active progress
• Test Releases of Reference Implementation
(Weld 3.0.0 Alphas)
• http://weld.cdi-spec.org/news/
• Follow the Expert Group
37. CDI 2.0
• Java SE Bootstrap
• XML Configuration
• Asynchronous Events@S@tar
• @Startup for CDI Beans
• Portable Extension SPI Simplification
• Small features and enhancements
39. CDI 2.0
@Schedule Outside EJB
@ApplicationScoped
public class MyScheduledBean {
...
@Schedule(...)
public void myScheduledTask() { ... }
}
@ApplicationScoped
@Stereotype
@Retention(RUNTIME)
@Target(TYPE)
@Schedule(...)
public @interface MonthlyTask {}
40. JSON-P 1.1
• JSR 374 - In Early Draft Review
• More Information:
• https://json-processing-spec.java.net/
• Sources: https://java.net/projects/jsonp
41. JSON-P 1.1
• Updates to new API in Java EE 7
• New JSON Standards
• JSON-Pointer and JSON-Patch
• Editing Operations on JSON objects and arrays
• Helper Classes and Enhanced Java SE 8
support
42. JSON-P 1.1
Java SE 8 Support
• Stream Support
JsonArray persons;
persons.getValuesAs(JsonObject.class).stream()
.filter(x->x.getString(“age”) >= 65)
.forEach(System.out.println(x.getString(“name”)));
44. JSON-P 1.1
JSON-Patch
public void shouldBuildJsonPatchExpressionUsingJsonPatchBuilder() {
JsonPatchBuilder patchBuilder = new JsonPatchBuilder();
JsonObject result = patchBuilder.add("/email”,
"john@example.com").replace("/age", 30)
.remove("/phoneNumber”)
.test("/firstName", "John”)
.copy("/address/lastName", "/lastName”)
.apply(buildPerson());
}
45. Java EE Management API
2.0
(Proposed for Removal)
• Currently working on Early Draft
• Join mailing list of JSR 373
46. Java EE Management API
2.0
• REST Based Interface to Supersede EJB
Management APIs of JSR 77
• Monitoring and deployment as well
• SSE for Event Support (WebSockets also under
consideration)
48. MVC
(Proposed for Removal)
• Model - View - Controller
• JSR 371
• Active Progress…download milestones
• Ozark: https://ozark.java.net/
49. MVC
• Action-Based Web Framework for Java EE
• Follows suit of Spring MVC or Apache Struts
• Does Not Replace JSF
• Model: CDI, Bean Validation, JPA
• View: Facelets, JSP (Extensible)
• Controller: Layered on top of JAX-RS
52. JSON-B
• Java API for JSON Binding
• JSR 367 - Public Review
• Read the spec, start testing:
https://java.net/projects/jsonb-spec/pages/Home
53. JSON-B
• Standardize means of converting JSON to Java
objects and vice versa
• Default mapping algorithm for converting Java
classes
• Draw from best of breed ideas in existing JSON
binding solutions
• Provide JAX-RS a standard way to support
“application/json” for POJOs
• JAX-RS currently supports JSON-P
54. JSON-B
Mapping
@Entity public class Person {
@Id String name;
String gender;
@ElementCollection
Map<String, String> phones;
...
}
Person duke = new Person();
duke.setName("Duke");
duke.setGender("Male");
phones = new HashMap<>();
phones.put("home", "650-123-4567");
phones.put("mobile",
"650-234-5678");
duke.setPhones(phones);
{
"name":"Duke",
"gender":"Male",
"phones":{
"home":"650-123-4567",
"mobile":"650-234-5678"
}
}
55. JSON-B
Proposed API - Custom Mapping
• Utilization of annotations to map fields to JSON
Document Elements
{
poolType : “Inground”,
}
@JsonProperty(“poolType”)
public String poolType;
{
poolType : “Inground”,
shape : “Rectangle”
}
@JsonPropertyOrder(“poolType”,
”shape”)
public class Pool(){
public String poolType;
public String shape;
…
}
56. Java EE Security
• JSR 365
• Early Draft Development
• Improve Java EE platform by ensuring that the
security API is useful in the modern cloud/PaaS
paradigm
• Simplify, standardize, modernize
• Promotes modern concepts (EL and CDI)
57. Java EE Security
• Simple security providers
• Easy pluggability and mapping
• Enabling Existing Security Annotations for all
beans
58. Java EE Security
Proposed Security Provider
@SecurityProvider
public class MySecurityProvider {
@Inject UserService userService;
@OnAuthentication
// The parameters could suit the credentials mechanism being
used.
public Principal getPrincipal(String username, String password) {
// Construct the principal using the user service.
}
@OnAuthorization
public String[] getRoles (Principal principal) {
// Construct an array of roles using the principal and user
service.
}
}
59. Java EE Security
• Proposed Idea Examples:
• https://github.com/javaee-security-spec/javaee-
security-proposals
60. JCache
• Java Temporary Caching API
• JSR 107 - Started in 2001
• Finished in 2014
• Provides a common way for Java applications to
create, access, update, and remove entries from
caches
61. JCache
• Provide applications with caching
functionality…particularly the ability to cache Java
objects
• Define common set of caching concepts & facilities
• Minimize learning curve
• Maximize portability
• Support in-process and distributed cache
implementations
62. JCache
• Unknown status...not mentioned in the Oracle
update
• Make use of JCache with some application servers
now with CDI
63. Health Checking
• Newly proposed specification, geared towards
monitoring the health of microservices
• Client-side standard
• Automatic, periodic, and self-monitoring
• Possibly statistics
64. Configuration
• Standard for externalizing configuration
• Aimed at cloud based environments
• Provide the ability to change one or more
configurations that are independent/decoupled of
apps...multiple configuration files
• Unified API for accessing configuration in many
different environments
• Layering and Overrides
66. Java EE 8 Timeline
Q4 2014
Expert Groups
Q4 2015
Early
Draft
Q1 2016
Public
Review
Q3 2016
Proposed Final
Draft
H2
2017?
Final
Release
Java
EE.Next
67. Java EE 8:
Take Action
• Start working with Java EE 8 today
• Tools:
• GlassFish v4.1, Payara 5 Branch
• Milestones
• Examples and Specification Docs
68. Adopt-A-JSR
• Started in 2007, easy way for JUGs to get
involved
• What you can do depends upon what you want
to do & what spec leads are looking for