The path to CDI 2.0 
@antoine_sd
Antoine Sabot-Durand 
Senior Software Engineer @Red Hat 
Java & OSS : 
CDI co-spec lead 
CDI community development 
Tech Lead on Agorava 
@antoine_sd
Agenda 
Flashback on CDI 1.0, 1.1 and 1.2 
Gathering feedback for CDI 2.0 
CDI 2.0 new features 
CDI 2.0 needs you
CDI 2.0 started one month ago 
JSR 365 was the first Java EE 8 JSR proposed and voted 
Expert Group is still in formation 
We have a lot of community momentum 
All contribution are accepted
Previously on CDI
CDI Timeline 
CDI 1.0 (Java EE 6) 
CDI 1.1 (Java EE 7) 
CDI 1.2 (1.1 MR) 
CDI 2.0 Starts 
Dec 2009 June 2013 Apr 2014 Sep 2014 
CDI 2.0 released 
2016
CDI 1.0 - December 2009 
A well-defined lifecycle for stateful objects bound to lifecycle contexts, where the 
set of contexts is extensible 
A sophisticated, typesafe dependency injection mechanism, including the ability to 
select dependencies at either development or deployment time, without verbose 
configuration 
The ability to decorate or to associate interceptors to objects with a typlsafve 
approach 
An event notification model 
An SPI allowing portable extensions to integrate cleanly with the container
CDI 1.1 - April 2013 
Add automatic enablement of CDI for beans with a scope annotation, and EJBs, in Java EE 
Add more introspection with event, bean, Decorator and interceptor meta data 
Ease access to bean manager from outside CDI with CDI class 
Moved interceptor binding to interceptors spec, allowing for reuse by other specifications 
Add global enablement of interceptors (see the Java Interceptors Specification 1.2), global enablement 
of decorators and alternatives, using the @Priority annotation 
Add scope activation and destruction callback events 
Add AlterableContext allowing bean instances to be explicitly destroyed 
Add Unmanaged allowing easy access to non-contexutal instances of beans
CDI 1.2 - April 2014 
Clarification in the spec regarding: 
CDI Lifecycle 
Events 
Reworking Bean defining annotation to avoid conflict with other JSR 330 
frameworks 
Clarification on conversation resolution 
OSGi official support in the API
Gathering feedback for CDI 2.0
Different sources 
Survey 
Jira requests 
For mer EG 
Feedback 
Other specs feedback
CDI 2.0 survey
About this survey… 
There was a survey before the survey 
Between May 28th and June 30th 
260 participants 
3 « demography » question 
20 new features to rate (from 1 to 5)
Who answered? 
I'm a developer using CDI on my projects 
I'm an advanced developer extending CDI on my projects 
I'm developing a framework based on CDI
CDI version they’re using 
CDI 1.0 CDI 1.1 CDI 1.2
What are their usage? 
Plain Java EE Servlet container Java SE
Results 1/2 
Features from most to less wanted av. rating 
Asynchronous method invocation 4,04 
Add asynchronous event support * 4,00 
@Startup for CDI 3,92 
Bootstrapping the container outside Java EE * 3,90 
AOP for produced or custom beans * 3,65 
Mutable container at runtime * 3,62 
Security support 3,61 
Observers ordering * 3,53 
Better event control 3,50 
Enhance SPI to give better access to all metadata 3,41
Results 2/2 
Feature from most to less wanted av. rating 
Better EAR support 3,32 
Helpers to manipulate and build CDI metadata 3,32 
An easier way to create AnnotationLiteral (and TypeLiteral) 3,27 
Context SPI easily pluggable by the container 3,24 
Configuration file 3,17 
CDI parts * 3,12 
Enhance SPI to retrieve Bean from its instances 3,1 
JMX support 3,07 
Introduce CDI Lite. * 2,78 
Aligment with portlet 3.0 2,02
CDI 2.0 new features
The path to cdi 2.0
Modularity 
Provide sub specs in CDI (called parts) that can be used independently 
Each part should have an implementation
Modularity - Why ? 
We want to add new features to CDI without making it a bloated spec 
Having parts will help CDI adoption. Third party won’t have to get the whole 
spec if they don’t want to
Modularity - What parts ? 
Right now we are thinking of 3 parts : 
CDI Light : DI without events, contexts, AOP and SPI 
Providing CDI for mobile / constrained platform 
Events : bring the event bus out of DI 
Full CDI
Modularity - challenges 
Be sure of the parts - too much or not enough granularity 
Having an RI and TCK for each part can become huge work
Java SE support 
using CDI outside Java EE
Java SE support - Why? 
To provide a mean of building new stacks out of Java EE 
To boost CDI adoption for Spec working already on Java SE
Java SE support - challenges 
Extract “Java EE” features across the spec to create a chapter dedicated to it 
Decide what existing SE support we standardise 
Add SPI for CDI integration with other framework / spec
Enhancing events 
Asynchronous events 
Event ordering 
Event Range (war, ear, server, cluster)
AOP enhancement 
Support AOP on custom or produced bean 
Improve interceptor chaining 
Support AOP on inner calls
SPI and contexts enhancement 
Better access to all meta data created by CDI 
Provide a way to add bean at runtime 
Contexts enhancement for third party Spec 
Contexts not only based on thread approach
CDI 2.0 needs you 
CDI 2.0 specification is open to everyone 
Come on join us on the mailing list and IRC channel 
All infos on http://cdi-spec.org or by following to @cdispec on twitter 
The more we are the more we’ll deliver
Questions ?

