SlideShare ist ein Scribd-Unternehmen logo
1 von 55
Downloaden Sie, um offline zu lesen
Java EE 7
Reaching for the Cloud
Lee Chuk Munn
chuk-munn.lee@oracle.com
The following 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.
Java EE 6 Platform
December 10, 2009
Great Tooling Support
Industry Wide Support
<Insert Picture Here>




Java EE 6
What is New in Java EE 6?
• Several new APIs
• Web profile
• Pluggability/extensibility
• Dependency injection
• Lots of improvements to existing API
New And Updated Components
• EJB 3.1 (+Lite)       • Managed Beans 1.0
• JPA 2.0               • Interceptors 1.1
• Servlet 3.0           • JSP 2.2
• JSF 2.0               • EL 2.2
• JAX-RS 1.1            • JSR-250 1.1
• Bean Validation 1.0   • JASPIC 1.1
• DI 1.0                • JACC 1.5
• CDI 1.0               • JAX-WS 2.2
• Connectors 1.6        • JSR-109 1.3
Java EE 6 Web Profile

             Web container                           JSP 2.2
              extensions
                                 JSF 2.0            JSTL 1.2
   CDI




                                                               Bean Validation 1.0
extensions
                             Servlet 3.0 · EL 2.2

    DI 1.0 · CDI 1.0 · Interceptors 1.1 · JSR-250 1.1

    Managed Beans 1.0                      EJB 3.1 Lite

                        JPA 2.0 · JTA 1.1
Web Tier Updates
• Annotations in Servlet 3.0
• Automatic discovery and registration of libraries
• web.xml is optional
• Package static files in resource jars
• Use EJBs directly inside web apps
Web Apps Simplified Packaging
    Web Application
WEB-INF/classes
 com/acme/MyServlet.class
 com/acme/MyFilter.class
WEB-INF/lib
 someframework.jar
WEB-INF/web.xml


index.html
main.css
jquery-1.4.2.js
ui/jquery.ui.core.js
ui/jquery.ui.widget.js
Web Apps Simplified Packaging
    Web Application
WEB-INF/classes             @WebServlet(urlPatterns=”/foo”)
 com/acme/MyServlet.class   public class MyServlet { … }
 com/acme/MyFilter.class
WEB-INF/lib                 @WebFilter(urlPatterns=”/foo”)
 someframework.jar          public class MyFilter { … }
WEB-INF/web.xml


index.html
main.css
jquery-1.4.2.js
ui/jquery.ui.core.js
ui/jquery.ui.widget.js
Web Apps Simplified Packaging
    Web Application
WEB-INF/classes
 com/acme/MyServlet.class
 com/acme/MyFilter.class     Framework Jar
WEB-INF/lib              META-INF/web-fragment.xml
 someframework.jar       com/fw/FwServlet.class
                         com/fw/FwFilter.class


index.html
main.css
jquery-1.4.2.js
ui/jquery.ui.core.js
ui/jquery.ui.widget.js
Web Apps Simplified Packaging
   Web Application
WEB-INF/classes
 com/acme/MyServlet.class
 com/acme/MyFilter.class
WEB-INF/lib
 someframework.jar
                             jQuery Resource Jar
 jquery-ui-1.8.4.jar    META-INF/resources/jquery-1.4.2.js
                        META-INF/resources/ui/jquery.ui.core.js
                        META-INF/resources/ui/jquery.ui.widget.js
index.html
main.css
Web Apps Simplified Packaging
   Web Application          • Self-contained

WEB-INF/classes             • Generic
 com/acme/MyServlet.class   • Reusable
 com/acme/MyFilter.class
WEB-INF/lib
 someframework.jar
 jquery-ui-1.8.4.jar



index.html
main.css
Java EE 6 Programming Model
• Complementary declarative/programmatic layer
• Annotations are additive
• Code can evolve gradually
• Managed beans as a common foundation
EJB 3.1 Lite
• Session bean programming model
• Stateless, singleton programming model
• Annotation based declarative security and
  transactions
• Deployment descriptors are optional
EJB 3.1 New First Class Construct
@Singleton @Startup
public class StartupBean {
 @PostConstruct
 public void doAtStartup() { … }
}

@Stateless public class BackupBean {
 @Schedule(dayOfWeek=”Fri”, hour=”3”, minute=”15”)
 public void performBackup() { … }
}

@Stateless public class BatchProcessor {
 @Asynchronous public Future<Result> submit(Task t){ … }
}
Dependency Injection
• Powerful type-safe model
• Can be enabled per-module
• Integrated with JSF, JSP, EJB, web tier
• Friendly to pre-Java EE 6 resources and services
• Event model
• Highly extensible
Bean with Constructor Injection

