SlideShare a Scribd company logo
Aleš Justin, JBoss by RedHat


        JavaEE and
        Google AppEngine

Tuesday, April 12, 2011
Agenda

        • What is GAE and CDI?
        • Why GAE and CDI?
        • Other JavaEE technologies
        • Development vs. Production
        • Problems vs. Solutions
        • Testing
        •Q & A
Tuesday, April 12, 2011
About me


        • Old school JBoss-ian
           • Microcontainer co-author
           • Weld lead
           • RHT Cloud “guinea pig”
        • Eager PaaS user
           • While still GAE amateur

Tuesday, April 12, 2011
GAE


        • Forked Jetty
        • Many (logical) restrictions
        • RDBMS → BigTable
        • Simple Map(Reduce)
        • Good administration
        • Free basic usage

Tuesday, April 12, 2011
CDI

        • Context and Dependency Injection
        • JSR-299 → JBoss Weld RI
        • “type-safe” programming
        • “contexts” concept
        • Easy to extend: “Extensions”
            • “Using CDI Extensions to Make a
              Better Java EE ” at 18:00
Tuesday, April 12, 2011
Why GAE and CDI?


        • Simple reason: sandbox app
        • Android app with server back-end
           • Tattletale (Tožibaba)
        • Zero administration / configuration
        • Reliable up-time
        • No more “boiler-plate” code → CDI

Tuesday, April 12, 2011
CDI #2

        • @Inject             • @Observes
        • @Qualifier          • @ConversationS.
        • @Named              • @Decorator
        • @Scope              • @Alternative
        • Interceptors        • @Sterotype
        • InjectionPoint
        • Instance            • Pete and Dan’s
        • @Produces             yday tutorial!
Tuesday, April 12, 2011
Other technologies


        • JPA
        • JSF2
        • BeanValidation
        • javax.cache
        • JSON
        • ShrinkWrap + Arquillian

Tuesday, April 12, 2011
Project Kick-Off

        • Know (all) restrictions!
           • 30sec, white-list, no threads, ...
        • How portable should my app be?
        • Development vs. Production Env!
        • Frameworks have problems
           • But they mostly have (easy)
             solutions → fork?
Tuesday, April 12, 2011
The Goal


        • Abstract away GAE API
           • Pure JavaEE
           • Port app to JBossAS (6 & 7)
        • Use CDI as much as possible
        • Test it all, same as other JavaEE apps

Tuesday, April 12, 2011
Initial problems
                                               Proxy




                                        Bean


        • CDI
           • “Entry” mechanism
           • Request / response binding
           • Lack of “lifecycle” handling


Tuesday, April 12, 2011
Initial problems

        • JPA
           • Limited relationships (Entity groups)
              • Proxying layer vs. Custom “ORM”
           • Transaction per “Entity group”
           • Old DataNucleus version
           • Long vs. Key entity key
           • “Enhanced” entities
           • GeoModel hashing queries (“IN”)
Tuesday, April 12, 2011
Initial problems


        • JSF2
           • Context parameter settings
           • “new InitialContext” patch
           • “built-in” EL 1.0 → workaround


Tuesday, April 12, 2011
Initial problems


        • BeanValidation
           • Static usage with JPA
           • Size
           • Configuration


Tuesday, April 12, 2011
Initial problems

        • javax.cache (GCache)
           • No partition
           • NUCCORE-540 → fork
        • JSON
           • Different versions; client vs. server
        • Arquillian
           • Missing GAE container
Tuesday, April 12, 2011
“Production” problems


        • CDI
           • “Bean scanning” → exact listing
           • “Lazy beans” → MVC re-write
           • GZIP + Base64 usage
           • “Fall-back / repeat” mechanism

Tuesday, April 12, 2011
“Production” problems

        • JPA
            • Explicit entity listing
            • Maximize cache usage
            • “Caching” → Lazy EMF
        • javax.cache
            • serialVersionUID
            • Non-primitive variables
            • Cache evict / clear mechanism
Tuesday, April 12, 2011
Testing


        • ShrinkWrap
           • Binaries abstraction
        • Arquillian
           • Runtime / Env abstraction
           • https://github.com/alesj/arquillian

Tuesday, April 12, 2011
Tattletale

        • Lhotse POC
             • https://github.com/alesj/lhotse
  Lhotse

                          Server-API                    Tattletale




      Server-GAE                       Server-JEE




Tuesday, April 12, 2011
Q&A

            ales.justin@jboss.org