More Related Content

PDF
CDI 2.0 is coming
PDF
Advanced CDI in live coding
PDF
Apache Deltaspike the CDI Toolbox (Java One 2015)
PDF
CDI 2.0 is upon us Devoxx
PDF
CDI 2.0 is coming
PDF
Adopt a JSR: CDI 2.0 at Devoxx UK
PDF
CDI 1.1 university
PDF
CDI In Real Life
CDI 2.0 is coming
Advanced CDI in live coding
Apache Deltaspike the CDI Toolbox (Java One 2015)
CDI 2.0 is upon us Devoxx
CDI 2.0 is coming
Adopt a JSR: CDI 2.0 at Devoxx UK
CDI 1.1 university
CDI In Real Life

What's hot (20)

PDF
New York Kubernetes: CI/CD Patterns for Kubernetes
KEY
Scala on androids
PDF
Binary Authorization in Kubernetes
PDF
Software Supply Chain Management with Grafeas and Kritis
PDF
Software Supply Chain Management with Grafeas and Kritis
PPTX
OpenDDR and Jakarta MVC - JavaLand 2021
PDF
DevNexus 2019: MicroProfile and Jakarta EE - What's Next?
PDF
Let your tests drive your code
PDF
AOTB2014: Agile Testing on the Java Platform
KEY
OSGi, Eclipse and API Tooling
PDF
OpenDaylight Developers Experience 1.5: Eclipse Setup, HOT reload, future plans
PDF
Implementing Microservices with Jakarta EE and MicroProfile
PDF
Professional iOS development
PDF
JavaEE & GlassFish UG - Digital JavaEE 7 New & Noteworthy by P.Pilgrim
PDF
Automated Virtualized Testing (AVT) with Docker, Kubernetes, WireMock and Gat...
PDF
The DevSecOps Builder’s Guide to the CI/CD Pipeline
PDF
Continuous Integration on my work
PDF
Preventing Supply Chain Attacks on Open Source Software
PDF
Hands on React Native: From Zero to Hero
PDF
OpenAPI Generator The Babel Fish of The API World - apidays Live Paris
New York Kubernetes: CI/CD Patterns for Kubernetes
Scala on androids
Binary Authorization in Kubernetes
Software Supply Chain Management with Grafeas and Kritis
Software Supply Chain Management with Grafeas and Kritis
OpenDDR and Jakarta MVC - JavaLand 2021
DevNexus 2019: MicroProfile and Jakarta EE - What's Next?
Let your tests drive your code
AOTB2014: Agile Testing on the Java Platform
OSGi, Eclipse and API Tooling
OpenDaylight Developers Experience 1.5: Eclipse Setup, HOT reload, future plans
Implementing Microservices with Jakarta EE and MicroProfile
Professional iOS development
JavaEE & GlassFish UG - Digital JavaEE 7 New & Noteworthy by P.Pilgrim
Automated Virtualized Testing (AVT) with Docker, Kubernetes, WireMock and Gat...
The DevSecOps Builder’s Guide to the CI/CD Pipeline
Continuous Integration on my work
Preventing Supply Chain Attacks on Open Source Software
Hands on React Native: From Zero to Hero
OpenAPI Generator The Babel Fish of The API World - apidays Live Paris
Ad

