Google App Engine (GAE) is a popular PaaS offering. Where its scalable and reliable environment is hidden behind a custom API. This makes GAE apps hard to port over to other non-GAE environments.
But what if one could implement such similar environment? And you could simply move your GAE application’s .war file to this new environment and it would just work?
After all, at the end it’s all about the API, plus scalable and reliable services.
JBoss CapeDwarf project aims at making this a reality. This presentation will provide a glimpse into what it takes to implement something as GAE, ranging from runtime integration with JBoss Application Server, actual services implementation to last but not least, automated heavy testing.
2. The goal
• Take an *existing* Google App Engine app
• Drop it into WildFly
• It just works!
• No vendor lock-in
• Enable cluster debugging / testing
• On-premises cloud!
• Designed to scale
3. • What’s Google App Engine?
• What is JBoss CapeDwarf?
• How do the two work together?
• The dirty details
• Demo
• Q&A
Agenda
4. • Aleš Justin
• CapeDwarf Project Founder & Lead
• Old School JBoss-ian; MC, CDI, Ceylon, ...
Who’s this guy?
5. “Google App Engine lets you run web applications on
Google's infrastructure. App Engine applications are easy to
build, easy to maintain, and easy to scale as your traffic and
data storage needs grow. With App Engine, there are no
servers to maintain: You just upload your application, and it's
ready to serve your users.”
It’s all about services and its API!
What is Google App Engine?
6. • Open source implementation of Google App Engine API
• It’s all about the API, not impl - for users
• Written on top of JBoss and other OS frameworks
• Infinispan, Hibernate Search, HornetQ, Lucene, ...
• Runs as a WildFly subsystem / extension
• Management, Clustering, ...
What is CapeDwarf?
7. • Super easy to setup locally - unzip & run
• Same way as any WildFly / JBossAS
• Trivial to setup cluster
• A way to debug scalable apps
• Integrated into OpenShift (Red Hat PaaS)
• Own CapeDwarf cartridge / image
• On-premises cloud env
What is CapeDwarf?
8. • 100% pure Java
• It’s all on GitHub
• https://github.com/capedwarf
What is CapeDwarf?
10. ... or how do we know CapeDwarf actually works ...
More about this in next slides :-)
Testing?
11. • Google App Engine Technology Compatibility Kit (TCK)
• Joint (initial) effort from Google and Red Hat
• http://www.appengine-tck.org
• 1000+ API tests
• Additional testing - Endpoints, DataNucleus, MapReduce,
Modules, Concurrency, …
• GCloud support (aka Managed / Custom Runtimes)
Google App Engine &
CapeDwarf
12. • Runs with Maven
• JUnit,Arquillian and ShrinkWrap based
• Nice API test coverage report
• Easy to add new containers / runtimes
• Using GitHub’ “community” power; pull-request,
review, ...
About TCK
18. • Standalone
• Properly map JEE .ear onto GAE Modules logic
• Setup virtual-servers for each module
• Domain (TODO)
• Custom DomainController
• Each module gets own app server instance
• Could share app servers
• Testing → new Arquillian Protocol
Modules
19. • Extending WildFly → New Subsystem
• It’s all about DeploymentUnitProcessors
• Remember JBoss Deployers? ;-)
• 10+ DUPs, per phase / purpose
• Almost zero configuration
• Few MSC services
• Fully modular
• in-line API jar or as-module
CapeDwarf Runtime
20. • Waiting for new WildFly9 release
• Improved Infinispan7
• Hibernate Search, Lucene upgrade
• CapeDwarf Managed sub-project
• Using GAE API directly in WildFly
• Managed / Custom Runtime
https://github.com/capedwarf/capedwarf-managed
CapeDwarf WIP
21. 1. Download latest CapeDwarf release
• http://www.capedwarf.org/downloads/
2. Unzip & run
• <CAPEDWARF_HOME>/bin/capedwarf.sh
3. Deploy your GAE app
• Via WildFly management
• Drop app into deployments/ dir
Try it out!