32
1 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

GlassFish in the Virtual World

Embed Size (px)

DESCRIPTION

GlassFish in the Virtual World at JavaOne Latin America 2011

Citation preview

Page 1: GlassFish in the Virtual World

1 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Page 2: GlassFish in the Virtual World

2 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8 2 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8 2 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

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.

Page 3: GlassFish in the Virtual World

3 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

GlassFish in the Virtual World How GlassFish turns into a PAAS provider

Page 4: GlassFish in the Virtual World

4 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Agenda

•  Introduction •  PaaS • GlassFish as a PaaS provider •  IaaS Management Service • Orchestration •  Elasticity

Page 5: GlassFish in the Virtual World

5 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8 5 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8 5 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Requirements

t0 t1 t2 t3

Development Hardware procurement Application Installation

Prototyping Testing Hardware installation Certification

Development and Deployment Timeline

The I.T. rift

Page 6: GlassFish in the Virtual World

6 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Introduction ([I|P|S]aas)

Isolation

Elasticity

Mutil-Services

PAAS

SAAS

IAAS Virtualization, Storage, Network

Java EE instances and Resources

Multi-tenant Java EE application

Page 7: GlassFish in the Virtual World

7 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Application Installation

•  Install Java EE application server on all hardware • Create a dedicated (static) cluster of Java EE server

instances • Map incoming traffic to Java EE server instances • Resolve cluster dependencies (MQ, Database) • Change Java EE application runtime descriptor to map to

the deployment cluster (optional) • Deploy the application

Page 8: GlassFish in the Virtual World

8 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Agenda

•  Introduction •  PaaS • GlassFish as a PaaS provider •  IaaS Management Service • Orchestration •  Elasticity

Page 9: GlassFish in the Virtual World

9 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

PaaS to the rescue

•  I.T. departments can offer usual services through a private PaaS : – No delay – Secure – Maximize hardware utilization – Monitoring

• Developers –  Faster time to market. – Easier deployment facilities

Page 10: GlassFish in the Virtual World

10 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

What does PaaS mean for Java EE

• One Step deployment : – Multi-services interdependencies resolution – Cluster of Java EE server instances procurement – Cluster elasticity :

• Metrics provided by application • Application Server metrics (response time, etc..) • Virtual Machine information (CPU, Memory usages)

•  And one step un-deployment…

Page 11: GlassFish in the Virtual World

11 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Agenda

•  Introduction •  PaaS • GlassFish as a PaaS provider •  IaaS Management Service • Orchestration •  Elasticity

Page 12: GlassFish in the Virtual World

12 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Requirements on GlassFish

• Capable of creating/starting/stopping/deleting Virtual Machines

• Capable of monitoring Virtual Machines • Capable of self-shaping the cluster based on statistics • Understands service definitions • Understands service references •  Bind references to definitions using virtual machines

Page 13: GlassFish in the Virtual World

13 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

GlassFish in the Cloud

Cloud Resources

Configuration

KVM Plugin

Template Management

Hypervisor Abstraction

OVM Plugin VirtualBox plugin

Iaas Management Service

Orchestration Engine

Elasticity Management Service

Service Provisioning Engine

Versioning

Template matching

Service Association

Service Discovery

Adjust cluster shape

Monitor deployed

Applications

Page 14: GlassFish in the Virtual World

14 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

GlassFish as a PaaS Provider

Virtual Machine with Database

service

Virtual Machine With Load Balancer

Application introspection

Virtual Cluster Creation

Virtual Machine with Java EE

Association Deployment

Timeline

Page 15: GlassFish in the Virtual World

15 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Agenda

•  Introduction •  PaaS • GlassFish as a PaaS provider •  IaaS Management Service • Orchestration •  Elasticity

Page 16: GlassFish in the Virtual World

16 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

IMS Architecture

Libvirt interface layer

KVM Plugin KVM Specific

CLIs

KVM specific configuration

OVM Plugin VirtualBox plugin

Service Provisioning

Engine virt-core

Common CLIs Common configuration

Page 17: GlassFish in the Virtual World

17 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Three virtualization implementations

•  Laptop mode – Runs processes on the bare metal operating system. – All service types supported (not all variations)

•  Local mode –  Locally installed hypervisor – Best fidelity to deployment scenario

• Remote mode – Connects to remote hypervisors

Page 18: GlassFish in the Virtual World

18 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Hypervisor plugin Hypervisor   Local  Mode   Remote  Mode  