Viewers also liked (16)

PDF
Invoke dynamite in Java EE with invoke dynamic
PDF
Going further with CDI 1.2
PDF
Apache DeltaSpike the CDI toolbox
PDF
Introduction to cdi given at java one 2014
PDF
Mute Java EE DNA with CDI
PDF
Extending Java EE with CDI and JBoss Forge
PDF
Java EE, un ami qui vous veut du bien
PDF
CDI 2.0 Deep Dive
PDF
The Magnificent java EE 7 in Wildfly-O-Rama
PDF
Devoxx Java Social and Agorava
PDF
Fais ce que tu veux avec Java EE - Devoxx France 2014
PPTX
Electronic governance steps in the right direction?
PDF
Architecting Large Enterprise Projects @DevConf.CZ
PDF
Kids computer-programming
PDF
Java 8, Streams & Collectors, patterns, performances and parallelization
KEY
CDI mis en pratique avec Seam Social et Weld OSGI
Invoke dynamite in Java EE with invoke dynamic
Going further with CDI 1.2
Apache DeltaSpike the CDI toolbox
Introduction to cdi given at java one 2014
Mute Java EE DNA with CDI
Extending Java EE with CDI and JBoss Forge
Java EE, un ami qui vous veut du bien
CDI 2.0 Deep Dive
The Magnificent java EE 7 in Wildfly-O-Rama
Devoxx Java Social and Agorava
Fais ce que tu veux avec Java EE - Devoxx France 2014
Electronic governance steps in the right direction?
Architecting Large Enterprise Projects @DevConf.CZ
Kids computer-programming
Java 8, Streams & Collectors, patterns, performances and parallelization
CDI mis en pratique avec Seam Social et Weld OSGI
Ad

Similar to The path to cdi 2.0 (20)

PDF
3/3 : The path to CDI 2.0 - Antoine Sabot-Durand
PDF
CDI Best Practices with Real-Life Examples - TUT3287
PDF
EJB and CDI - Alignment and Strategy
PDF
CDI Integration in OSGi - Emily Jiang
PDF
Moving to Java EE 6 and CDI and away from the clutter
PDF
Developing Modern Java Web Applications with Java EE 7 and AngularJS
PDF
Contextual Dependency Injection for Apachecon 2010
PDF
CDI 2.0 (JSR 365) - Java Day Tokyo 2017 (English)
PDF
2015 JavaOne EJB/CDI Alignment
PDF
2015 JavaOne EJB/CDI Alignment
PDF
Designing Java EE Applications in the Age of CDI
PDF
2/3 : CDI advanced - Antoine Sabot-Durand
PPTX
Context and Dependency Injection 2.0
PPT
Cdi demo
PDF
Java EE 8: On the Horizon
PPT
Contexts and Dependency Injection for the JavaEE platform
PDF
MyFaces CODI and JBoss Seam3 become Apache DeltaSpike
PPTX
Java EE vs Spring Framework
PDF
CDI, Weld and the future of Seam
3/3 : The path to CDI 2.0 - Antoine Sabot-Durand
CDI Best Practices with Real-Life Examples - TUT3287
EJB and CDI - Alignment and Strategy
CDI Integration in OSGi - Emily Jiang
Moving to Java EE 6 and CDI and away from the clutter
Developing Modern Java Web Applications with Java EE 7 and AngularJS
Contextual Dependency Injection for Apachecon 2010
CDI 2.0 (JSR 365) - Java Day Tokyo 2017 (English)
2015 JavaOne EJB/CDI Alignment
2015 JavaOne EJB/CDI Alignment
Designing Java EE Applications in the Age of CDI
2/3 : CDI advanced - Antoine Sabot-Durand
Context and Dependency Injection 2.0
Cdi demo
Java EE 8: On the Horizon
Contexts and Dependency Injection for the JavaEE platform
MyFaces CODI and JBoss Seam3 become Apache DeltaSpike
Java EE vs Spring Framework
CDI, Weld and the future of Seam

