Java EE 6 Platform

Document Sample
Java EE 6 Platform Powered By Docstoc
					Java EE 6 Platform
   Roberto Chinnici
 Senior Staff Engineer
Sun Microsystems, Inc.
Overall Presentation Goal




        Learn about the direction,
     contents and overall theme of
          the Java EE 6 platform




                    www.javapolis.com
    Speaker’s Qualifications


   Roberto Chinnici is a Senior Staff Engineer
    at Sun Microsystems
   Roberto Chinnici is co-specification lead for
    the Java EE 6 platform (JSR-316)‫‏‬
   Roberto Chinnici speaks frequently on the
    Java Platform, Enterprise Edition, as well
    as web services and scripting




                        www.javapolis.com
    Agenda


   A look at Java EE over the years
   Goals for Java EE 6
   Component JSRs
   Timeline
   Community




                     www.javapolis.com
Remember Java EE 5 ?




                 www.javapolis.com
Java EE 5 Implementations




                   www.javapolis.com
  History of Enterprise Java
History of Enterprise Java                                         Ease of
                                                                 Development

                                                                 Java EE 5
                                                     Web           Ease of
                                                    Service      Development
                                                       s         Annotations
                                                   J2EE 1.4        EJB 3.0
                           `                          Web        Persistence
                           Robustness               Services,        API
                                                   Management     New and
              Enterprise   J2EE 1.3                     ,          Updated
                 Java         CMP,                 Deployment,   Web Services
               Platform     Connector                Async.
                           Architecture             Connector
              J2EE 1.2
               Servlet,
                JSP,
     JPE      EJB, JMS
    Project   RMI/IIOP



                 19 mo              21 mo
                               www.javapolis.com       26 mo         29 mo
Theme for Java EE 6




       Rightsizing the platform




                  www.javapolis.com
    What does “Rightsizing” mean?


   “Ease of development is good, but...
       ...the platform still looks too big!”
   Reduce size, without losing focus
   Make the platform fit well a particular
    class of applications
   Increase flexibility at deployment stage




                       www.javapolis.com
    New in Java EE 6


   Profiles
   Pruning
   Extensibility
   More ease of development




                       www.javapolis.com
    Profiles


   Rules set by the Java EE Platform spec
   Profiles can be subsets, supersets,
    overlapping
   Define immediately a Web Profile
        Focus on lightweight web applications
        Very powerful in conjunction with extensibility
   JCP process for future profiles




                            www.javapolis.com
    Pruning


   Make some components optional
   Send a strong signal to new applications
   Same rules proposed by Java SE
        “pruned now, optional in the next release”
   Likely candidates for Pruning
        EJB Entity Beans – Replaced by JPA
        JAX-RPC – Replaced by JAX-WS
        JAXR – Infrequently used
        JSR-88 – Infrequently used, not used by applications


                             www.javapolis.com
    Extensibility


   Embrace open source frameworks
        Especially in the web tier
   Simplify framework use/pluggability
   Clean layering, no discrimination
   E.g. scripting support via extensibility
        Ruby, JavaScript, JavaFX in the web tier




                            www.javapolis.com
    More ease of development


   No editing of web.xml
   More annotations, fewer descriptors
        e.g. @Servlet
   Easier packaging
        EJB component directly inside a war archive
   More APIs
        JAX-RS for RESTful web services




                           www.javapolis.com
 Servlet annotations


package com.foo;
@Servlet(name=”MyServlet”, urlPattern=”/myApp/*”)‫‏‬
public class MyServlet {
   public void doGet(HttpServletRequest req,
                           HttpServletResponse res)
{

       ...
   }
                                  Sun's current thinking on a Servlet
                                    annotation in Servlets 3.0 and
                                  Java EE 6. Servlet 3.0 expert group
                                    needs to work out and approve
                                             the specifics.



                       www.javapolis.com
  X
web.xml descriptor becomes optional


<!--Deployment descriptor web.xml -->
<web-app>
   <servlet>
      <servlet-name>MyServlet</servlet-name>
       <servlet-class>com.foo.MyServlet</servlet-class>
    </servlet>
    <servlet-mapping>
       <servlet-name>MyServlet
       </servlet-name>
       <url-pattern>/myApp/*
       </url-pattern>
    </servlet-mapping>
    ...
 </web-app>




                        www.javapolis.com
Adding an EJB to a web application

      Java EE 5 5
        Java EE                             Java EE 6

                ShoppingCart                 ShoppingCart
BuyBooks.war
                  EJB Class                   EJB Class


               ShoppingCart.jar



       BuyBooks.ear                          BuyBooks.war




                        www.javapolis.com
    Java EE 6 Support


   Overwhelming approval from JCP
    Executive Committee
        More YES votes than any recent JSR
   Support from new sources

     “Java EE 6 will be the most important
       release of the platform since it was
          released nearly 10 years ago”
                                                  Rod Johnson
                                               Inventor of Spring

                           www.javapolis.com
    New JSRs in Java EE 6


   EJB 3.1 (JSR 318)‫‏‬
   Java Persistence API 2.0 (JSR 317)‫‏‬
   Servlet 3.0 (JSR 315)‫‏‬
   JSF 2.0 (JSR 314)‫‏‬
   JAX-RS 1.0 (JSR 311)‫‏‬
   WebBeans 1.0 (JSR 299)‫‏‬
                                    Not finalized yet. The Java EE 6
                                     platform expert group has the
                                      final word on the contents.



                      www.javapolis.com
    Other updated components in Java EE 6


   Required foundation: Java SE 6
   Maintenance Releases (MRs):
        JAX-WS 2.2
        Implementing Enterprise Web Services 1.3 (JSR
         109)‫‏‬
        JSP 2.2
        Expression Language 1.2
   Already completed JSRs/MRs:
        JAXB 2.1 (JSR 222)‫‏‬
        Java Authentication Service Provider Interface for
         Containers (JSR 196)‫‏‬
                            www.javapolis.com
    Other JSRs on our radar


   Bean validation (JSR-303)‫‏‬
   Timer API (JSR-236)‫‏‬
   Work Manager API (JSR-237)‫‏‬




                       www.javapolis.com
    EJB 3.1 highlights


   Optional local interfaces
   Singletons
   EJB components in a web module
   Timer service enhancements
   Asynchronous session bean invocation
   Stateful web service endpoints
   Module-level component environment



                         www.javapolis.com
    JPA 2.0 highlights


   More flexible modeling capabilities
   Expanded O/R mapping
   Additions to the query language
   API for criteria queries
   Expanded pluggability contracts
   Validation




                         www.javapolis.com
    Servlet 3.0 highlights


   Web framework pluggability
   Asynchronous request processing
   Annotation-based programming model
   File upload
   Module-wide init parameters
   Alignment with JAX-RS 1.0 / JSF 2.0




                         www.javapolis.com
    JSF 2.0 highlights


   Easier to develop components
   More uses of annotations
   Declarative renderers
   Ajax support
   Packaging component resources in jars
   Software development lifecycle stages
   Alignments with JAX-RS 1.0



                         www.javapolis.com
    JAX-RS 1.0 highlights


   Annotation-based programming model
   Core API for power users
   Pluggable entity providers
   Integration with JPA
   Support for JSP/JSF as views
   Multiple containers




                        www.javapolis.com
    Schedule


   All JSRs approved and currently under way
   Milestones
        Q1 2008   Public review
        Q3 2008   Proposed final draft
        Q4 2008   RI beta release
        Q2 2009   Final release




                        www.javapolis.com
    Glassfish V3


   Java EE 6 reference implementation done
    as an open source project
   GlassFish being refactored (v3) to
    accommodate Java EE 6 Goals
        Modular, lighter, easier to develop with
   We would love to work together with you on
    Java EE 6!!

http://glassfish.dev.java.net


                            www.javapolis.com
    Summary


   Java EE 6 work is under way
   “Rightsizing” is the keyword
   Profiles, pruning, extensibility
   More ease of development




                       www.javapolis.com
Don't forget to...




            Participate!



                     www.javapolis.com
            Q&A
View JavaPolis talks @ www.parleys.com