@RequestScoped
public class CheckoutHandler {
  @Inject
  public CheckoutHandler(
            @LoggedIn User user,
            @Reliable @PayBy(CREDIT_CARD)
            PaymentProcessor processor,
            @Default ShoppingCart cart) {…}
Bean with Constructor Injection

 @RequestScoped
 public class CheckoutHandler {
   @Inject
   public CheckoutHandler(
             @LoggedIn User user,
             @Reliable @PayBy(CREDIT_CARD)
Types
             PaymentProcessor processor,
             @Default ShoppingCart cart) {…}
Bean with Constructor Injection

  @RequestScoped
  public class CheckoutHandler {
      @Inject
      public CheckoutHandler(
               @LoggedIn User user,
               @Reliable @PayBy(CREDIT_CARD)
Qualifiers
               PaymentProcessor processor,
               @Default ShoppingCart cart) {…}
Bean with Constructor Injection
                               Request scoped
@RequestScoped
public class CheckoutHandler {
  @Inject
  public CheckoutHandler(
            @LoggedIn User user,
            @Reliable @PayBy(CREDIT_CARD)
            PaymentProcessor processor,
            @Default ShoppingCart cart) {…}
Bean with Constructor Injection

  @RequestScoped
  public class CheckoutHandler {
      @Inject
      public CheckoutHandler(
               @LoggedIn User user,
               @Reliable @PayBy(CREDIT_CARD)
Session scoped PaymentProcessor processor,
               @Default ShoppingCart cart) {…}
Bean with Constructor Injection

 @RequestScoped
 public class CheckoutHandler {
   @Inject
   public CheckoutHandler(
             @LoggedIn User user,
             @Reliable @PayBy(CREDIT_CARD)
             PaymentProcessor processor,
             @Default ShoppingCart cart) {…}
Application
scoped
Bean with Constructor Injection

@RequestScoped
public class CheckoutHandler {
  @Inject
  public CheckoutHandler(
            @LoggedIn User user,
            @Reliable @PayBy(CREDIT_CARD)
            PaymentProcessor processor,
            @Default ShoppingCart cart) {…}

   Conversation scoped
Java EE 7
 Cloudy Ahead
Layers of Cloud


  Software as a Service (SaaS)



  Platform as a Service (PaaS)



Infrastructure as a Service (IaaS)
Java EE and the Cloud
• Containers are back in vogue!
• We have containers
• We have services... injectable services...
• We scale to large clusters...
• We have a security model...
JSR 342 – Java EE for the Cloud
• More easily operate on public/private cloud
  – Multi tenancy, elasticiy
• Tighter requirements for resource and state
    management
•   Better isolation between applications
•   Potential standard APIs for NRDBMS, caching, etc.
•   Common management and monitoring interfaces
•   Evolving the platform
Better Packaging for the Cloud
• Applications should be versioned
• Multiple versions should be able to coexists
• Dealing with data versioning, upgrades, etc.
• Need the ability to specify QoS properties
• Exposed and connected to services
Cloud Platform

                  Application



  Java     Persistence     Queueing
 Service     Service        Service
                                      ...

              State Management

              Virtualization Layer
Cloud Platform

                           Application
 Code   Code   Code                                QoS
Module Module Module
                     Schema Migration Security
                                               Information         …


   Java           Persistence        Queueing
  Service           Service           Service
                                                             ...

                      State Management

                      Virtualization Layer
Cloud Platform


Application   Application   Application   Application   Application


   Java          Persistence         Queueing
  Service          Service            Service
                                                          ...

                      State Management

                      Virtualization Layer
Cloud Platform

                   Managed Environment

Application   Application   Application   Application   Application


   Java          Persistence         Queueing
  Service          Service            Service
                                                          ...

                      State Management

                      Virtualization Layer
Modularity
• Build on JavaSE 8 modularity
• Applications are composed of modules
• Dependencies are explicit
• Versioning is built-in
• Additional metadata for JavaEE
JavaSE 8 Modules
                                            com.foo.app
module-info.java
module com.foo @ 1.0.0 {    com.foo.extra
  class com.foo.app.Main
  requires com.foo.lib @ 2.1-alpha;         com.foo.lib
  provides com.foo.app.lib @ 1.0.0;
  requires optional com.foo.extra;
}


                                   org.bar.lib