Laptop  mode   Yes   Soon  

KVM   Yes   Yes  

Xen   Yes   Yes  

VirtualBox   Yes   No  

OVM   Yes   Yes  

Vmware   Yes   Yes  

Page 19: GlassFish in the Virtual World

19 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Topology

IaaS Management Service

Server Pool Server Pool Asia

Server Pool Europe

Oracle  VM  Manager  

IaaS  Provider  (Amazon)  

Oracle  Enterprise  Manager  Machines  in  

France  Machines  in  U.K.   Machines  in  

Germany  

Page 20: GlassFish in the Virtual World

20 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Agenda

•  Introduction •  PaaS • GlassFish as a PaaS provider •  IaaS Management Service • Orchestration •  Elasticity

Page 21: GlassFish in the Virtual World

21 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Services

•  It’s all about Services, how to provide them, how to resolve them and eventually how to inject them. – Provisioned

• Application Scoped • Global/Shared

– External

•  Service Metadata – Service Definition – Service Reference (implicit and explicit)

Page 22: GlassFish in the Virtual World

22 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Service Reference

•  glassfish-services.xml – Explicit Service References definition

• Target template • Characteristics matching

• Will be replaced with Java EE standard XML

Page 23: GlassFish in the Virtual World

23 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Service Reference Example <glassfish-services> <service-description name="MyDB”> <!-- Based on the characteristics specified below, the Orchestrator would match to a Template in the Template Repository and provision that Service --> <characteristics> <characteristic name="service-type" value="Database"/> <characteristic name="service-vendor" value="Oracle"/> <characteristic name="service-product-name" value="Oracle"/> <characteristic name="service-version" value="11g"/> <characteristic name="os-name" value="Linux"/> </characteristics> <configurations> <!-- Create initial schema --> <configuration name="init.sql" value="tbl-init.sql"/> </configurations> </service-description> </glassfish-services>

Page 24: GlassFish in the Virtual World

24 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

PaaS Application Deployment

Service Reference Extraction

Message Queue Service

Configure Application with procured services references

Database Service Java EE Service

Provision and Initialize

Deployment Pipeline

Provision and Initialize

Provision and Initialize Deploy application

LoadBalancer

Provision and Initialize

Page 25: GlassFish in the Virtual World

25 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Redeployment

• Reuse existing services/cluster of Java EE instances •  Adapt shape to new application requirements • Data migration

– Database schema upgrade – Security

• Rolling upgrades still apply •  Lower stack software update (O.S. / Database)

Page 26: GlassFish in the Virtual World

26 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Undeployment

• Rule of thumb : undo what was done during deployment •  Application scoped services stopped and released •  Shared services released • Cluster of Java EE instances deleted •  Virtual Machines released •  Virtual Disks deleted

Page 27: GlassFish in the Virtual World

27 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Agenda

•  Introduction •  PaaS • GlassFish as a PaaS provider •  IaaS Management Service • Orchestration •  Elasticity

Page 28: GlassFish in the Virtual World

28 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

How to Determine when to Autoscale

• Monitor Resources used by the system – CPU

• Used and idle CPU times – Memory

• Process memory: Allocated, Resident etc. • JVM memory: Used, Committed and Max memory

– Disk • Reads, Writes per seconds • Bytes read, written etc.

Page 29: GlassFish in the Virtual World

29 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

How to Determine when to Autoscale

–  Java Objects • HTTP Sessions created / destroyed per second • Number of HTTP requests that arrived • Connection Pools: Number of connections acquired / released etc. • Database Queries executed • Transaction status: Number of commits / rollbacks

– Application Specific Metrics

• Response time of a specific URL

– Many, many, many other metrics…

Page 30: GlassFish in the Virtual World

30 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Metric Sources •  JMX

–  Example MXBean to gather memory statistics –  Operating environment may have JMX MBeans that provide some

metrics

• Monitoring tools – Virtual Machine Manager can provide cpu / memory usage metric

• Native tools –  Top, lsof, iostat etc.

Page 31: GlassFish in the Virtual World

31 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Want to try ?

•  Source code and builds –  http://glassfish.java.net/

•  The aquarium –  http://blogs.oracle.com/theaquarium/

•  The specs –  http://javaee-spec.java.net/

Page 32: GlassFish in the Virtual World

32 Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Insert Information Protection Policy Classification from Slide 8

Latin America 2011 December 6–8, 2011

Tokyo 2012 April 4–6, 2012