Tuesday, April 12, 2011

More Related Content

KEY
Fun with EJB 3.1 and Open EJB
PPTX
Java EE 8
PPTX
Preparing for java 9 modules upload
PDF
Deploying Web Applications with WildFly 8
PDF
Social Connections 2015 CrossWorlds and Domino
PDF
Eureka Moment UKLUG
PDF
Java EE 6 Clustering with Glassfish 3.1
PDF
Boston 2011 OTN Developer Days - GlassFish
Fun with EJB 3.1 and Open EJB
Java EE 8
Preparing for java 9 modules upload
Deploying Web Applications with WildFly 8
Social Connections 2015 CrossWorlds and Domino
Eureka Moment UKLUG
Java EE 6 Clustering with Glassfish 3.1
Boston 2011 OTN Developer Days - GlassFish

What's hot (20)

ODP
Eureka moment
PDF
GlassFish 3.1 – Simplifying your Java EE 6 Development and Deployment @ JAX L...
KEY
LatJUG. JSF2.0 - The JavaEE6 Standard
PPTX
XPages and Java (DanNotes 50th conference, November 2013)
PDF
Just enough app server
PDF
GlassFish Server 3.1: Deploying your Java EE 6 Applications
PDF
Liberty: The Right Fit for Micro Profile?
PDF
OSGi Community Event 2010 - OSGi and Android
PDF
Java EE Servlet/JSP Tutorial- Cookbook 2
PDF
Access Data from XPages with the Relational Controls
PDF
Java 8 in Anger (JavaOne)
PDF
Deploying Java EE 6 Apps in a Cluster: GlassFish 3.1 at Dallas Tech Fest 2011
PDF
Java EE | Apache TomEE - Java EE Web Profile on Tomcat | Jonathan Gallimore
PPTX
Workshop Framework(J2EE/OSGi/RCP)
PDF
Better Career with Java
PDF
Container Landscape in 2017
PPT
Introduction tomaven
PPTX
Developing in the Cloud
PPTX
[DanNotes] XPages - Beyound the Basics
PPT
Play framework
Eureka moment
GlassFish 3.1 – Simplifying your Java EE 6 Development and Deployment @ JAX L...
LatJUG. JSF2.0 - The JavaEE6 Standard
XPages and Java (DanNotes 50th conference, November 2013)
Just enough app server
GlassFish Server 3.1: Deploying your Java EE 6 Applications
Liberty: The Right Fit for Micro Profile?
OSGi Community Event 2010 - OSGi and Android
Java EE Servlet/JSP Tutorial- Cookbook 2
Access Data from XPages with the Relational Controls
Java 8 in Anger (JavaOne)
Deploying Java EE 6 Apps in a Cluster: GlassFish 3.1 at Dallas Tech Fest 2011
Java EE | Apache TomEE - Java EE Web Profile on Tomcat | Jonathan Gallimore
Workshop Framework(J2EE/OSGi/RCP)
Better Career with Java
Container Landscape in 2017
Introduction tomaven
Developing in the Cloud
[DanNotes] XPages - Beyound the Basics
Play framework
Ad

Similar to Java EE and Google App Engine (20)

PDF
2011 june-kuala-lumpur-gtug-hackathon
PDF
A new world with cdi en
PDF
Andy Bosch - JavaServer Faces in the cloud
PDF
Extending Spring for Custom Usage
PDF
2011 JavaOne Fun with EJB 3.1 and OpenEJB
PDF
Integrallis groovy-cloud
PDF
Java EE Technical Keynote - JavaOne India 2011
PDF
Automatically generating-json-from-java-objects-java-objects268
PDF
Developer Productivity with Forge, Java EE 6 and Arquillian
PDF
What's New in GWT 2.2
PDF
CloudConf2011 Introduction to Google App Engine
PDF
Java EE 6 workshop at Dallas Tech Fest 2011
PDF
Intro to App Engine - Agency Dev Day NYC 2011
PDF
Railsconf 2010
ODP
Enterprise Java in 2012 and Beyond, by Juergen Hoeller
PDF
J2EE Introduction
PDF
2012 04-06-v2-tdp-1163-java e-evsspringshootout-final
PDF
The spring 32 update final
PDF
JBoss AS 7 from a user perspective
PDF
Jsf+ejb 50
2011 june-kuala-lumpur-gtug-hackathon
A new world with cdi en
Andy Bosch - JavaServer Faces in the cloud
Extending Spring for Custom Usage
2011 JavaOne Fun with EJB 3.1 and OpenEJB
Integrallis groovy-cloud
Java EE Technical Keynote - JavaOne India 2011
Automatically generating-json-from-java-objects-java-objects268
Developer Productivity with Forge, Java EE 6 and Arquillian
What's New in GWT 2.2
CloudConf2011 Introduction to Google App Engine
Java EE 6 workshop at Dallas Tech Fest 2011
Intro to App Engine - Agency Dev Day NYC 2011
Railsconf 2010
Enterprise Java in 2012 and Beyond, by Juergen Hoeller
J2EE Introduction
2012 04-06-v2-tdp-1163-java e-evsspringshootout-final
The spring 32 update final
JBoss AS 7 from a user perspective
Jsf+ejb 50
Ad

