Server-side OSGi with Apache Sling. Felix Meschberger Day Management AG 124



Similar documents
Apache Sling A REST-based Web Application Framework Carsten Ziegeler cziegeler@apache.org ApacheCon NA 2014

RESTful web applications with Apache Sling

NextRow - AEM Training Program Course Catalog

Developer s Guide. How to Develop a Communiqué Digital Asset Management Solution

FUSE-ESB4 An open-source OSGi based platform for EAI and SOA

APACHE SLING & FRIENDS TECH MEETUP BERLIN, SEPTEMBER APACHE SLING & SCALA Jochen Fliedner

GlassFish v3. Building an ex tensible modular Java EE application server. Jerome Dochez and Ludovic Champenois Sun Microsystems, Inc.

Operations and Monitoring with Spring

Creating a REST API for Cloud services using Apache Felix and Sling Carsten Ziegeler and David Bosschaert

Web Development with the Eclipse Platform

<Insert Picture Here> GlassFish v3 - A Taste of a Next Generation Application Server

Continuous Delivery of Apache Sling Applications

Learning GlassFish for Tomcat Users

CQCON 2013: five Sling features you should know

Building a Modular Server Platform with OSGi. Dileepa Jayakody Software Engineer SSWSO2 Inc.

InfoSphere Master Data Management operational server v11.x OSGi best practices and troubleshooting guide

Introducing Apache Pivot. Greg Brown, Todd Volkert 6/10/2010

Glassfish Architecture.

docs.hortonworks.com

Communiqué 4. Standardized Global Content Management. Designed for World s Leading Enterprises. Industry Leading Products & Platform

Apache Karaf in real life ApacheCon NA 2014

ADMINISTERING ADOBE LIVECYCLE MOSAIC 9.5

Talend ESB. Getting Started Guide 5.5.1

YouTrack MPS case study

IBM WebSphere Server Administration

Sabre Red Apps. Developer Toolkit Overview. October 2014

Architecture Guide Jahia EE v6.1

Course Description. Course Audience. Course Outline. Course Page - Page 1 of 5

Enterprise Application Development In Java with AJAX and ORM

Enterprise Service Bus

A Comparison of Open Source Application Development Frameworks for the Enterprise

EVALUATION ONLY. WA2088 WebSphere Application Server 8.5 Administration on Windows. Student Labs. Web Age Solutions Inc.

Configuring Apache HTTP Server as a Reverse Proxy Server for SAS 9.2 Web Applications Deployed on BEA WebLogic Server 9.2

Architecture and Mode of Operation

Eclipse 4 RCP application Development COURSE OUTLINE

Preface. Motivation for this Book

This training is targeted at System Administrators and developers wanting to understand more about administering a WebLogic instance.

Converting Java EE Applications into OSGi Applications

Effective Web Application Development with Apache Sling. Robert Munteanu ), Adobe Systems Romania

JBoss Portlet Container. User Guide. Release 2.0

Managing Complexity in Mobile Application Deployment Using the OSGi Service Platform

Talend Open Studio for ESB. Release Notes 5.2.1

Software Development Kit

Workshop for WebLogic introduces new tools in support of Java EE 5.0 standards. The support for Java EE5 includes the following technologies:

LDAPCON Sébastien Bahloul

Oracle WebLogic Server

ITG Software Engineering

IKAN ALM Architecture. Closing the Gap Enterprise-wide Application Lifecycle Management

NetBeans IDE Field Guide

WebSphere Server Administration Course

Developing modular Java applications

No.1 IT Online training institute from Hyderabad URL: sriramtechnologies.com

WebLogic Server: Installation and Configuration

IBM Digital Experience. Using Modern Web Development Tools and Technology with IBM Digital Experience

Course Name: Course in JSP Course Code: P5

Customer Bank Account Management System Technical Specification Document