Recently uploaded (20)

PPTX
Cybersecurity: Protecting the Digital World
PPTX
Trending Python Topics for Data Visualization in 2025
PDF
Autodesk AutoCAD Crack Free Download 2025
PDF
Practical Indispensable Project Management Tips for Delivering Successful Exp...
PPTX
Advanced SystemCare Ultimate Crack + Portable (2025)
PPTX
Matchmaking for JVMs: How to Pick the Perfect GC Partner
PDF
Top 10 Software Development Trends to Watch in 2025 🚀.pdf
PDF
CCleaner 6.39.11548 Crack 2025 License Key
PDF
E-Commerce Website Development Companyin india
PDF
iTop VPN Crack Latest Version Full Key 2025
PDF
DNT Brochure 2025 – ISV Solutions @ D365
PPTX
MLforCyber_MLDataSetsandFeatures_Presentation.pptx
PDF
Microsoft Office 365 Crack Download Free
PPTX
Airline CRS | Airline CRS Systems | CRS System
PDF
DuckDuckGo Private Browser Premium APK for Android Crack Latest 2025
PDF
Ableton Live Suite for MacOS Crack Full Download (Latest 2025)
PDF
AI Guide for Business Growth - Arna Softech
PDF
The Dynamic Duo Transforming Financial Accounting Systems Through Modern Expe...
PPTX
Cybersecurity-and-Fraud-Protecting-Your-Digital-Life.pptx
PPTX
most interesting chapter in the world ppt
Cybersecurity: Protecting the Digital World
Trending Python Topics for Data Visualization in 2025
Autodesk AutoCAD Crack Free Download 2025
Practical Indispensable Project Management Tips for Delivering Successful Exp...
Advanced SystemCare Ultimate Crack + Portable (2025)
Matchmaking for JVMs: How to Pick the Perfect GC Partner
Top 10 Software Development Trends to Watch in 2025 🚀.pdf
CCleaner 6.39.11548 Crack 2025 License Key
E-Commerce Website Development Companyin india
iTop VPN Crack Latest Version Full Key 2025
DNT Brochure 2025 – ISV Solutions @ D365
MLforCyber_MLDataSetsandFeatures_Presentation.pptx
Microsoft Office 365 Crack Download Free
Airline CRS | Airline CRS Systems | CRS System
DuckDuckGo Private Browser Premium APK for Android Crack Latest 2025
Ableton Live Suite for MacOS Crack Full Download (Latest 2025)
AI Guide for Business Growth - Arna Softech
The Dynamic Duo Transforming Financial Accounting Systems Through Modern Expe...
Cybersecurity-and-Fraud-Protecting-Your-Digital-Life.pptx
most interesting chapter in the world ppt