More from Arun Gupta (20)

PDF
5 Skills To Force Multiply Technical Talents.pdf
PPTX
Machine Learning using Kubernetes - AI Conclave 2019
PDF
Machine Learning using Kubeflow and Kubernetes
PPTX
Secure and Fast microVM for Serverless Computing using Firecracker
PPTX
Building Java in the Open - j.Day at OSCON 2019
PPTX
Why Amazon Cares about Open Source
PDF
Machine learning using Kubernetes
PDF
Building Cloud Native Applications
PDF
Chaos Engineering with Kubernetes
PDF
How to be a mentor to bring more girls to STEAM
PDF
Java in a World of Containers - DockerCon 2018
PPTX
The Serverless Tidal Wave - SwampUP 2018 Keynote
PDF
Introduction to Amazon EKS - KubeCon 2018
PDF
Mastering Kubernetes on AWS - Tel Aviv Summit
PDF
Top 10 Technology Trends Changing Developer's Landscape
PDF
Java EE and NoSQL using JBoss EAP 7 and OpenShift
PDF
Docker, Kubernetes, and Mesos recipes for Java developers
PDF
Thanks Managers!
PDF
Migrate your traditional VM-based Clusters to Containers
PDF
NoSQL - Vital Open Source Ingredient for Modern Success
5 Skills To Force Multiply Technical Talents.pdf
Machine Learning using Kubernetes - AI Conclave 2019
Machine Learning using Kubeflow and Kubernetes
Secure and Fast microVM for Serverless Computing using Firecracker
Building Java in the Open - j.Day at OSCON 2019
Why Amazon Cares about Open Source
Machine learning using Kubernetes
Building Cloud Native Applications
Chaos Engineering with Kubernetes
How to be a mentor to bring more girls to STEAM
Java in a World of Containers - DockerCon 2018
The Serverless Tidal Wave - SwampUP 2018 Keynote
Introduction to Amazon EKS - KubeCon 2018
Mastering Kubernetes on AWS - Tel Aviv Summit
Top 10 Technology Trends Changing Developer's Landscape
Java EE and NoSQL using JBoss EAP 7 and OpenShift
Docker, Kubernetes, and Mesos recipes for Java developers
Thanks Managers!
Migrate your traditional VM-based Clusters to Containers
NoSQL - Vital Open Source Ingredient for Modern Success

Recently uploaded (20)

PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PPT
Teaching material agriculture food technology
PDF
Review of recent advances in non-invasive hemoglobin estimation
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PPTX
Understanding_Digital_Forensics_Presentation.pptx
PDF
Electronic commerce courselecture one. Pdf
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PDF
Encapsulation_ Review paper, used for researhc scholars
PPTX
sap open course for s4hana steps from ECC to s4
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
Network Security Unit 5.pdf for BCA BBA.
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PPTX
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PDF
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PPTX
MYSQL Presentation for SQL database connectivity
PDF
Unlocking AI with Model Context Protocol (MCP)
Mobile App Security Testing_ A Comprehensive Guide.pdf
Teaching material agriculture food technology
Review of recent advances in non-invasive hemoglobin estimation
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Understanding_Digital_Forensics_Presentation.pptx
Electronic commerce courselecture one. Pdf
“AI and Expert System Decision Support & Business Intelligence Systems”
Encapsulation_ Review paper, used for researhc scholars
sap open course for s4hana steps from ECC to s4
Dropbox Q2 2025 Financial Results & Investor Presentation
Digital-Transformation-Roadmap-for-Companies.pptx
Network Security Unit 5.pdf for BCA BBA.
Reach Out and Touch Someone: Haptics and Empathic Computing
Effective Security Operations Center (SOC) A Modern, Strategic, and Threat-In...
The Rise and Fall of 3GPP – Time for a Sabbatical?
NewMind AI Weekly Chronicles - August'25 Week I
Peak of Data & AI Encore- AI for Metadata and Smarter Workflows
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
MYSQL Presentation for SQL database connectivity
Unlocking AI with Model Context Protocol (MCP)