Basic TCP/IP networking knowledge of client/server concepts Basic Linux commands and desktop navigation (if don't know we will cover it )

The Compatible One Application and Platform Service 1 (COAPS) API User Guide

The Java EE 6 Platform. Alexis Moussine-Pouchkine GlassFish Team

Introduction to Oracle Mobile Application Framework Raghu Srinivasan, Director Development Mobile and Cloud Development Tools Oracle

FileMaker Server 10 Help

Securing SAS Web Applications with SiteMinder

MESSAGING SECURITY USING GLASSFISH AND OPEN MESSAGE QUEUE

FileMaker Server 11. FileMaker Server Help

Kohsuke Kawaguchi Sun Microsystems, Inc. hk2.dev.java.net, glassfish.dev.java.net. Session ID

Building native mobile apps for Digital Factory

Load and Performance Load Testing. RadView Software October

CHAPTER 1 - JAVA EE OVERVIEW FOR ADMINISTRATORS

Red Hat Enterprise Portal Server: Architecture and Features

TIBCO Spotfire Statistics Services Installation and Administration

WebSphere Training Outline

IUCLID 5 Guidance and Support

TIBCO Spotfire Statistics Services Installation and Administration Guide. Software Release 5.0 November 2012

Configuring Secure Socket Layer (SSL) for use with BPM 7.5.x

Oracle Communications WebRTC Session Controller: Basic Admin. Student Guide

Glassfish, JAVA EE, Servlets, JSP, EJB

Configuring CQ Security

Project SailFin: Building and Hosting Your Own Communication Server.

WebSphere Application Server - Introduction, Monitoring Tools, & Administration

Agile Best Practices and Patterns for Success on an Agile Software development project.

Copyright 2014 Jaspersoft Corporation. All rights reserved. Printed in the U.S.A. Jaspersoft, the Jaspersoft

Alfresco. Wiley Publishing, Inc. PROFESSIONAL. PRACTICAL SOLUTIONS FOR ENTERPRISE. John Newton CONTENT MANAGEMENT. Michael Farman Michael G.

Rapid Application Development. and Application Generation Tools. Walter Knesel

Oracle WebLogic Server 11g: Administration Essentials

HP Process Automation v6 Architecture/Technologies

ReSTful OSGi Web Applications Tutorial. Khawaja Shams & Jeff Norris

Creating Web Services Applications with IntelliJ IDEA

JVA-122. Secure Java Web Development

Configuring Apache HTTP Server as a Reverse Proxy Server for SAS 9.3 Web Applications Deployed on Oracle WebLogic Server

An Oracle White Paper May Ready for Business: Oracle GlassFish Server

TIBCO Spotfire Statistics Services Installation and Administration Guide

Java EE 6 development with Eclipse, Netbeans, IntelliJ and GlassFish. Ludovic Champenois Oracle Corporation

Transcription:

Server-side OSGi with Apache Sling Felix Meschberger Day Management AG 124

About Felix Meschberger > Senior Developer, Day Management AG > fmeschbe@day.com > http://blog.meschberger.ch > VP Apache Sling > Apache Felix > Apache Jackrabbit 2

Agenda > Apache Sling > Why OSGi? > What parts of OSGi? > Advantages and Problems > Demo 3

Apache Sling > REST based web framework > Content-driven (JCR, JSR-170/283) > Powered by OSGi > Scripting inside (Java Scripting, JSR-223) > Apache Open Source Projekt (http://sling.apache.org) 4

Sling Architecture HTTP debugger filesystem browser resource resolution standard servlets JSR223 Scripting WebDAV Server Felix Web Console servlet resolution custom servlets javascript JSP etc. JSR-170/283 API JCR repository OSGi Framework 5

Sling URL Decomposition /content/cars/audi/s4.details.html 6

Sling is RESTful > URLs map to Resources Items in the JCR Repository Files in the Filesystem Content of Bundles > HTTP Methods map to Script Names e.g. cars/post.jsp GET for reading only Dilution: POST allowed for any changes (Create, Update, Delete) > Content Negotiation Request URL extension Accept request header currently ignored 7

Sling is Object Oriented Web > Resources are the Object > Resources maintained in Resource Tree > Resources accessed by path in the Resource Tree > Request Method, Extension and Selectors define Method to call > Resources are typed: Resource Type Resource Super Type Root Type : sling/servlet/default 8

Functionality Out-Of-the-Box > Default Implementations for GET Plain Text JSON XML > Default Implementation for POST Create, Update, Modify content Extensible 9

Sling in Action > Day Communiqué 5 (http://www.day.com/cq5) > Sakai 3 (http://www.sakaiproject.org) > Tuberculosis Project > Idium Web (http://www.idium.no/no/idium_web) http://cwiki.apache.org/sling/who-is-using-sling-.html 10

Agenda > Apache Sling > Why OSGi? > What parts of OSGi? > Advantages and Problems > Demo 11

Requirements for Sling > Modular and Extensible System > Declared Dependencies > Intermodule Communication > Lightweight Framework 12

Variants > Do It Yourself Well, don't we have other problems to solve? ;-) > Spring (before Spring DM) First Favourite due to declarative nature Systems not really dynamic Static application descriptor > OSGi Perfect match to all requirements 13

Agenda > Apache Sling > Why OSGi? > What parts of OSGi? > Advantages and Problems > Demo 14

OSGi Elements Used > Framework > Configuration Admin Service > Meta Type Service > Declarative Services > Event Admin Service > Log Service > HTTP Service 15

Launching Sling > Standalone or Web Application > Small Footprint Launcher (~30K) > Framework in its own ClassLoader > Restart of Framework > Update of Framework > Application is Container Agnostic Interaction only within the OSGi Framework Http Service implementation is the key 16

Configuration Admin Service > Provides an API to manage Configurations > Provides functionality to pass configuration to consumers > Hides persistance problems > Uses in Sling Web Console configuraition editor JCR Install updates through repository 17

Metatype Service > Descriptor to generate GUI for Configuration Management > Use in Sling Descriptor generated by Maven SCR Plugin Configuration Admin GUI in Web Console supports Metatype Service descriptors 18

Declarative Services > Replace boiler-plate code by descriptors Service Registration Configuration support Service Access > Dependency Injection > One of many OSGi Core Extensions: Apache Felix Dependency Manager (Predecessor) Apache Felix ipojo (Successor) Blueprint (OSGi Compendium Specification R 4.2) Peaberry 19

Event Admin Service > Whiteboard Pattern oriented eventing > Support for synchronous and asynchronous events > Uses in Sling Base Mechnism to implement Job Scheduling Extended to allow for event distribution in Cluster 20

Log Service > Sling's own implementation > Based on SLF4J API > Provides OSGi LogService SLF4J Logging Commons Logging Log4F Logging > Dynamically Configurable (by Configuration Admin Service) > Log Levels and Log Format per Logger > Multiple Log Files with size and time rotation 21

Http Service > Registering Servlets (and Resources) dynamically > Real Implementation Includes Servlet Container > Bridged Implementation Used for Web Application Launcher Bridges Servlet Container to OSGi > Implementation transparent to registered Servlets 22

Extensions > Apache Felix Web Console Extensible Web Based Management Jquery UI Based (as of Version 3.0) > Maven SCR Plugin Generates Supports Declarative Services Descriptors Metatype Service Descriptors JavaDoc Tags (@scr.component, etc.) Java 5 Annotations (@Component, etc.) > JCR Install Deploy Bundles via JCR Repository Deploy Configuration Admin configurations via JCR Repository 23

Agenda > Apache Sling > Why OSGi? > What parts of OSGi? > Advantages and Problems > Demo 24

Advantages > Declared Dependencies > Better Isolution through explicit exports and private classes > Classloader Isolation > Extensibility built-in, not built-atop > Dynamism 25

Problems > Steep Learning Curve OSGi Specifications Themselves Modularization vs. Monolithic > Uptime vs. Startup Time > Legacy Specs und ClassLoader JDBC, XML, etc. > Scripting und ClassLoader BundleClassLoaderProxy approach > Application Packaging CRX Content Packages (Day proprietary) Karaf features (Sling provides feature.xml) 26

Agenda > Apache Sling > Why OSGi? > What parts of OSGi? > Advantages and Problems > Demo 27

Demo: 15 Minutes > Commandline launch > Web Console > Show WebDAV > Dummy Content > Create Scripts and have it render ESP Groovy JSP 28

Links > Apache Sling The JCR (Web) Application Framework http://sling.apache.org > Apache Felix OSGi Framework and Compendium Service implementations http://felix.apache.org > Apache Jackrabbit The JCR (JSR-170/283) Reference Implementation http://jackrabbit.apache.org > Day Developer's Home http://dev.day.com 29

Questions 30

Thank you very much! 31

Felix Meschberger Day Management AG http://www.day.com fmeschbe@day.com