SlideShare uma empresa Scribd logo
1 de 39
Baixar para ler offline
<Insert Picture Here>
What's new in Java EE 6 ?
Arun Gupta
blogs.sun.com/arungupta, @arungupta
2
The following/preceding is intended to outline our
general product direction. It is intended for
information purposes only, and may not be
incorporated into any contract. It is not a
commitment to deliver any material, code, or
functionality, and should not be relied upon in
making purchasing decisions.
The development, release, and timing of any
features or functionality described for Oracle’s
products remains at the sole discretion of Oracle.
3
Compatible Java EE 5 Impl
http://java.sun.com/javaee/overview/compatibility-javaee5.jsp
4
Compatible Java EE 6 Impls
Today:
Announced:
5
Goals for the Java EE 6 Platform
• Flexible & Light-weight
• JAX-RPC, EJB 2.x Entity Beans, JAXR, JSR 88
• Extensible
• Embrace Open Source Frameworks
• Easier to use, develop on
• Continue on path set by Java EE 5
6
Java EE 6 Web Profile 1.0
• Fully functional mid-sized profile
• Actively discussed in the Java EE 6 Expert
Group and outside it
• Technologies
• Servlets 3.0, JSP 2.2, EL 2.2, Debugging Support for
Other Languages 1.0, JSTL 1.2, JSF 2.0, Common
Annotations 1.1, EJB 3.1 Lite, JTA 1.1, JPA 2.0, Bean
Validation 1.0, Managed Beans 1.0, Interceptors 1.1,
Context & Dependency Injection 1.0, Dependency
Injection for Java 1.0
7
Java EE 6 - Done
• Specifications approved by the JCP
• Reference Implementation is GlassFish v3
• TCK D
ec
2009
8
Java EE 6 Specifications
• The Platform
• Java EE 6 Web Profile 1.0
• Managed Beans 1.0
9
Java EE 6 Specifications
New
• Contexts and Dependency Injection for
Java EE (JSR 299)
• Bean Validation 1.0 (JSR 303)
• Java API for RESTful Web Services (JSR 311)
• Dependency Injection for Java (JSR 330)
10
Java EE 6 Specifications
Extreme Makeover
• Java Server Faces 2.0 (JSR 314)
• Java Servlets 3.0 (JSR 315)
• Java Persistence 2.0 (JSR 317)
• Enterprise Java Beans 3.1 & Interceptors 1.1
(JSR 318)
• Java EE Connector Architecture 1.6 (JSR 322)
11
Java EE 6 Specifications
Updates
• Java API for XML-based Web Services 2.2 (JSR 224)
• Java API for XML Binding 2.2 (JSR 222)
• Web Services Metadata MR3 (JSR 181)
• JSP 2.2/EL 2.2 (JSR 245)
• Web Services for Java EE 1.3 (JSR 109)
• Common Annotations 1.1 (JSR 250)
• Java Authorization Contract for Containers 1.3 (JSR 115)
• Java Authentication Service Provider Interface for
Containers 1.0 (JSR 196)
12
Java EE 6 Specifications
As is
• JDBC 4.0 API
• Java Naming and Directory Interface 1.2
• Java Message Service 1.1
• Java Transaction API 1.1
• Java Transaction Service 1.0
• JavaMail API Specification 1.4
• JavaBeans Activation Framework 1.1
• Java API for XML Processing 1.3
• Java API for XML-based RPC 1.1
• SOAP with Attachments API for Java 1.3
• Java API for XML Registries 1.0
• Java EE Management Specification 1.1 (JSR 77)
• Java EE Deployment Specification 1.2 (JSR 88)
• Java Management Extensions 1.2
• Java Authentication and Authorization Service 1.0
• Debugging Support for Other Languages (JSR 45)
• Standard Tag Library for JSP 1.2 (JSR 52)
• Streaming API for XML 1.0 (JSR 173)
13
Java EE 6 & Ease-of-development
• Continue advancements of Java EE 5
• Primary focus: Web Tier
• General principles
• Annotation-based programming model
• Reduce or eliminate need for DD
• Traditional API for advanced users
14
Managed Beans 1.0
• JavaBeans component model for Java EE
• Simple and Universally useful
• Advanced concepts in companion specs
• Basic Services
• Resource Injection, Lifecycle Callbacks, Interceptors
• Available as
• @Resource / @Inject
• java:app/<module-name>/<bean-name>
• java:module/<bean-name>
15
public class MyManagedBean {
public void setupResources() {
// setup your resources
}
public void cleanupResources() {
// collect them back here
}
public String sayHello(String name) {
return "Hello " + name;
}
}
Managed Beans 1.0 - Sample
@Resource
MyManagedBean bean;
@javax.annotation.ManagedBean
@PostConstruct
@PreDestroy
@Inject
MyManagedBean bean;
http://blogs.sun.com/arungupta/entry/totd_129_managed_beans_1
16
Servlets in Java EE 5
At least 2 files
<!--Deployment descriptor
web.xml -->
<web-app>
<servlet>
<servlet-name>MyServlet
</servlet-name>
<servlet-class>
com.sun.MyServlet
</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>MyServlet
</servlet-name>
<url-pattern>/myApp/*
</url-pattern>
</servlet-mapping>
...
</web-app>
/* Code in Java Class */
package com.sun;
public class MyServlet extends
HttpServlet {
public void
doGet(HttpServletRequest
req,HttpServletResponse res)
{
...
}
...
}
17
Servlets 3.0 (JSR 315)
Annotations-based @WebServlet
http://blogs.sun.com/arungupta/entry/totd_81_getting_started_with
package com.sun;
@WebServlet(name=”MyServlet”, urlPatterns={”/myApp/*”})
public class MyServlet extends HttpServlet {
public void doGet(HttpServletRequest req,
HttpServletResponse res)
{
...
}
<!--Deployment descriptor web.xml -->
<web-app>
<servlet>
<servlet-name>MyServlet</servlet-name>
<servlet-class>
com.sun.MyServlet
</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>MyServlet</servlet-name>
<url-pattern>/myApp/*</url-pattern>
</servlet-mapping>
...
</web-app>
18
Servlets 3.0
• @WebServlet, @WebListener, @WebFilter, …
• Asynchronous Servlets
• @WebServlet(asyncSupported=true)
• Plugin libraries using web fragments
• Dynamic registration of Servlets
• WEB-INF/lib/[*.jar]/META-INF/resources
accessible in the root
• Programmatic authentication login/logout
• Default Error Page
• . . .
19
EJB 3.1 (JSR 318)
Package & Deploy in a WAR
myApp.ear
web.war
WEB-INF/web.xml
WEB-INF/classes
com.sun.FooServlet
com.sun.TickTock
beans.jar
com.sun.FooBean
com.sun.FooHelper
myApp.war
WEB-INF/classes
com.sun.FooServlet
com.sun.TickTock
com.sun.FooBean
com.sun.FooHelper
web.xml ?
Java EE 5 Java EE 6
http://blogs.sun.com/arungupta/entry/totd_95_ejb_3_1
20
public class MySessionBean {
public void setupResources() {
// setup your resources
}
public void cleanupResources() {
// collect them back here
}
public String sayHello(String name) {
return "Hello " + name;
}
}
EJB 3.1 - Sample
@EJB
MySessionBean bean;
@Stateless
@PostConstruct
@PreDestroy
21
EJB 3.1
• No interface view – one source file per bean
• Embeddable API
• @Singleton
• Initialization in @PostContruct
• Simplified Cron-like syntax for Timer
• Asynchronous Session Bean
• Portable Global JNDI Name
22
EJB 3.1
EJB 3.1 Lite – Feature Comparison
23
Contexts & Dependency Injection
(JSR 299)
• Standards-based Dependency Injection
• Type-safe – Buids on @Inject API
• Context/Scope management
• Includes ELResolver
@Inject @LoggedIn User user
Request
Injection
What ?
(Type)
Which one ?
(Qualifier)
@Inject @LoggedIn User
24
CDI
• Qualifiers
• Events
• Stereotypes
• Interceptors
• Decorators
• Alternatives
• . . .
25
Java Server Faces 2.0 (JSR 314)
• Facelets as “templating language” for the page
• Custom components much easier to develop
• Integrated Ajax
• “faces-config.xml” optional in common cases
• Default navigation rules
• Much more …
• Runs on Servlet 2.5+
• Bookmarkable URLs
• Conditional navigation
• ...
26
Java Persistence API 2 (JSR 317)
• Improved O/R mapping
• Type-safe Criteria API
• Expanded and Richer JPQL
• 2nd-level Cache
• New locking modes
• PESSIMISTIC_READ – grab shared lock
• PESSIMISTIC_WRITE – grab exclusive lock
• PESSIMISTIC_FORCE_INCREMENT – update version
• Standard configuration options
• javax.persistence.jdbc.[driver | url | user | password]
27
Bean Validation (JSR 303)
• Tier-independent mechanism to define
constraints for data validation
• Represented by annotations
• javax.validation.* package
• Integrated with JSF and JPA
• JSF: f:validateRequired, f:validateRegexp
• JPA: pre-persist, pre-update, and pre-remove
• @NotNull(message=”...”), @Max, @Min,
@Size
• Fully Extensible
• @Email String recipient;
28
JAX-RS 1.1 (JSR 311)
• Java API for building RESTful Web Services
• POJO based
• Annotation-driven
• Server-side API
• HTTP-centric
29
JAX-RS 1.1
Code Sample - Simple
public class HelloWorldResource {
public String sayHello() {
return "Hello World";
}
public String morning() {
return “Good Morning!”;
}
}
@Path("helloworld")
@Context UriInfo ui;
@GET
@Produces("text/plain")
@GET
@Path("morning")
30
IDE Support for Java EE 6
31
What does Java EE offer to Cloud ?
●
Containers
●
Injectable services
●
Scale to large clusters
●
Security model
●
. . .
32
What can Java EE do for Clouds ?
●
Tighter requirements for resource and state
management
●
Better isolation between applications
●
Potential standard APIs for NRDBMS, Caching, …
●
HTML5
●
Common management and monitoring interfaces
●
Better packaging
●
Apps/Data are (multiple) versioned, Upgrades,
Expose/Connect to services, QoS attributes, ...
●
Evolution, not revolution
33
What else is coming in JavaEE.next?
• Modularity
• Build on Java SE work
• Applications made of modules
• Dependencies are explicit
• Versioning is built-in
• Web socket support
• Standard JSON API
• HTML5 support
• NIO.2-based web container
34
What is GlassFish ?
• A community
• Users, Partners, Testers, Developers, ...
• Started in 2005 on java.net
• Application Server
• Open Source (CDDL & GPL v2)
• Java EE Reference Implementation
GlassFish Distributions
Distribution License Features
GlassFish Open Source
Edition 3.0.1
CDDL &
GPLv2
• Java EE 6 Compatibility
• No Clustering
• Clustering planned in 3.1
• mod_jk for load balancing
GlassFish Open Source
Edition 2.1.1
CDDL &
GPLv2
• Java EE 5 Compatibility
• In memory replication
• mod_loadbalancer
Oracle GlassFish Server
3.0.1
Commercial • GlassFish Open Source Edition 3.0.1
• GlassFish Server Control
• Clustering planned in 3.1
Oracle GlassFish Server
2.1.1
Commercial • GlassFish Open Source Edition 2.1.1
• Enterprise Manager
• HADB
Clustering
Coming
Soon!
36
Books on GlassFish
37
GlassFish Roadmap Detail
©2010 Oracle Corporation
38
References
• glassfish.org
• oracle.com/goto/glassfish
• blogs.sun.com/theaquarium
• glassfish.org/roadmap
• youtube.com/user/GlassFishVideos
• Follow @glassfish
<Insert Picture Here>
What's new in Java EE 6 ?
Arun Gupta
blogs.sun.com/arungupta, @arungupta

Mais conteúdo relacionado

Mais procurados

Java EE 6 workshop at Dallas Tech Fest 2011
Java EE 6 workshop at Dallas Tech Fest 2011Java EE 6 workshop at Dallas Tech Fest 2011
Java EE 6 workshop at Dallas Tech Fest 2011Arun Gupta
 
Java EE 6 Component Model Explained
Java EE 6 Component Model Explained Java EE 6 Component Model Explained
Java EE 6 Component Model Explained Shreedhar Ganapathy
 
Sun Java EE 6 Overview
Sun Java EE 6 OverviewSun Java EE 6 Overview
Sun Java EE 6 Overviewsbobde
 
Deep Dive Hands-on in Java EE 6 - Oredev 2010
Deep Dive Hands-on in Java EE 6 - Oredev 2010Deep Dive Hands-on in Java EE 6 - Oredev 2010
Deep Dive Hands-on in Java EE 6 - Oredev 2010Arun Gupta
 
Java EE6 CodeCamp16 oct 2010
Java EE6 CodeCamp16 oct 2010Java EE6 CodeCamp16 oct 2010
Java EE6 CodeCamp16 oct 2010Codecamp Romania
 
Java EE 8 Recipes
Java EE 8 RecipesJava EE 8 Recipes
Java EE 8 RecipesJosh Juneau
 
Contextual Dependency Injection for Apachecon 2010
Contextual Dependency Injection for Apachecon 2010Contextual Dependency Injection for Apachecon 2010
Contextual Dependency Injection for Apachecon 2010Rohit Kelapure
 
스프링 프레임워크
스프링 프레임워크스프링 프레임워크
스프링 프레임워크Yoonki Chang
 
S313557 java ee_programming_model_explained_dochez
S313557 java ee_programming_model_explained_dochezS313557 java ee_programming_model_explained_dochez
S313557 java ee_programming_model_explained_dochezJerome Dochez
 
Java EE 6 & GlassFish v3 @ DevNexus
Java EE 6 & GlassFish v3 @ DevNexusJava EE 6 & GlassFish v3 @ DevNexus
Java EE 6 & GlassFish v3 @ DevNexusArun Gupta
 
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...Arun Gupta
 
TDC 2011: The Java EE 7 Platform: Developing for the Cloud
TDC 2011: The Java EE 7 Platform: Developing for the CloudTDC 2011: The Java EE 7 Platform: Developing for the Cloud
TDC 2011: The Java EE 7 Platform: Developing for the CloudArun Gupta
 
GlassFish & Java EE Business Update @ CEJUG
GlassFish & Java EE Business Update @ CEJUGGlassFish & Java EE Business Update @ CEJUG
GlassFish & Java EE Business Update @ CEJUGArun Gupta
 
JavaEE 6 and GlassFish v3 at SFJUG
JavaEE 6 and GlassFish v3 at SFJUGJavaEE 6 and GlassFish v3 at SFJUG
JavaEE 6 and GlassFish v3 at SFJUGMarakana Inc.
 
Java EE 6 Hands-on Workshop at Dallas Tech Fest 2010
Java EE 6 Hands-on Workshop at Dallas Tech Fest 2010Java EE 6 Hands-on Workshop at Dallas Tech Fest 2010
Java EE 6 Hands-on Workshop at Dallas Tech Fest 2010Arun Gupta
 
Understanding the nuts & bolts of Java EE 6
Understanding the nuts & bolts of Java EE 6Understanding the nuts & bolts of Java EE 6
Understanding the nuts & bolts of Java EE 6Arun Gupta
 

Mais procurados (20)

Java EE 6 workshop at Dallas Tech Fest 2011
Java EE 6 workshop at Dallas Tech Fest 2011Java EE 6 workshop at Dallas Tech Fest 2011
Java EE 6 workshop at Dallas Tech Fest 2011
 
Java EE 6 Component Model Explained
Java EE 6 Component Model Explained Java EE 6 Component Model Explained
Java EE 6 Component Model Explained
 
Sun Java EE 6 Overview
Sun Java EE 6 OverviewSun Java EE 6 Overview
Sun Java EE 6 Overview
 
Java 7 workshop
Java 7 workshopJava 7 workshop
Java 7 workshop
 
Deep Dive Hands-on in Java EE 6 - Oredev 2010
Deep Dive Hands-on in Java EE 6 - Oredev 2010Deep Dive Hands-on in Java EE 6 - Oredev 2010
Deep Dive Hands-on in Java EE 6 - Oredev 2010
 
Java EE6 CodeCamp16 oct 2010
Java EE6 CodeCamp16 oct 2010Java EE6 CodeCamp16 oct 2010
Java EE6 CodeCamp16 oct 2010
 
Java EE 8 Recipes
Java EE 8 RecipesJava EE 8 Recipes
Java EE 8 Recipes
 
Contextual Dependency Injection for Apachecon 2010
Contextual Dependency Injection for Apachecon 2010Contextual Dependency Injection for Apachecon 2010
Contextual Dependency Injection for Apachecon 2010
 
스프링 프레임워크
스프링 프레임워크스프링 프레임워크
스프링 프레임워크
 
S313557 java ee_programming_model_explained_dochez
S313557 java ee_programming_model_explained_dochezS313557 java ee_programming_model_explained_dochez
S313557 java ee_programming_model_explained_dochez
 
Java EE 8
Java EE 8Java EE 8
Java EE 8
 
Java EE 6 & GlassFish v3 @ DevNexus
Java EE 6 & GlassFish v3 @ DevNexusJava EE 6 & GlassFish v3 @ DevNexus
Java EE 6 & GlassFish v3 @ DevNexus
 
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...
 
TDC 2011: The Java EE 7 Platform: Developing for the Cloud
TDC 2011: The Java EE 7 Platform: Developing for the CloudTDC 2011: The Java EE 7 Platform: Developing for the Cloud
TDC 2011: The Java EE 7 Platform: Developing for the Cloud
 
GlassFish & Java EE Business Update @ CEJUG
GlassFish & Java EE Business Update @ CEJUGGlassFish & Java EE Business Update @ CEJUG
GlassFish & Java EE Business Update @ CEJUG
 
JavaEE 6 and GlassFish v3 at SFJUG
JavaEE 6 and GlassFish v3 at SFJUGJavaEE 6 and GlassFish v3 at SFJUG
JavaEE 6 and GlassFish v3 at SFJUG
 
jsf2 Notes
jsf2 Notesjsf2 Notes
jsf2 Notes
 
Java EE 6 Hands-on Workshop at Dallas Tech Fest 2010
Java EE 6 Hands-on Workshop at Dallas Tech Fest 2010Java EE 6 Hands-on Workshop at Dallas Tech Fest 2010
Java EE 6 Hands-on Workshop at Dallas Tech Fest 2010
 
Java EE 7 - Overview and Status
Java EE 7  - Overview and StatusJava EE 7  - Overview and Status
Java EE 7 - Overview and Status
 
Understanding the nuts & bolts of Java EE 6
Understanding the nuts & bolts of Java EE 6Understanding the nuts & bolts of Java EE 6
Understanding the nuts & bolts of Java EE 6
 

Destaque

GlassFish Story by Jaromir Hamala/C2B2 Consulting
GlassFish Story by Jaromir Hamala/C2B2 ConsultingGlassFish Story by Jaromir Hamala/C2B2 Consulting
GlassFish Story by Jaromir Hamala/C2B2 Consultingglassfish
 
OTN Developer Days - GlassFish
OTN Developer Days - GlassFishOTN Developer Days - GlassFish
OTN Developer Days - GlassFishglassfish
 
GlassFish Story by David Heffelfinger/Ensode Technology
GlassFish Story by David Heffelfinger/Ensode TechnologyGlassFish Story by David Heffelfinger/Ensode Technology
GlassFish Story by David Heffelfinger/Ensode Technologyglassfish
 
GlassFish Roadmap
GlassFish RoadmapGlassFish Roadmap
GlassFish Roadmapglassfish
 
GlassFish BOF
GlassFish BOFGlassFish BOF
GlassFish BOFglassfish
 
GlassFish Story by Kerry Wilson/Vanderbilt University Medical Center
GlassFish Story by Kerry Wilson/Vanderbilt University Medical CenterGlassFish Story by Kerry Wilson/Vanderbilt University Medical Center
GlassFish Story by Kerry Wilson/Vanderbilt University Medical Centerglassfish
 
Fifty Features of Java EE 7 in 50 Minutes
Fifty Features of Java EE 7 in 50 MinutesFifty Features of Java EE 7 in 50 Minutes
Fifty Features of Java EE 7 in 50 Minutesglassfish
 

Destaque (7)

GlassFish Story by Jaromir Hamala/C2B2 Consulting
GlassFish Story by Jaromir Hamala/C2B2 ConsultingGlassFish Story by Jaromir Hamala/C2B2 Consulting
GlassFish Story by Jaromir Hamala/C2B2 Consulting
 
OTN Developer Days - GlassFish
OTN Developer Days - GlassFishOTN Developer Days - GlassFish
OTN Developer Days - GlassFish
 
GlassFish Story by David Heffelfinger/Ensode Technology
GlassFish Story by David Heffelfinger/Ensode TechnologyGlassFish Story by David Heffelfinger/Ensode Technology
GlassFish Story by David Heffelfinger/Ensode Technology
 
GlassFish Roadmap
GlassFish RoadmapGlassFish Roadmap
GlassFish Roadmap
 
GlassFish BOF
GlassFish BOFGlassFish BOF
GlassFish BOF
 
GlassFish Story by Kerry Wilson/Vanderbilt University Medical Center
GlassFish Story by Kerry Wilson/Vanderbilt University Medical CenterGlassFish Story by Kerry Wilson/Vanderbilt University Medical Center
GlassFish Story by Kerry Wilson/Vanderbilt University Medical Center
 
Fifty Features of Java EE 7 in 50 Minutes
Fifty Features of Java EE 7 in 50 MinutesFifty Features of Java EE 7 in 50 Minutes
Fifty Features of Java EE 7 in 50 Minutes
 

Semelhante a OTN Developer Days - Java EE 6

Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ JAX London ...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ JAX London ...Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ JAX London ...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ JAX London ...Arun Gupta
 
Java EE 6, Eclipse @ EclipseCon
Java EE 6, Eclipse @ EclipseConJava EE 6, Eclipse @ EclipseCon
Java EE 6, Eclipse @ EclipseConLudovic Champenois
 
Java EE 6 & GlassFish = Less Code + More Power at CEJUG
Java EE 6 & GlassFish = Less Code + More Power at CEJUGJava EE 6 & GlassFish = Less Code + More Power at CEJUG
Java EE 6 & GlassFish = Less Code + More Power at CEJUGArun Gupta
 
Java EE 6 = Less Code + More Power
Java EE 6 = Less Code + More PowerJava EE 6 = Less Code + More Power
Java EE 6 = Less Code + More PowerArun Gupta
 
Java EE 6 & GlassFish = Less Code + More Power @ DevIgnition
Java EE 6 & GlassFish = Less Code + More Power @ DevIgnitionJava EE 6 & GlassFish = Less Code + More Power @ DevIgnition
Java EE 6 & GlassFish = Less Code + More Power @ DevIgnitionArun Gupta
 
Java EE8 - by Kito Mann
Java EE8 - by Kito Mann Java EE8 - by Kito Mann
Java EE8 - by Kito Mann Kile Niklawski
 
What’s new in Java SE, EE, ME, Embedded world & new Strategy
What’s new in Java SE, EE, ME, Embedded world & new StrategyWhat’s new in Java SE, EE, ME, Embedded world & new Strategy
What’s new in Java SE, EE, ME, Embedded world & new StrategyMohamed Taman
 
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 India
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 IndiaJava EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 India
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 IndiaArun Gupta
 
Java EE 6 & GlassFish v3 at Vancouver JUG, Jan 26, 2010
Java EE 6 & GlassFish v3 at Vancouver JUG, Jan 26, 2010Java EE 6 & GlassFish v3 at Vancouver JUG, Jan 26, 2010
Java EE 6 & GlassFish v3 at Vancouver JUG, Jan 26, 2010Arun Gupta
 
Java ee 8 + security overview
Java ee 8 + security overviewJava ee 8 + security overview
Java ee 8 + security overviewRudy De Busscher
 
Java EE 8: On the Horizon
Java EE 8:  On the HorizonJava EE 8:  On the Horizon
Java EE 8: On the HorizonJosh Juneau
 
Java EE 7 Soup to Nuts at JavaOne 2014
Java EE 7 Soup to Nuts at JavaOne 2014Java EE 7 Soup to Nuts at JavaOne 2014
Java EE 7 Soup to Nuts at JavaOne 2014Arun Gupta
 
Gustavo Garnica: Evolución de la Plataforma Java y lo que Significa para Ti
Gustavo Garnica: Evolución de la Plataforma Java y lo que Significa para TiGustavo Garnica: Evolución de la Plataforma Java y lo que Significa para Ti
Gustavo Garnica: Evolución de la Plataforma Java y lo que Significa para TiSoftware Guru
 
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010Arun Gupta
 
JavaOne 2014 Java EE 8 Booth Slides
JavaOne 2014 Java EE 8 Booth SlidesJavaOne 2014 Java EE 8 Booth Slides
JavaOne 2014 Java EE 8 Booth SlidesEdward Burns
 
Enterprise java unit-1_chapter-1
Enterprise java unit-1_chapter-1Enterprise java unit-1_chapter-1
Enterprise java unit-1_chapter-1sandeep54552
 
Java EE 6, Eclipse, GlassFish @EclipseCon 2010
Java EE 6, Eclipse, GlassFish @EclipseCon 2010Java EE 6, Eclipse, GlassFish @EclipseCon 2010
Java EE 6, Eclipse, GlassFish @EclipseCon 2010Ludovic Champenois
 

Semelhante a OTN Developer Days - Java EE 6 (20)

Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ JAX London ...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ JAX London ...Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ JAX London ...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ JAX London ...
 
Java EE 6, Eclipse @ EclipseCon
Java EE 6, Eclipse @ EclipseConJava EE 6, Eclipse @ EclipseCon
Java EE 6, Eclipse @ EclipseCon
 
Java EE 6 & GlassFish = Less Code + More Power at CEJUG
Java EE 6 & GlassFish = Less Code + More Power at CEJUGJava EE 6 & GlassFish = Less Code + More Power at CEJUG
Java EE 6 & GlassFish = Less Code + More Power at CEJUG
 
Java EE 6 = Less Code + More Power
Java EE 6 = Less Code + More PowerJava EE 6 = Less Code + More Power
Java EE 6 = Less Code + More Power
 
Java EE 6 & GlassFish = Less Code + More Power @ DevIgnition
Java EE 6 & GlassFish = Less Code + More Power @ DevIgnitionJava EE 6 & GlassFish = Less Code + More Power @ DevIgnition
Java EE 6 & GlassFish = Less Code + More Power @ DevIgnition
 
Java EE8 - by Kito Mann
Java EE8 - by Kito Mann Java EE8 - by Kito Mann
Java EE8 - by Kito Mann
 
What’s new in Java SE, EE, ME, Embedded world & new Strategy
What’s new in Java SE, EE, ME, Embedded world & new StrategyWhat’s new in Java SE, EE, ME, Embedded world & new Strategy
What’s new in Java SE, EE, ME, Embedded world & new Strategy
 
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 India
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 IndiaJava EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 India
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 India
 
Java EE 6 & GlassFish v3 at Vancouver JUG, Jan 26, 2010
Java EE 6 & GlassFish v3 at Vancouver JUG, Jan 26, 2010Java EE 6 & GlassFish v3 at Vancouver JUG, Jan 26, 2010
Java EE 6 & GlassFish v3 at Vancouver JUG, Jan 26, 2010
 
Java ee 8 + security overview
Java ee 8 + security overviewJava ee 8 + security overview
Java ee 8 + security overview
 
Java EE 8: On the Horizon
Java EE 8:  On the HorizonJava EE 8:  On the Horizon
Java EE 8: On the Horizon
 
Java EE 7 Soup to Nuts at JavaOne 2014
Java EE 7 Soup to Nuts at JavaOne 2014Java EE 7 Soup to Nuts at JavaOne 2014
Java EE 7 Soup to Nuts at JavaOne 2014
 
Gustavo Garnica: Evolución de la Plataforma Java y lo que Significa para Ti
Gustavo Garnica: Evolución de la Plataforma Java y lo que Significa para TiGustavo Garnica: Evolución de la Plataforma Java y lo que Significa para Ti
Gustavo Garnica: Evolución de la Plataforma Java y lo que Significa para Ti
 
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010
 
JavaOne 2014 Java EE 8 Booth Slides
JavaOne 2014 Java EE 8 Booth SlidesJavaOne 2014 Java EE 8 Booth Slides
JavaOne 2014 Java EE 8 Booth Slides
 
Java E
Java EJava E
Java E
 
Enterprise java unit-1_chapter-1
Enterprise java unit-1_chapter-1Enterprise java unit-1_chapter-1
Enterprise java unit-1_chapter-1
 
Java EE 6, Eclipse, GlassFish @EclipseCon 2010
Java EE 6, Eclipse, GlassFish @EclipseCon 2010Java EE 6, Eclipse, GlassFish @EclipseCon 2010
Java EE 6, Eclipse, GlassFish @EclipseCon 2010
 
First8 java one review 2016
First8 java one review 2016First8 java one review 2016
First8 java one review 2016
 
JavaEE 6 tools coverage
JavaEE 6 tools coverageJavaEE 6 tools coverage
JavaEE 6 tools coverage
 

Último

All in AI: LLM Landscape & RAG in 2024 with Mark Ryan (Google) & Jerry Liu (L...
All in AI: LLM Landscape & RAG in 2024 with Mark Ryan (Google) & Jerry Liu (L...All in AI: LLM Landscape & RAG in 2024 with Mark Ryan (Google) & Jerry Liu (L...
All in AI: LLM Landscape & RAG in 2024 with Mark Ryan (Google) & Jerry Liu (L...Daniel Zivkovic
 
99.99% of Your Traces Are (Probably) Trash (SRECon NA 2024).pdf
99.99% of Your Traces  Are (Probably) Trash (SRECon NA 2024).pdf99.99% of Your Traces  Are (Probably) Trash (SRECon NA 2024).pdf
99.99% of Your Traces Are (Probably) Trash (SRECon NA 2024).pdfPaige Cruz
 
Igniting Next Level Productivity with AI-Infused Data Integration Workflows
Igniting Next Level Productivity with AI-Infused Data Integration WorkflowsIgniting Next Level Productivity with AI-Infused Data Integration Workflows
Igniting Next Level Productivity with AI-Infused Data Integration WorkflowsSafe Software
 
Machine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdfMachine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdfAijun Zhang
 
100+ ChatGPT Prompts for SEO Optimization
100+ ChatGPT Prompts for SEO Optimization100+ ChatGPT Prompts for SEO Optimization
100+ ChatGPT Prompts for SEO Optimizationarrow10202532yuvraj
 
UiPath Studio Web workshop series - Day 7
UiPath Studio Web workshop series - Day 7UiPath Studio Web workshop series - Day 7
UiPath Studio Web workshop series - Day 7DianaGray10
 
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...UbiTrack UK
 
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1DianaGray10
 
ADOPTING WEB 3 FOR YOUR BUSINESS: A STEP-BY-STEP GUIDE
ADOPTING WEB 3 FOR YOUR BUSINESS: A STEP-BY-STEP GUIDEADOPTING WEB 3 FOR YOUR BUSINESS: A STEP-BY-STEP GUIDE
ADOPTING WEB 3 FOR YOUR BUSINESS: A STEP-BY-STEP GUIDELiveplex
 
The Kubernetes Gateway API and its role in Cloud Native API Management
The Kubernetes Gateway API and its role in Cloud Native API ManagementThe Kubernetes Gateway API and its role in Cloud Native API Management
The Kubernetes Gateway API and its role in Cloud Native API ManagementNuwan Dias
 
Computer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and HazardsComputer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and HazardsSeth Reyes
 
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online CollaborationCOMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online Collaborationbruanjhuli
 
IEEE Computer Society’s Strategic Activities and Products including SWEBOK Guide
IEEE Computer Society’s Strategic Activities and Products including SWEBOK GuideIEEE Computer Society’s Strategic Activities and Products including SWEBOK Guide
IEEE Computer Society’s Strategic Activities and Products including SWEBOK GuideHironori Washizaki
 
Videogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdfVideogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdfinfogdgmi
 
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Will Schroeder
 
UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6DianaGray10
 
Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024SkyPlanner
 
Governance in SharePoint Premium:What's in the box?
Governance in SharePoint Premium:What's in the box?Governance in SharePoint Premium:What's in the box?
Governance in SharePoint Premium:What's in the box?Juan Carlos Gonzalez
 

Último (20)

201610817 - edge part1
201610817 - edge part1201610817 - edge part1
201610817 - edge part1
 
All in AI: LLM Landscape & RAG in 2024 with Mark Ryan (Google) & Jerry Liu (L...
All in AI: LLM Landscape & RAG in 2024 with Mark Ryan (Google) & Jerry Liu (L...All in AI: LLM Landscape & RAG in 2024 with Mark Ryan (Google) & Jerry Liu (L...
All in AI: LLM Landscape & RAG in 2024 with Mark Ryan (Google) & Jerry Liu (L...
 
99.99% of Your Traces Are (Probably) Trash (SRECon NA 2024).pdf
99.99% of Your Traces  Are (Probably) Trash (SRECon NA 2024).pdf99.99% of Your Traces  Are (Probably) Trash (SRECon NA 2024).pdf
99.99% of Your Traces Are (Probably) Trash (SRECon NA 2024).pdf
 
20230104 - machine vision
20230104 - machine vision20230104 - machine vision
20230104 - machine vision
 
Igniting Next Level Productivity with AI-Infused Data Integration Workflows
Igniting Next Level Productivity with AI-Infused Data Integration WorkflowsIgniting Next Level Productivity with AI-Infused Data Integration Workflows
Igniting Next Level Productivity with AI-Infused Data Integration Workflows
 
Machine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdfMachine Learning Model Validation (Aijun Zhang 2024).pdf
Machine Learning Model Validation (Aijun Zhang 2024).pdf
 
100+ ChatGPT Prompts for SEO Optimization
100+ ChatGPT Prompts for SEO Optimization100+ ChatGPT Prompts for SEO Optimization
100+ ChatGPT Prompts for SEO Optimization
 
UiPath Studio Web workshop series - Day 7
UiPath Studio Web workshop series - Day 7UiPath Studio Web workshop series - Day 7
UiPath Studio Web workshop series - Day 7
 
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
 
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
 
ADOPTING WEB 3 FOR YOUR BUSINESS: A STEP-BY-STEP GUIDE
ADOPTING WEB 3 FOR YOUR BUSINESS: A STEP-BY-STEP GUIDEADOPTING WEB 3 FOR YOUR BUSINESS: A STEP-BY-STEP GUIDE
ADOPTING WEB 3 FOR YOUR BUSINESS: A STEP-BY-STEP GUIDE
 
The Kubernetes Gateway API and its role in Cloud Native API Management
The Kubernetes Gateway API and its role in Cloud Native API ManagementThe Kubernetes Gateway API and its role in Cloud Native API Management
The Kubernetes Gateway API and its role in Cloud Native API Management
 
Computer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and HazardsComputer 10: Lesson 10 - Online Crimes and Hazards
Computer 10: Lesson 10 - Online Crimes and Hazards
 
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online CollaborationCOMPUTER 10: Lesson 7 - File Storage and Online Collaboration
COMPUTER 10: Lesson 7 - File Storage and Online Collaboration
 
IEEE Computer Society’s Strategic Activities and Products including SWEBOK Guide
IEEE Computer Society’s Strategic Activities and Products including SWEBOK GuideIEEE Computer Society’s Strategic Activities and Products including SWEBOK Guide
IEEE Computer Society’s Strategic Activities and Products including SWEBOK Guide
 
Videogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdfVideogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdf
 
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
Apres-Cyber - The Data Dilemma: Bridging Offensive Operations and Machine Lea...
 
UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6
 
Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024Salesforce Miami User Group Event - 1st Quarter 2024
Salesforce Miami User Group Event - 1st Quarter 2024
 
Governance in SharePoint Premium:What's in the box?
Governance in SharePoint Premium:What's in the box?Governance in SharePoint Premium:What's in the box?
Governance in SharePoint Premium:What's in the box?
 

OTN Developer Days - Java EE 6

  • 1. <Insert Picture Here> What's new in Java EE 6 ? Arun Gupta blogs.sun.com/arungupta, @arungupta
  • 2. 2 The following/preceding is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remains at the sole discretion of Oracle.
  • 3. 3 Compatible Java EE 5 Impl http://java.sun.com/javaee/overview/compatibility-javaee5.jsp
  • 4. 4 Compatible Java EE 6 Impls Today: Announced:
  • 5. 5 Goals for the Java EE 6 Platform • Flexible & Light-weight • JAX-RPC, EJB 2.x Entity Beans, JAXR, JSR 88 • Extensible • Embrace Open Source Frameworks • Easier to use, develop on • Continue on path set by Java EE 5
  • 6. 6 Java EE 6 Web Profile 1.0 • Fully functional mid-sized profile • Actively discussed in the Java EE 6 Expert Group and outside it • Technologies • Servlets 3.0, JSP 2.2, EL 2.2, Debugging Support for Other Languages 1.0, JSTL 1.2, JSF 2.0, Common Annotations 1.1, EJB 3.1 Lite, JTA 1.1, JPA 2.0, Bean Validation 1.0, Managed Beans 1.0, Interceptors 1.1, Context & Dependency Injection 1.0, Dependency Injection for Java 1.0
  • 7. 7 Java EE 6 - Done • Specifications approved by the JCP • Reference Implementation is GlassFish v3 • TCK D ec 2009
  • 8. 8 Java EE 6 Specifications • The Platform • Java EE 6 Web Profile 1.0 • Managed Beans 1.0
  • 9. 9 Java EE 6 Specifications New • Contexts and Dependency Injection for Java EE (JSR 299) • Bean Validation 1.0 (JSR 303) • Java API for RESTful Web Services (JSR 311) • Dependency Injection for Java (JSR 330)
  • 10. 10 Java EE 6 Specifications Extreme Makeover • Java Server Faces 2.0 (JSR 314) • Java Servlets 3.0 (JSR 315) • Java Persistence 2.0 (JSR 317) • Enterprise Java Beans 3.1 & Interceptors 1.1 (JSR 318) • Java EE Connector Architecture 1.6 (JSR 322)
  • 11. 11 Java EE 6 Specifications Updates • Java API for XML-based Web Services 2.2 (JSR 224) • Java API for XML Binding 2.2 (JSR 222) • Web Services Metadata MR3 (JSR 181) • JSP 2.2/EL 2.2 (JSR 245) • Web Services for Java EE 1.3 (JSR 109) • Common Annotations 1.1 (JSR 250) • Java Authorization Contract for Containers 1.3 (JSR 115) • Java Authentication Service Provider Interface for Containers 1.0 (JSR 196)
  • 12. 12 Java EE 6 Specifications As is • JDBC 4.0 API • Java Naming and Directory Interface 1.2 • Java Message Service 1.1 • Java Transaction API 1.1 • Java Transaction Service 1.0 • JavaMail API Specification 1.4 • JavaBeans Activation Framework 1.1 • Java API for XML Processing 1.3 • Java API for XML-based RPC 1.1 • SOAP with Attachments API for Java 1.3 • Java API for XML Registries 1.0 • Java EE Management Specification 1.1 (JSR 77) • Java EE Deployment Specification 1.2 (JSR 88) • Java Management Extensions 1.2 • Java Authentication and Authorization Service 1.0 • Debugging Support for Other Languages (JSR 45) • Standard Tag Library for JSP 1.2 (JSR 52) • Streaming API for XML 1.0 (JSR 173)
  • 13. 13 Java EE 6 & Ease-of-development • Continue advancements of Java EE 5 • Primary focus: Web Tier • General principles • Annotation-based programming model • Reduce or eliminate need for DD • Traditional API for advanced users
  • 14. 14 Managed Beans 1.0 • JavaBeans component model for Java EE • Simple and Universally useful • Advanced concepts in companion specs • Basic Services • Resource Injection, Lifecycle Callbacks, Interceptors • Available as • @Resource / @Inject • java:app/<module-name>/<bean-name> • java:module/<bean-name>
  • 15. 15 public class MyManagedBean { public void setupResources() { // setup your resources } public void cleanupResources() { // collect them back here } public String sayHello(String name) { return "Hello " + name; } } Managed Beans 1.0 - Sample @Resource MyManagedBean bean; @javax.annotation.ManagedBean @PostConstruct @PreDestroy @Inject MyManagedBean bean; http://blogs.sun.com/arungupta/entry/totd_129_managed_beans_1
  • 16. 16 Servlets in Java EE 5 At least 2 files <!--Deployment descriptor web.xml --> <web-app> <servlet> <servlet-name>MyServlet </servlet-name> <servlet-class> com.sun.MyServlet </servlet-class> </servlet> <servlet-mapping> <servlet-name>MyServlet </servlet-name> <url-pattern>/myApp/* </url-pattern> </servlet-mapping> ... </web-app> /* Code in Java Class */ package com.sun; public class MyServlet extends HttpServlet { public void doGet(HttpServletRequest req,HttpServletResponse res) { ... } ... }
  • 17. 17 Servlets 3.0 (JSR 315) Annotations-based @WebServlet http://blogs.sun.com/arungupta/entry/totd_81_getting_started_with package com.sun; @WebServlet(name=”MyServlet”, urlPatterns={”/myApp/*”}) public class MyServlet extends HttpServlet { public void doGet(HttpServletRequest req, HttpServletResponse res) { ... } <!--Deployment descriptor web.xml --> <web-app> <servlet> <servlet-name>MyServlet</servlet-name> <servlet-class> com.sun.MyServlet </servlet-class> </servlet> <servlet-mapping> <servlet-name>MyServlet</servlet-name> <url-pattern>/myApp/*</url-pattern> </servlet-mapping> ... </web-app>
  • 18. 18 Servlets 3.0 • @WebServlet, @WebListener, @WebFilter, … • Asynchronous Servlets • @WebServlet(asyncSupported=true) • Plugin libraries using web fragments • Dynamic registration of Servlets • WEB-INF/lib/[*.jar]/META-INF/resources accessible in the root • Programmatic authentication login/logout • Default Error Page • . . .
  • 19. 19 EJB 3.1 (JSR 318) Package & Deploy in a WAR myApp.ear web.war WEB-INF/web.xml WEB-INF/classes com.sun.FooServlet com.sun.TickTock beans.jar com.sun.FooBean com.sun.FooHelper myApp.war WEB-INF/classes com.sun.FooServlet com.sun.TickTock com.sun.FooBean com.sun.FooHelper web.xml ? Java EE 5 Java EE 6 http://blogs.sun.com/arungupta/entry/totd_95_ejb_3_1
  • 20. 20 public class MySessionBean { public void setupResources() { // setup your resources } public void cleanupResources() { // collect them back here } public String sayHello(String name) { return "Hello " + name; } } EJB 3.1 - Sample @EJB MySessionBean bean; @Stateless @PostConstruct @PreDestroy
  • 21. 21 EJB 3.1 • No interface view – one source file per bean • Embeddable API • @Singleton • Initialization in @PostContruct • Simplified Cron-like syntax for Timer • Asynchronous Session Bean • Portable Global JNDI Name
  • 22. 22 EJB 3.1 EJB 3.1 Lite – Feature Comparison
  • 23. 23 Contexts & Dependency Injection (JSR 299) • Standards-based Dependency Injection • Type-safe – Buids on @Inject API • Context/Scope management • Includes ELResolver @Inject @LoggedIn User user Request Injection What ? (Type) Which one ? (Qualifier) @Inject @LoggedIn User
  • 24. 24 CDI • Qualifiers • Events • Stereotypes • Interceptors • Decorators • Alternatives • . . .
  • 25. 25 Java Server Faces 2.0 (JSR 314) • Facelets as “templating language” for the page • Custom components much easier to develop • Integrated Ajax • “faces-config.xml” optional in common cases • Default navigation rules • Much more … • Runs on Servlet 2.5+ • Bookmarkable URLs • Conditional navigation • ...
  • 26. 26 Java Persistence API 2 (JSR 317) • Improved O/R mapping • Type-safe Criteria API • Expanded and Richer JPQL • 2nd-level Cache • New locking modes • PESSIMISTIC_READ – grab shared lock • PESSIMISTIC_WRITE – grab exclusive lock • PESSIMISTIC_FORCE_INCREMENT – update version • Standard configuration options • javax.persistence.jdbc.[driver | url | user | password]
  • 27. 27 Bean Validation (JSR 303) • Tier-independent mechanism to define constraints for data validation • Represented by annotations • javax.validation.* package • Integrated with JSF and JPA • JSF: f:validateRequired, f:validateRegexp • JPA: pre-persist, pre-update, and pre-remove • @NotNull(message=”...”), @Max, @Min, @Size • Fully Extensible • @Email String recipient;
  • 28. 28 JAX-RS 1.1 (JSR 311) • Java API for building RESTful Web Services • POJO based • Annotation-driven • Server-side API • HTTP-centric
  • 29. 29 JAX-RS 1.1 Code Sample - Simple public class HelloWorldResource { public String sayHello() { return "Hello World"; } public String morning() { return “Good Morning!”; } } @Path("helloworld") @Context UriInfo ui; @GET @Produces("text/plain") @GET @Path("morning")
  • 30. 30 IDE Support for Java EE 6
  • 31. 31 What does Java EE offer to Cloud ? ● Containers ● Injectable services ● Scale to large clusters ● Security model ● . . .
  • 32. 32 What can Java EE do for Clouds ? ● Tighter requirements for resource and state management ● Better isolation between applications ● Potential standard APIs for NRDBMS, Caching, … ● HTML5 ● Common management and monitoring interfaces ● Better packaging ● Apps/Data are (multiple) versioned, Upgrades, Expose/Connect to services, QoS attributes, ... ● Evolution, not revolution
  • 33. 33 What else is coming in JavaEE.next? • Modularity • Build on Java SE work • Applications made of modules • Dependencies are explicit • Versioning is built-in • Web socket support • Standard JSON API • HTML5 support • NIO.2-based web container
  • 34. 34 What is GlassFish ? • A community • Users, Partners, Testers, Developers, ... • Started in 2005 on java.net • Application Server • Open Source (CDDL & GPL v2) • Java EE Reference Implementation
  • 35. GlassFish Distributions Distribution License Features GlassFish Open Source Edition 3.0.1 CDDL & GPLv2 • Java EE 6 Compatibility • No Clustering • Clustering planned in 3.1 • mod_jk for load balancing GlassFish Open Source Edition 2.1.1 CDDL & GPLv2 • Java EE 5 Compatibility • In memory replication • mod_loadbalancer Oracle GlassFish Server 3.0.1 Commercial • GlassFish Open Source Edition 3.0.1 • GlassFish Server Control • Clustering planned in 3.1 Oracle GlassFish Server 2.1.1 Commercial • GlassFish Open Source Edition 2.1.1 • Enterprise Manager • HADB Clustering Coming Soon!
  • 38. 38 References • glassfish.org • oracle.com/goto/glassfish • blogs.sun.com/theaquarium • glassfish.org/roadmap • youtube.com/user/GlassFishVideos • Follow @glassfish
  • 39. <Insert Picture Here> What's new in Java EE 6 ? Arun Gupta blogs.sun.com/arungupta, @arungupta

Notas do Editor

  1. P2A: Can you talk about the ecosystem of compatible implementations? What has been the feedback of various vendors as they have gone through the EE 6 spec lifecycle? J2EE 1.4 Implementations (17) Apache BEA CAS Once Hitachi IBM JBoss Kingdee NEC ObjectWeb Oracle Pramati SAP Sun Sybase TmaxSoft TongTech Trifork
  2. P2A: Can you talk about the ecosystem of compatible implementations? What has been the feedback of various vendors as they have gone through the EE 6 spec lifecycle? J2EE 1.4 Implementations (17) Apache BEA CAS Once Hitachi IBM JBoss Kingdee NEC ObjectWeb Oracle Pramati SAP Sun Sybase TmaxSoft TongTech Trifork
  3. Paul talks to this slide. A2P: What are the major goals of the EE 6 Platform?
  4. &amp;lt;number&amp;gt;
  5. &amp;lt;number&amp;gt;