Java EE and Google App Engine

  • 1. Aleš Justin, JBoss by RedHat JavaEE and Google AppEngine Tuesday, April 12, 2011
  • 2. Agenda • What is GAE and CDI? • Why GAE and CDI? • Other JavaEE technologies • Development vs. Production • Problems vs. Solutions • Testing •Q & A Tuesday, April 12, 2011
  • 3. About me • Old school JBoss-ian • Microcontainer co-author • Weld lead • RHT Cloud “guinea pig” • Eager PaaS user • While still GAE amateur Tuesday, April 12, 2011
  • 4. GAE • Forked Jetty • Many (logical) restrictions • RDBMS → BigTable • Simple Map(Reduce) • Good administration • Free basic usage Tuesday, April 12, 2011
  • 5. CDI • Context and Dependency Injection • JSR-299 → JBoss Weld RI • “type-safe” programming • “contexts” concept • Easy to extend: “Extensions” • “Using CDI Extensions to Make a Better Java EE ” at 18:00 Tuesday, April 12, 2011
  • 6. Why GAE and CDI? • Simple reason: sandbox app • Android app with server back-end • Tattletale (Tožibaba) • Zero administration / configuration • Reliable up-time • No more “boiler-plate” code → CDI Tuesday, April 12, 2011
  • 7. CDI #2 • @Inject • @Observes • @Qualifier • @ConversationS. • @Named • @Decorator • @Scope • @Alternative • Interceptors • @Sterotype • InjectionPoint • Instance • Pete and Dan’s • @Produces yday tutorial! Tuesday, April 12, 2011
  • 8. Other technologies • JPA • JSF2 • BeanValidation • javax.cache • JSON • ShrinkWrap + Arquillian Tuesday, April 12, 2011
  • 9. Project Kick-Off • Know (all) restrictions! • 30sec, white-list, no threads, ... • How portable should my app be? • Development vs. Production Env! • Frameworks have problems • But they mostly have (easy) solutions → fork? Tuesday, April 12, 2011
  • 10. The Goal • Abstract away GAE API • Pure JavaEE • Port app to JBossAS (6 & 7) • Use CDI as much as possible • Test it all, same as other JavaEE apps Tuesday, April 12, 2011
  • 11. Initial problems Proxy Bean • CDI • “Entry” mechanism • Request / response binding • Lack of “lifecycle” handling Tuesday, April 12, 2011
  • 12. Initial problems • JPA • Limited relationships (Entity groups) • Proxying layer vs. Custom “ORM” • Transaction per “Entity group” • Old DataNucleus version • Long vs. Key entity key • “Enhanced” entities • GeoModel hashing queries (“IN”) Tuesday, April 12, 2011
  • 13. Initial problems • JSF2 • Context parameter settings • “new InitialContext” patch • “built-in” EL 1.0 → workaround Tuesday, April 12, 2011
  • 14. Initial problems • BeanValidation • Static usage with JPA • Size • Configuration Tuesday, April 12, 2011
  • 15. Initial problems • javax.cache (GCache) • No partition • NUCCORE-540 → fork • JSON • Different versions; client vs. server • Arquillian • Missing GAE container Tuesday, April 12, 2011
  • 16. “Production” problems • CDI • “Bean scanning” → exact listing • “Lazy beans” → MVC re-write • GZIP + Base64 usage • “Fall-back / repeat” mechanism Tuesday, April 12, 2011
  • 17. “Production” problems • JPA • Explicit entity listing • Maximize cache usage • “Caching” → Lazy EMF • javax.cache • serialVersionUID • Non-primitive variables • Cache evict / clear mechanism Tuesday, April 12, 2011
  • 18. Testing • ShrinkWrap • Binaries abstraction • Arquillian • Runtime / Env abstraction • https://github.com/alesj/arquillian Tuesday, April 12, 2011
  • 19. Tattletale • Lhotse POC • https://github.com/alesj/lhotse Lhotse Server-API Tattletale Server-GAE Server-JEE Tuesday, April 12, 2011
  • 20. Q&A ales.justin@jboss.org Tuesday, April 12, 2011