Eclipse Gyrex OSGi based PaaS-Like Programming Stack - OSGi Cloud Workshop March 2012

Post on 13-May-2015

1.997 views 2 download

Tags:

description

OSGi DevCon 2012 - OSGi Cloud Workshop. Presentation by Gunnar Wagenknecht (Ageto) - "Eclipse Gyrex OSGi based PaaS-Like Programming Stack"

Transcript of Eclipse Gyrex OSGi based PaaS-Like Programming Stack - OSGi Cloud Workshop March 2012

OSGi based PaaS-like programming stack

ZK Cluster

Gyrex Node

LoadBalancer

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

ZK Node

ZK Node

ZK Node

• coordinates the cluster • Holds the complete application- and cluster configuration

REST API

REST API

REST API

REST API

REST API

REST API

REST API

REST API

data repositories

iPad App Mobile Apps

PHP WebApp

InternetOfThings Device

Native App

Eclipse Gyrex

GYREX lightweight application stack for building server applications using EclipseRT technologies.

o built-in clustering o built-in web-based administration UI

o built-in multi tenancy

o enhancements for professional maintenance - centralized logging - cluster provisioning UI

Stack

o Equinox o Jetty o p2 o ZooKeeper o Solr o Logback, o Cassandra o Memcached

GYREX Components

Admin

Contextual Runtime

Equinox

Cloud

Monitoring

Repositories (JDBC, EclipseLink, NoSQL)

HTTP Applications (Jetty, OSGi HttpService)

RAP Logging

Clustering & Coord. (ZooKeeper)

Provisioning (p2)

Debug/Trace

Metrics

Console

Processing (Eclipse Jobs API)

Configuration (Eclipse Preferences API)

ZK Cluster

GYREX Infrastructure Setup For a High Traffic Application

with different frontends

Gyrex Node

LoadBalancer

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

ZK Node

ZK Node

ZK Node

• coordinates the cluster • Holds the complete application- and cluster configuration

REST API

REST API

REST API

REST API

REST API

REST API

REST API

REST API

data repositories

iPad App Mobile Apps

PHP WebApp

InternetOfThings Device

Native App

p2 repo

GYREX Features

ZK Cluster

Gyrex Node

LoadBalancer

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

Gyrex Node

ZK Node

ZK Node

ZK Node

• coordinates the cluster • Holds the complete application- and cluster configuration

REST API

REST API

REST API

REST API

REST API

REST API

REST API

REST API

data repositories

iPad App Mobile Apps

PHP WebApp

InternetOfThings Device

Native App

o light weight application stack

o fast 100% OSGi runtime o central cluster configuration through zookeeper o cluster aware job scheduling

o multi tenant application support

o automated deployment through p2

o support for cluster node roles, e.g. „job worker node“ and „api node“

ZooKeeper o group/membership

o tag nodes (“webserver”, “worker”) o associate bundle states and/or applications with tags

o configuration (using OSGi Preferences)

o distributed coordination

o automatic failover of singleton services o node UP/DOWN events (EventAdmin)

HTTP & OSGi

Requirements:

o Grouping (“application”)

o Multi-tenancy

o Run multiple instances of an “application” on different URLs

HTTP & OSGi public class MyWebApp extends Application { @Override protected void doInit() throws CoreException { getApplicationContext().registerServlet(…); getApplicationContext().registerResources(…); getApplicationContext().registerFilter(…); } }

HTTP & OSGi osgi> http <cmd> [args] ls … lists registered applications or providers

defineApp … defines an application removeApp … removes an application definition setAppProperty … sets/removes an application property

mount … mounts an application at the specified URL unmount … unmounts the specified URL

start … starts an application stop … stops an application

Queue Service IQueueService { IQueue getQueue(..) } IQueue { void sendMessage(byte[] messageBody) List<IMessage> receiveMessages(..) IMessage consumeMessage(..) boolean deleteMessage(..) }

Thank You for your attention