                                            edu.baz.util
Packaging and Install
• Compiling Java classes with modules

$ javac -modulepath mods src/com.foo.app/...

• Packaging classes into modules

$ jpkg -modulepath mods jmod 
com.foo.app com.foo.extra com.foo.lib

• Installing modules into library

$ jmod -L mlib install 
  $EXT/edu.baz.util@*.jmod 
  $EXT/org.bar.lib@*.jmod
Modular Applications
 j1demo.app
   j1demo-1.0.3
Modular Applications
 j1demo.app               twitter-client-2.3.0
   j1demo-1.0.3
              requires   j1demo-persist-1.4.0
Modular Applications
 j1demo.app        twitter-client-2.3.0
   j1demo-1.0.3
                  j1demo-persist-1.4.0



 javaee-web-7.0                jpa-2.1    jax-rs-2.0
Modular Applications
 j1demo.app           twitter-client-2.3.0
   j1demo-1.0.3
                     j1demo-persist-1.4.0



 javaee-web-7.0                   jpa-2.1    jax-rs-2.0


        implements



 gf-appserv-4.01.


            ...
Modular Applications
 j1demo.app          twitter-client-2.3.0
   j1demo-1.0.3
                    j1demo-persist-1.4.0



 javaee-web-7.0                  jpa-2.1          jax-rs-2.0


                                     implements


 gf-appserv-4.01.          eclipselink-
                              2.1.3

            ...            jersey-2.0.5
Modular Applications
 j1demo.app          twitter-client-2.3.0    jax-rs-2.1
   j1demo-1.0.3
                    j1demo-persist-1.4.0    jersey-2.1.1



 javaee-web-7.0                  jpa-2.1




 gf-appserv-4.01.          eclipselink-
                              2.1.3

            ...
Modular Applications
 j1demo.app          twitter-client-2.3.0         jax-rs-2.1
   j1demo-1.0.3
                    j1demo-persist-1.4.0        jersey-2.1.1



 javaee-web-7.0                  jpa-2.1    jax-rs-2.1




 gf-appserv-4.01.          eclipselink-
                              2.1.3