The path to cdi 2.0

  • 1. The path to CDI 2.0 @antoine_sd
  • 2. Antoine Sabot-Durand Senior Software Engineer @Red Hat Java & OSS : CDI co-spec lead CDI community development Tech Lead on Agorava @antoine_sd
  • 3. Agenda Flashback on CDI 1.0, 1.1 and 1.2 Gathering feedback for CDI 2.0 CDI 2.0 new features CDI 2.0 needs you
  • 4. CDI 2.0 started one month ago JSR 365 was the first Java EE 8 JSR proposed and voted Expert Group is still in formation We have a lot of community momentum All contribution are accepted
  • 6. CDI Timeline CDI 1.0 (Java EE 6) CDI 1.1 (Java EE 7) CDI 1.2 (1.1 MR) CDI 2.0 Starts Dec 2009 June 2013 Apr 2014 Sep 2014 CDI 2.0 released 2016
  • 7. CDI 1.0 - December 2009 A well-defined lifecycle for stateful objects bound to lifecycle contexts, where the set of contexts is extensible A sophisticated, typesafe dependency injection mechanism, including the ability to select dependencies at either development or deployment time, without verbose configuration The ability to decorate or to associate interceptors to objects with a typlsafve approach An event notification model An SPI allowing portable extensions to integrate cleanly with the container
  • 8. CDI 1.1 - April 2013 Add automatic enablement of CDI for beans with a scope annotation, and EJBs, in Java EE Add more introspection with event, bean, Decorator and interceptor meta data Ease access to bean manager from outside CDI with CDI class Moved interceptor binding to interceptors spec, allowing for reuse by other specifications Add global enablement of interceptors (see the Java Interceptors Specification 1.2), global enablement of decorators and alternatives, using the @Priority annotation Add scope activation and destruction callback events Add AlterableContext allowing bean instances to be explicitly destroyed Add Unmanaged allowing easy access to non-contexutal instances of beans
  • 9. CDI 1.2 - April 2014 Clarification in the spec regarding: CDI Lifecycle Events Reworking Bean defining annotation to avoid conflict with other JSR 330 frameworks Clarification on conversation resolution OSGi official support in the API
  • 11. Different sources Survey Jira requests For mer EG Feedback Other specs feedback
  • 13. About this survey… There was a survey before the survey Between May 28th and June 30th 260 participants 3 « demography » question 20 new features to rate (from 1 to 5)
  • 14. Who answered? I'm a developer using CDI on my projects I'm an advanced developer extending CDI on my projects I'm developing a framework based on CDI
  • 15. CDI version they’re using CDI 1.0 CDI 1.1 CDI 1.2
  • 16. What are their usage? Plain Java EE Servlet container Java SE
  • 17. Results 1/2 Features from most to less wanted av. rating Asynchronous method invocation 4,04 Add asynchronous event support * 4,00 @Startup for CDI 3,92 Bootstrapping the container outside Java EE * 3,90 AOP for produced or custom beans * 3,65 Mutable container at runtime * 3,62 Security support 3,61 Observers ordering * 3,53 Better event control 3,50 Enhance SPI to give better access to all metadata 3,41
  • 18. Results 2/2 Feature from most to less wanted av. rating Better EAR support 3,32 Helpers to manipulate and build CDI metadata 3,32 An easier way to create AnnotationLiteral (and TypeLiteral) 3,27 Context SPI easily pluggable by the container 3,24 Configuration file 3,17 CDI parts * 3,12 Enhance SPI to retrieve Bean from its instances 3,1 JMX support 3,07 Introduce CDI Lite. * 2,78 Aligment with portlet 3.0 2,02
  • 19. CDI 2.0 new features
  • 21. Modularity Provide sub specs in CDI (called parts) that can be used independently Each part should have an implementation
  • 22. Modularity - Why ? We want to add new features to CDI without making it a bloated spec Having parts will help CDI adoption. Third party won’t have to get the whole spec if they don’t want to
  • 23. Modularity - What parts ? Right now we are thinking of 3 parts : CDI Light : DI without events, contexts, AOP and SPI Providing CDI for mobile / constrained platform Events : bring the event bus out of DI Full CDI
  • 24. Modularity - challenges Be sure of the parts - too much or not enough granularity Having an RI and TCK for each part can become huge work
  • 25. Java SE support using CDI outside Java EE
  • 26. Java SE support - Why? To provide a mean of building new stacks out of Java EE To boost CDI adoption for Spec working already on Java SE
  • 27. Java SE support - challenges Extract “Java EE” features across the spec to create a chapter dedicated to it Decide what existing SE support we standardise Add SPI for CDI integration with other framework / spec
  • 28. Enhancing events Asynchronous events Event ordering Event Range (war, ear, server, cluster)
  • 29. AOP enhancement Support AOP on custom or produced bean Improve interceptor chaining Support AOP on inner calls
  • 30. SPI and contexts enhancement Better access to all meta data created by CDI Provide a way to add bean at runtime Contexts enhancement for third party Spec Contexts not only based on thread approach
  • 31. CDI 2.0 needs you CDI 2.0 specification is open to everyone Come on join us on the mailing list and IRC channel All infos on http://cdi-spec.org or by following to @cdispec on twitter The more we are the more we’ll deliver