            ...            jersey-2.1.1
<Insert Picture Here>




Status
Web Tier
• Web socket support in Servlet container
• Standard JSON API
• HTML5 support in JSF
• NIO2 based web container
• Updates to Web Profile
• JAX-RS 2.0 will be mandatory
New API
• Concurrency Utilities – JSR 236
   – Eg. transaction-, security- naming- aware ExecutorService
• JCache – JSR 107
   – Local cache API, key-value map
   – Needs to be aligned with JPA cache API
• JMS 2.0
   – Annotation based programming model to JMS
• JSON 1.0
• RESTful client API for JAX-RS 2.0
Java EE 7 JSRs Status
           Approved                    Ongoing
•   JPA 2.1                    • Concurrency Utilities 1.0
•   JAX-RS 2.0                 • JCache 1.0
•   Servlet 3.1
•   EL 3.0                             Yet to be filed
•   Platform 7/Web Profile 7   •   EJB 3.2
•   JMS 2.0                    •   CDI 1.1
•   JSF 2.2                    •   JSR-330 1.1
                               •   Bean Validation 1.1
                               •   JSON 1.0
Java EE 7 Schedule
• First seven JSRs already filed
• Remaining ones to be filed soon...
   – Stay tuned
• Final release late 2012
• Date driven release
   – Anything not ready will be deferred to Java EE 8
JavaEE 6 on the Cloud Today
JRockit Virtualized Edition
                      • Oracle JRockit VE runs
                       natively on hypervisor
                         – Better performance
                         – Improved security
                      • Deterministic GC
                        behaviour
                         – “Soft” real-time
                      • Simple administration
                         – Console and scripting
Java EE 6 Platform

Available from
http://www.oracle.com/javaee
Java EE 7
Reaching for the Cloud
Lee Chuk Munn
chuk-munn.lee@oracle.com

Weitere ähnliche Inhalte

Was ist angesagt?

Different Types of Containers in Spring
Different Types of Containers in Spring Different Types of Containers in Spring
Different Types of Containers in Spring Sunil kumar Mohanty
 
02 Hibernate Introduction
02 Hibernate Introduction02 Hibernate Introduction
02 Hibernate IntroductionRanjan Kumar
 
Types of Dependency Injection in Spring
Types of Dependency Injection in SpringTypes of Dependency Injection in Spring
Types of Dependency Injection in SpringSunil kumar Mohanty
 
Indic threads pune12-java ee 7 platformsimplification html5
Indic threads pune12-java ee 7 platformsimplification html5Indic threads pune12-java ee 7 platformsimplification html5
Indic threads pune12-java ee 7 platformsimplification html5IndicThreads
 
Testing Your Application On Google App Engine
Testing Your Application On Google App EngineTesting Your Application On Google App Engine
Testing Your Application On Google App EngineIndicThreads
 
Hibernate Interview Questions
Hibernate Interview QuestionsHibernate Interview Questions
Hibernate Interview QuestionsSyed Shahul
 
Spring 4 advanced final_xtr_presentation
Spring 4 advanced final_xtr_presentationSpring 4 advanced final_xtr_presentation
Spring 4 advanced final_xtr_presentationsourabh aggarwal
 
Java EE 7: Whats New in the Java EE Platform @ Devoxx 2013
Java EE 7: Whats New in the Java EE Platform @ Devoxx 2013Java EE 7: Whats New in the Java EE Platform @ Devoxx 2013
Java EE 7: Whats New in the Java EE Platform @ Devoxx 2013Arun Gupta
 
Hibernate Developer Reference
Hibernate Developer ReferenceHibernate Developer Reference
Hibernate Developer ReferenceMuthuselvam RS
 
Lecture 3: Servlets - Session Management
Lecture 3:  Servlets - Session ManagementLecture 3:  Servlets - Session Management
Lecture 3: Servlets - Session ManagementFahad Golra
 
24 collections framework interview questions
24 collections framework interview questions24 collections framework interview questions
24 collections framework interview questionsArun Vasanth
 
Java interview-questions-and-answers
Java interview-questions-and-answersJava interview-questions-and-answers
Java interview-questions-and-answersbestonlinetrainers
 
Introduction to JPA and Hibernate including examples
Introduction to JPA and Hibernate including examplesIntroduction to JPA and Hibernate including examples
Introduction to JPA and Hibernate including examplesecosio GmbH
 
Bea weblogic job_interview_preparation_guide
Bea weblogic job_interview_preparation_guideBea weblogic job_interview_preparation_guide
Bea weblogic job_interview_preparation_guidePankaj Singh
 

Was ist angesagt? (17)

Different Types of Containers in Spring
Different Types of Containers in Spring Different Types of Containers in Spring
Different Types of Containers in Spring
 
02 Hibernate Introduction
02 Hibernate Introduction02 Hibernate Introduction
02 Hibernate Introduction
 
Types of Dependency Injection in Spring
Types of Dependency Injection in SpringTypes of Dependency Injection in Spring
Types of Dependency Injection in Spring
 
Java Programming - 01 intro to java
Java Programming - 01 intro to javaJava Programming - 01 intro to java
Java Programming - 01 intro to java
 
Indic threads pune12-java ee 7 platformsimplification html5
Indic threads pune12-java ee 7 platformsimplification html5Indic threads pune12-java ee 7 platformsimplification html5
Indic threads pune12-java ee 7 platformsimplification html5
 
Java Enterprise Edition
Java Enterprise EditionJava Enterprise Edition
Java Enterprise Edition
 
Testing Your Application On Google App Engine
Testing Your Application On Google App EngineTesting Your Application On Google App Engine
Testing Your Application On Google App Engine
 
Hibernate Interview Questions
Hibernate Interview QuestionsHibernate Interview Questions
Hibernate Interview Questions
 
Spring 4 advanced final_xtr_presentation
Spring 4 advanced final_xtr_presentationSpring 4 advanced final_xtr_presentation
Spring 4 advanced final_xtr_presentation
 
Java EE 7: Whats New in the Java EE Platform @ Devoxx 2013
Java EE 7: Whats New in the Java EE Platform @ Devoxx 2013Java EE 7: Whats New in the Java EE Platform @ Devoxx 2013
Java EE 7: Whats New in the Java EE Platform @ Devoxx 2013
 
Java Programming - 08 java threading
Java Programming - 08 java threadingJava Programming - 08 java threading
Java Programming - 08 java threading
 
Hibernate Developer Reference
Hibernate Developer ReferenceHibernate Developer Reference
Hibernate Developer Reference
 
Lecture 3: Servlets - Session Management
Lecture 3:  Servlets - Session ManagementLecture 3:  Servlets - Session Management
Lecture 3: Servlets - Session Management
 
24 collections framework interview questions
24 collections framework interview questions24 collections framework interview questions
24 collections framework interview questions
 
Java interview-questions-and-answers
Java interview-questions-and-answersJava interview-questions-and-answers
Java interview-questions-and-answers
 
Introduction to JPA and Hibernate including examples
Introduction to JPA and Hibernate including examplesIntroduction to JPA and Hibernate including examples
Introduction to JPA and Hibernate including examples
 
Bea weblogic job_interview_preparation_guide
Bea weblogic job_interview_preparation_guideBea weblogic job_interview_preparation_guide
Bea weblogic job_interview_preparation_guide
 

Ähnlich wie Java EE 與 雲端運算的展望

The Java EE 7 Platform: Developing for the Cloud (FISL 12)
The Java EE 7 Platform: Developing for the Cloud  (FISL 12)The Java EE 7 Platform: Developing for the Cloud  (FISL 12)
The Java EE 7 Platform: Developing for the Cloud (FISL 12)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
 
Java ee 8 + security overview
Java ee 8 + security overviewJava ee 8 + security overview
Java ee 8 + security overviewRudy De Busscher
 
Contextual Dependency Injection for Apachecon 2010
Contextual Dependency Injection for Apachecon 2010Contextual Dependency Injection for Apachecon 2010
Contextual Dependency Injection for Apachecon 2010Rohit Kelapure
 
InterConnect 2016 Java EE 7 Overview (PEJ-5296)
InterConnect 2016 Java EE 7 Overview (PEJ-5296)InterConnect 2016 Java EE 7 Overview (PEJ-5296)
InterConnect 2016 Java EE 7 Overview (PEJ-5296)Kevin Sutter
 
Summer training java
Summer training javaSummer training java
Summer training javaArshit Rai
 
Summer training java
Summer training javaSummer training java
Summer training javaArshit Rai
 
Java EE 6, Eclipse @ EclipseCon
Java EE 6, Eclipse @ EclipseConJava EE 6, Eclipse @ EclipseCon
Java EE 6, Eclipse @ EclipseConLudovic Champenois
 
Lecture 19 dynamic web - java - part 1
Lecture 19   dynamic web - java - part 1Lecture 19   dynamic web - java - part 1
Lecture 19 dynamic web - java - part 1Д. Ганаа
 
Lecture 19 - Dynamic Web - JAVA - Part 1.ppt
Lecture 19 - Dynamic Web - JAVA - Part 1.pptLecture 19 - Dynamic Web - JAVA - Part 1.ppt
Lecture 19 - Dynamic Web - JAVA - Part 1.pptKalsoomTahir2
 
Overview of Java EE 6 by Roberto Chinnici at SFJUG
Overview of Java EE 6 by Roberto Chinnici at SFJUGOverview of Java EE 6 by Roberto Chinnici at SFJUG
Overview of Java EE 6 by Roberto Chinnici at SFJUGMarakana Inc.
 
Powering the Next Generation Services with Java Platform - Spark IT 2010
Powering the Next Generation Services with Java Platform - Spark IT 2010Powering the Next Generation Services with Java Platform - Spark IT 2010
Powering the Next Generation Services with Java Platform - Spark IT 2010Arun Gupta
 
SPEC INDIA Java Case Study
SPEC INDIA Java Case StudySPEC INDIA Java Case Study
SPEC INDIA Java Case StudySPEC INDIA
 
Java one brazil_keynote_dochez
Java one brazil_keynote_dochezJava one brazil_keynote_dochez
Java one brazil_keynote_dochezJerome Dochez
 
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
 
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
 
Intorduction to struts
Intorduction to strutsIntorduction to struts
Intorduction to strutsAnup72
 
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 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
 

Ähnlich wie Java EE 與 雲端運算的展望 (20)

The Java EE 7 Platform: Developing for the Cloud (FISL 12)
The Java EE 7 Platform: Developing for the Cloud  (FISL 12)The Java EE 7 Platform: Developing for the Cloud  (FISL 12)
The Java EE 7 Platform: Developing for the Cloud (FISL 12)
 
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
 
Java ee 8 + security overview
Java ee 8 + security overviewJava ee 8 + security overview
Java ee 8 + security overview
 
Contextual Dependency Injection for Apachecon 2010
Contextual Dependency Injection for Apachecon 2010Contextual Dependency Injection for Apachecon 2010
Contextual Dependency Injection for Apachecon 2010
 
InterConnect 2016 Java EE 7 Overview (PEJ-5296)
InterConnect 2016 Java EE 7 Overview (PEJ-5296)InterConnect 2016 Java EE 7 Overview (PEJ-5296)
InterConnect 2016 Java EE 7 Overview (PEJ-5296)
 
Summer training java
Summer training javaSummer training java
Summer training java
 
Summer training java
Summer training javaSummer training java
Summer training java
 
Java EE 6, Eclipse @ EclipseCon
Java EE 6, Eclipse @ EclipseConJava EE 6, Eclipse @ EclipseCon
Java EE 6, Eclipse @ EclipseCon
 
Lecture 19 dynamic web - java - part 1
Lecture 19   dynamic web - java - part 1Lecture 19   dynamic web - java - part 1
Lecture 19 dynamic web - java - part 1
 
Lecture 19 - Dynamic Web - JAVA - Part 1.ppt
Lecture 19 - Dynamic Web - JAVA - Part 1.pptLecture 19 - Dynamic Web - JAVA - Part 1.ppt
Lecture 19 - Dynamic Web - JAVA - Part 1.ppt
 
Overview of Java EE 6 by Roberto Chinnici at SFJUG
Overview of Java EE 6 by Roberto Chinnici at SFJUGOverview of Java EE 6 by Roberto Chinnici at SFJUG
Overview of Java EE 6 by Roberto Chinnici at SFJUG
 
Powering the Next Generation Services with Java Platform - Spark IT 2010
Powering the Next Generation Services with Java Platform - Spark IT 2010Powering the Next Generation Services with Java Platform - Spark IT 2010
Powering the Next Generation Services with Java Platform - Spark IT 2010
 
4. J2EE.pptx
4. J2EE.pptx4. J2EE.pptx
4. J2EE.pptx
 
SPEC INDIA Java Case Study
SPEC INDIA Java Case StudySPEC INDIA Java Case Study
SPEC INDIA Java Case Study
 
Java one brazil_keynote_dochez
Java one brazil_keynote_dochezJava one brazil_keynote_dochez
Java one brazil_keynote_dochez
 
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
 
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
 
Intorduction to struts
Intorduction to strutsIntorduction to struts
Intorduction to struts
 
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 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
 

Kürzlich hochgeladen

Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityWSO2
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Angeliki Cooney
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistandanishmna97
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Bhuvaneswari Subramani
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesrafiqahmad00786416
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Orbitshub
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontologyjohnbeverley2021
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 

Kürzlich hochgeladen (20)

Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​Elevate Developer Efficiency & build GenAI Application with Amazon Q​
Elevate Developer Efficiency & build GenAI Application with Amazon Q​
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 

Java EE 與 雲端運算的展望

  • 1.
  • 2. Java EE 7 Reaching for the Cloud Lee Chuk Munn chuk-munn.lee@oracle.com
  • 3. The following 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.
  • 4. Java EE 6 Platform December 10, 2009
  • 8. What is New in Java EE 6? • Several new APIs • Web profile • Pluggability/extensibility • Dependency injection • Lots of improvements to existing API
  • 9. New And Updated Components • EJB 3.1 (+Lite) • Managed Beans 1.0 • JPA 2.0 • Interceptors 1.1 • Servlet 3.0 • JSP 2.2 • JSF 2.0 • EL 2.2 • JAX-RS 1.1 • JSR-250 1.1 • Bean Validation 1.0 • JASPIC 1.1 • DI 1.0 • JACC 1.5 • CDI 1.0 • JAX-WS 2.2 • Connectors 1.6 • JSR-109 1.3
  • 10. Java EE 6 Web Profile Web container JSP 2.2 extensions JSF 2.0 JSTL 1.2 CDI Bean Validation 1.0 extensions Servlet 3.0 · EL 2.2 DI 1.0 · CDI 1.0 · Interceptors 1.1 · JSR-250 1.1 Managed Beans 1.0 EJB 3.1 Lite JPA 2.0 · JTA 1.1
  • 11. Web Tier Updates • Annotations in Servlet 3.0 • Automatic discovery and registration of libraries • web.xml is optional • Package static files in resource jars • Use EJBs directly inside web apps
  • 12. Web Apps Simplified Packaging Web Application WEB-INF/classes com/acme/MyServlet.class com/acme/MyFilter.class WEB-INF/lib someframework.jar WEB-INF/web.xml index.html main.css jquery-1.4.2.js ui/jquery.ui.core.js ui/jquery.ui.widget.js
  • 13. Web Apps Simplified Packaging Web Application WEB-INF/classes @WebServlet(urlPatterns=”/foo”) com/acme/MyServlet.class public class MyServlet { … } com/acme/MyFilter.class WEB-INF/lib @WebFilter(urlPatterns=”/foo”) someframework.jar public class MyFilter { … } WEB-INF/web.xml index.html main.css jquery-1.4.2.js ui/jquery.ui.core.js ui/jquery.ui.widget.js
  • 14. Web Apps Simplified Packaging Web Application WEB-INF/classes com/acme/MyServlet.class com/acme/MyFilter.class Framework Jar WEB-INF/lib META-INF/web-fragment.xml someframework.jar com/fw/FwServlet.class com/fw/FwFilter.class index.html main.css jquery-1.4.2.js ui/jquery.ui.core.js ui/jquery.ui.widget.js
  • 15. Web Apps Simplified Packaging Web Application WEB-INF/classes com/acme/MyServlet.class com/acme/MyFilter.class WEB-INF/lib someframework.jar jQuery Resource Jar jquery-ui-1.8.4.jar META-INF/resources/jquery-1.4.2.js META-INF/resources/ui/jquery.ui.core.js META-INF/resources/ui/jquery.ui.widget.js index.html main.css
  • 16. Web Apps Simplified Packaging Web Application • Self-contained WEB-INF/classes • Generic com/acme/MyServlet.class • Reusable com/acme/MyFilter.class WEB-INF/lib someframework.jar jquery-ui-1.8.4.jar index.html main.css
  • 17. Java EE 6 Programming Model • Complementary declarative/programmatic layer • Annotations are additive • Code can evolve gradually • Managed beans as a common foundation
  • 18. EJB 3.1 Lite • Session bean programming model • Stateless, singleton programming model • Annotation based declarative security and transactions • Deployment descriptors are optional
  • 19. EJB 3.1 New First Class Construct @Singleton @Startup public class StartupBean { @PostConstruct public void doAtStartup() { … } } @Stateless public class BackupBean { @Schedule(dayOfWeek=”Fri”, hour=”3”, minute=”15”) public void performBackup() { … } } @Stateless public class BatchProcessor { @Asynchronous public Future<Result> submit(Task t){ … } }
  • 20. Dependency Injection • Powerful type-safe model • Can be enabled per-module • Integrated with JSF, JSP, EJB, web tier • Friendly to pre-Java EE 6 resources and services • Event model • Highly extensible
  • 21. Bean with Constructor Injection @RequestScoped public class CheckoutHandler { @Inject public CheckoutHandler( @LoggedIn User user, @Reliable @PayBy(CREDIT_CARD) PaymentProcessor processor, @Default ShoppingCart cart) {…}
  • 22. Bean with Constructor Injection @RequestScoped public class CheckoutHandler { @Inject public CheckoutHandler( @LoggedIn User user, @Reliable @PayBy(CREDIT_CARD) Types PaymentProcessor processor, @Default ShoppingCart cart) {…}
  • 23. Bean with Constructor Injection @RequestScoped public class CheckoutHandler { @Inject public CheckoutHandler( @LoggedIn User user, @Reliable @PayBy(CREDIT_CARD) Qualifiers PaymentProcessor processor, @Default ShoppingCart cart) {…}
  • 24. Bean with Constructor Injection Request scoped @RequestScoped public class CheckoutHandler { @Inject public CheckoutHandler( @LoggedIn User user, @Reliable @PayBy(CREDIT_CARD) PaymentProcessor processor, @Default ShoppingCart cart) {…}
  • 25. Bean with Constructor Injection @RequestScoped public class CheckoutHandler { @Inject public CheckoutHandler( @LoggedIn User user, @Reliable @PayBy(CREDIT_CARD) Session scoped PaymentProcessor processor, @Default ShoppingCart cart) {…}
  • 26. Bean with Constructor Injection @RequestScoped public class CheckoutHandler { @Inject public CheckoutHandler( @LoggedIn User user, @Reliable @PayBy(CREDIT_CARD) PaymentProcessor processor, @Default ShoppingCart cart) {…} Application scoped
  • 27. Bean with Constructor Injection @RequestScoped public class CheckoutHandler { @Inject public CheckoutHandler( @LoggedIn User user, @Reliable @PayBy(CREDIT_CARD) PaymentProcessor processor, @Default ShoppingCart cart) {…} Conversation scoped
  • 28. Java EE 7 Cloudy Ahead
  • 29. Layers of Cloud Software as a Service (SaaS) Platform as a Service (PaaS) Infrastructure as a Service (IaaS)
  • 30. Java EE and the Cloud • Containers are back in vogue! • We have containers • We have services... injectable services... • We scale to large clusters... • We have a security model...
  • 31. JSR 342 – Java EE for the Cloud • More easily operate on public/private cloud – Multi tenancy, elasticiy • Tighter requirements for resource and state management • Better isolation between applications • Potential standard APIs for NRDBMS, caching, etc. • Common management and monitoring interfaces • Evolving the platform
  • 32. Better Packaging for the Cloud • Applications should be versioned • Multiple versions should be able to coexists • Dealing with data versioning, upgrades, etc. • Need the ability to specify QoS properties • Exposed and connected to services
  • 33. Cloud Platform Application Java Persistence Queueing Service Service Service ... State Management Virtualization Layer
  • 34. Cloud Platform Application Code Code Code QoS Module Module Module Schema Migration Security Information … Java Persistence Queueing Service Service Service ... State Management Virtualization Layer
  • 35. Cloud Platform Application Application Application Application Application Java Persistence Queueing Service Service Service ... State Management Virtualization Layer
  • 36. Cloud Platform Managed Environment Application Application Application Application Application Java Persistence Queueing Service Service Service ... State Management Virtualization Layer
  • 37. Modularity • Build on JavaSE 8 modularity • Applications are composed of modules • Dependencies are explicit • Versioning is built-in • Additional metadata for JavaEE
  • 38. JavaSE 8 Modules com.foo.app module-info.java module com.foo @ 1.0.0 { com.foo.extra class com.foo.app.Main requires com.foo.lib @ 2.1-alpha; com.foo.lib provides com.foo.app.lib @ 1.0.0; requires optional com.foo.extra; } org.bar.lib edu.baz.util
  • 39. Packaging and Install • Compiling Java classes with modules $ javac -modulepath mods src/com.foo.app/... • Packaging classes into modules $ jpkg -modulepath mods jmod com.foo.app com.foo.extra com.foo.lib • Installing modules into library $ jmod -L mlib install $EXT/edu.baz.util@*.jmod $EXT/org.bar.lib@*.jmod
  • 41. Modular Applications j1demo.app twitter-client-2.3.0 j1demo-1.0.3 requires j1demo-persist-1.4.0
  • 42. Modular Applications j1demo.app twitter-client-2.3.0 j1demo-1.0.3 j1demo-persist-1.4.0 javaee-web-7.0 jpa-2.1 jax-rs-2.0
  • 43. Modular Applications j1demo.app twitter-client-2.3.0 j1demo-1.0.3 j1demo-persist-1.4.0 javaee-web-7.0 jpa-2.1 jax-rs-2.0 implements gf-appserv-4.01. ...
  • 44. Modular Applications j1demo.app twitter-client-2.3.0 j1demo-1.0.3 j1demo-persist-1.4.0 javaee-web-7.0 jpa-2.1 jax-rs-2.0 implements gf-appserv-4.01. eclipselink- 2.1.3 ... jersey-2.0.5
  • 45. Modular Applications j1demo.app twitter-client-2.3.0 jax-rs-2.1 j1demo-1.0.3 j1demo-persist-1.4.0 jersey-2.1.1 javaee-web-7.0 jpa-2.1 gf-appserv-4.01. eclipselink- 2.1.3 ...
  • 46. Modular Applications j1demo.app twitter-client-2.3.0 jax-rs-2.1 j1demo-1.0.3 j1demo-persist-1.4.0 jersey-2.1.1 javaee-web-7.0 jpa-2.1 jax-rs-2.1 gf-appserv-4.01. eclipselink- 2.1.3 ... jersey-2.1.1
  • 48. Web Tier • Web socket support in Servlet container • Standard JSON API • HTML5 support in JSF • NIO2 based web container • Updates to Web Profile • JAX-RS 2.0 will be mandatory
  • 49. New API • Concurrency Utilities – JSR 236 – Eg. transaction-, security- naming- aware ExecutorService • JCache – JSR 107 – Local cache API, key-value map – Needs to be aligned with JPA cache API • JMS 2.0 – Annotation based programming model to JMS • JSON 1.0 • RESTful client API for JAX-RS 2.0
  • 50. Java EE 7 JSRs Status Approved Ongoing • JPA 2.1 • Concurrency Utilities 1.0 • JAX-RS 2.0 • JCache 1.0 • Servlet 3.1 • EL 3.0 Yet to be filed • Platform 7/Web Profile 7 • EJB 3.2 • JMS 2.0 • CDI 1.1 • JSF 2.2 • JSR-330 1.1 • Bean Validation 1.1 • JSON 1.0
  • 51. Java EE 7 Schedule • First seven JSRs already filed • Remaining ones to be filed soon... – Stay tuned • Final release late 2012 • Date driven release – Anything not ready will be deferred to Java EE 8
  • 52. JavaEE 6 on the Cloud Today
  • 53. JRockit Virtualized Edition • Oracle JRockit VE runs natively on hypervisor – Better performance – Improved security • Deterministic GC behaviour – “Soft” real-time • Simple administration – Console and scripting
  • 54. Java EE 6 Platform Available from http://www.oracle.com/javaee
  • 55. Java EE 7 Reaching for the Cloud Lee Chuk Munn chuk-munn.lee@oracle.com