SlideShare a Scribd company logo
1 of 60
Download to read offline
Carsten Ziegeler | Day Management AG


OSGi, Scripting, REST
Webapps with Apache Sling
  cziegeler@apache.org
About
• Member of the ASF
     – Sling, Felix, Cocoon, Portals, Sanselan,
       Excalibur, Incubator
     – PMC: Felix, Portals, Sling, Incubator,
       Excalibur (Chair)
• RnD Team at Day Software
• Article/Book Author, Technical
  Reviewer
• JSR 286 Spec Group (Portlet API 2.0)

 2
Agenda – Apache Sling
1   Motivation
2   Content and JCR
3   Web and REST
4   Scripting
5   OSGi
6   Outlook




    3
Apache Sling



1 Motivation


4
Web Challenges
• Publish huge amount of information
     – Different types
     – Highly dynamic
     – Different output formats
• Web 2.0 ready
     – Collaboration and integration
• Fast changing requirements
     – Rapid prototyping and development
     – Dynamic, extensible but maintainable

 5
Web Challenges
• Publish huge amount of information
     – Different types                   JCR

     – Highly dynamic
     – Different output formats         REST
                                        ROA
• Web 2.0 ready
     – Collaboration and integration
• Fast changing requirements           Scripting

     – Rapid prototyping and development
     – Dynamic, extensible but maintainable
                                        OSGi


 6
Apache Sling – The Fun Is Back
•   Web framework             th
                       5 Winner JAX Innovation Award 2008

•   Java content repository (JCR)
•   ROA / REST
•   Scripting inside
•   OSGi
•   Apache Open Source top level project
        – http://sling.apache.org
• Driving force behind several OSGi
   related projects at Apache
    7
Apache Sling Powered Site




8
Apache Sling



2 Content/JCR


9
Content Is Important
• Apache Sling makes handling content
  easy
• Java content repository (JCR)
     – Several different sources possible
• Direct mapping: URL -> content
     – Configurable
     – http://myserver.domain/products/sling
        .html
• Flexible rendering

10
Content Repository I
• Features of an RDBMS
     – Structure, integrity
     – Query, transactions
• Features of a filesystem
     – Hierarchy, binaries
     – Locking, access control
• All the other good stuff
     – Observation, versioning
     – Unstructured
     – Multi values, sort order, full text
• Single repository for all content!
11
JCR – JSR 170, JSR 283
• Content Repository for Java
  technology API
• (Java) Standard
     – Supported by many vendors
     – Used by many products and projects
     – Several open source solutions
• How do you connect to a CR?
• How do you interact with a CR?
              JSR 283 – Version 2.0 – Final since September 09

12
Sample Application: Slingshot
• Digital Asset Management
     –   Hierarchical storage of pictures
     –   Upload
     –   Tagging                     Poor man's flickr...
     –   Searching
     –   Automatic thumbnail generation




                                                        13
13
Slingshot Content Structure


                      Travel              Family


                 Europe                            Weddings


     Amsterdam            Basel                         2008


     2007                      City                 Photo      Photo


      Photo                           Photo



14
Content Repository II
• Hierarchical content
     – Nodes and properties
• Structured
     – Nodetypes and typed properties
• And/or unstructured
• Fine and coarse-grained
• Single repository for all content!



15
The Repository Model
•    Repository: one (or more) workspaces
•    Workspace contains a tree of items
•    Item: Node or property
•    Nodes provide the content structure
         – May have children
• Actual data is stored as values of
  properties
• Types and namespaces!


    16
Nodes and Properties
                                                 Root


                         Travel                   Family


                    Europe        “Images from
                                  Europe“
                                                           Weddings


     Amsterdam               Basel                              2008


     2007                           City                    Photo      Photo


      Photo                                 Photo

              „Once
              upon a
              time..“



                             Properties
                                  Implementation of JCR


17
Apache Jackrabbit
• JSR 170, JSR 283 reference
    implementation
• Apache TLP since 2006
• Several releases
• JCR 2.0 implementation end of 2009
• Additional components




18
Leverage the standard node types
      • Type hierarchy             • Content
                                     hierarchy
      nt:hierarchyNode

                     nt:folder

                         nt:file

                   nt:linkedFile

      nt:unstructured




 19
Bottom-up modeling: Node types
slingshot:album > nt:folder        slingshot:tag
- slingshot:description (string)   - slingshot:description (string)
- slingshot:date (date)



slingshot:photo > nt:file
- slingshot:description (string)
- slingshot:location (string)
- slingshot:tags (string[])




20
Top-down modeling: Hierarchy


                      Travel              Family


                 Europe                            Weddings


     Amsterdam            Basel                         2008


     2007                      City                 Photo      Photo


      Photo                           Photo



21
Apache Sling



3 ROA and REST


22
Resource Oriented Architecutre
• Piece of information is a resource
     – News entry, product, photo...
     – (Descriptive) URI
• Stateless
     – Request contains all relevant
        information
• Use HTTP
     – Methods (GET, POST) for operations



23
REST with Apache Sling
• Default behaviour for GET
• Creating/Updating content through
  POST
     – Default behaviour
• Additional operations/method
• Resource-first request processing!




24
Resource
• Sling's abstraction of the thing
  addressed by the request URI
       – Usually mapped to a JCR node
       – File system, database...
• Properties of resources
     – Path, e.g. JCR Item path
     – Type, e.g. JCR node type
     – Metadata, e.g. last modification date



25
Resource-first Request Processing
• URI Decomposition
         – Resource and representation
•        /slingshout/albums/travel.print.a4.html

             Resource Path       Selectors   Extension
• Content retrieved from repository
• Rendering based on content type




    26
Basic Request Processing Steps
• URI decomposition
• Resolve the resource (using URI)
• Resolve rendering script
     – Source: resource type
     – Scripts wrapped by generic servlet
• Create rendering chain
       – Configurable (servlet) filters
       – Rendering servlet
• Invoke rendering chain
27
Resource Resolver I
• Tasks:
     – Finding Resources
     – Getting Resources
     – Simplification of Query Execution




28
Resource Resolver II
• Gateway for resources
• Abstracts the path resolution
• Abstracts access to the persistence
  layer(s)
• Configurable
     – Mappings (Multi-site mgmt, beautify
        paths)




29
Resource-First Request Processing

 request
             Resource Resolver

                     Resource (resource type)
              Script Resolver


                 Script


  response


  30
Apache Sling



4 Scripting


31
Scripting Inside
• It's your choice
     – JSP, servlet, ESP, Scala
     – javax.script (Apache BSF)
     – own script handlers
• Scripts stored in OSGi bundles or repository
• Scripts are searched at configurable locatiosn
• Default servlets (or scripts)
        – JSON, XML
     – Registerable
     – Fallback / Last Ressort



32
Script Resolving I
• Path to script is built from ...
     – Configured search paths ( /apps, /libs )
     – Resource type converted to path
       ( slingshot/Album )
     – Selector string ( print/a4)
     – Request method & extension
       • GET --> Request URL Extension ( html )
       • else --> Method Name ( POST, PUT, ... )




33
Script Resolving Example
• URI:
  /slingshot/albums/travel.print.a4.html
• Resource: /slingshot/albums/travel
• Resource Type: slingshot:Album
• Script for GET:
     – /apps/slingshot/Album/print/a4/html.*
• Script for POST:
     – /libs/slingshot/Album/print/a4/POST.*


34
Script Resolving II
• Scripts are searched by best matching
     –   /apps/slingshot/Album/print/a4/html.*
     –   /libs/slingshot/Album/print/a4/html.*
     –   /apps/slingshot/Album/html.*
     –   /libs/slingshot/Album/html.*
• Resource has a type and a super type
     – Script inheritance
     – Default script (JSON...)



35
Powerful Scripting with Includes I
 Request: /slingshot/albums/travel.html


             Resource Resolver

                      Resource, resource type: slingshot:Album
              Script Resolver
                      Script: /libs/slingshot/Album/html.jsp
                 Script
                      Generates main html
                      sling:include with selectors
  response

  36
Powerful Scripting with Includes II
   Request: /slingshot/albums/travel.html

            Script (/libs/slingshot/Album/html.jsp)
   for(current : ChildResources)
       <sling:include resource="<%= current %>" addSelectors="main"/>
       …



                   Script Resolver

                 Script: /libs/slingshot/Photo/tree.html.jsp

                                Script
  response
  37
Resource-first Request Processing
•    ROA
•    URI decomposition
•    Resource resolving
•    Script resolving
         – Recursion
• Flexible script search algorithm




    38
Apache Sling



5 OSGi


39
Runtime Framework: Requirements
• Modularization – Modularity is key
        – Manage growing complexity
        – Support (dynamic) extensibility
• Lifecycle management
• Configuration management
• Dependency management
      – Modules, services
      – Different distributions
• Dynamic System Changes
 40
OSGi in 5..ehm..1 Minute

• Specification of a framework
• Module concept (bundles) with lifecycle
• Simple but powerful component model
       – Lifecycle management
       – Publish/Find/Bind service registration
• Dynamic!
• Uses the concept of bundles


  41
An OSGi Bundle
• Leverages the Java packaging
  mechanism: JAR files
• Contains Java classes and resources
• Additional meta-data
     – Implicit dependencies to other bundles
     – Package imports/exports




42
Services
• OSGi offers an API to register services
     – Service is registered by its interface
       name(s)
     – Implementation is bundle private
     – Several components for same service
       possible (from different bundles)
• Bundles can query services
     – By interface names
     – With additional filters


43
The OSGi Core
• Minimal but sufficient API for services
     – Minimal overhead: Good for simple
       bundles
     – No support for component management
     – No support for configuration management
     – Requires sometimes a lot of Java coding
• Additional (optional) OSGi extensions
     – Declarative Service Specification
     – Configuration Admin Service Specification


44
Dynamic Services
• OSGi Declarative Services Spec
  – XML Configuration (in a bundle)
  – Publishing services
  – Consuming services
    • Policy (static,dynamic), cardinality (0..1, 1..1,
      0..n)
  – Default configuration
  – Service Lifecycle management
• Various Implementations
  – Apache Felix SCR
Config Admin and Metatype
• OSGi Config Admin
  –   Configuration Manager
  –   Persistence storage
  –   API to retrieve/update/remove configs
  –   Works with Declarative Services
• OSGi Metatype Service
  – Description of bundle metadata
  – Description of service configurations
• Various Implementations
  – Apache Felix (Reference Implementation)
Apache Felix
• Top-level project (March 2007)
• Healthy and diverse community
• OSGi R4 (R4.2) implementation
  – Framework (frequent releases)
  – Services (continued development)
• Tools
  – Maven Plugins, Web Console, iPojo
• New sub project
    – Karaf : Runtime Environment (OSGi Kernel)
    – Sigil: OSGi tooling
Contributions to Apache Felix
•   Declarative service
•   Config admin
•   Metatype service
•   Preferences service
•   Web console (!)
•   Maven SCR Plugin (!)
Apache Sling Runtime
• Uses Apache Felix
• Runtime: Apache Sling Launchpad
    – Might be merged with Felix Karaf
• Two flavours
    – Standalone Java Application
    – Web application
• But Sling can be deployed in any
   OSGi framework!
Standalone Java Application
• One single executable JAR file
• Small Launcher
• Starts OSGi Framework (Apache
  Felix)
• Uses Jetty in an OSGi Bundle




50
Web Application
• Extends Standalone Application
     – Replaces Main with a Servlet
• Uses a bridge to connect Sling to the
  Servlet Container




51
Facts about Sling
• Sling API
     – No reference to JCR API
     – Uses resource abstraction
• 36 maintained bundles (many optional)
       – Over 25 additional bundles
• Highly modular and runtime configurable
     – OSGi framework
     – Everything is a OSGi bundle
• ConfigAdmin, Declarative Services, Metatype
• Felix Web Console


52
Apache Sling



6 Outlook


53
Current State
• Apache Sling is a top level project
• New convenience Release
     – Frequent releases of various bundles
• Demo Applications
• Increasing interest -> Increasing
  community




54
Development
• Easy to get started
         – Add content, add script, add more
            content
• Very flexible and dynamic
• Tooling
     –   Maven Plugins
     –   Apache Felix SCR Plugin
     –   Additional Sling Plugins
     –   But not tied to Maven of course :)

55
And remember...
• (Nearly) Everything is content
     – Application content
     – HTML pages, CSS and JavaScript files,
       static images
     – Documentation, resource bundles, etc.
     – With versioning, export/import, full text
       search, etc.




56
Manage the Web Challenges...
• Publish huge amount of information
      – Different types
      – Highly dynamic
      – Different output formats
• Web 2.0 ready
      – Collaboration and integration
• Fast changing requirements
      – Rapid prototyping and development
      – Dynamic, extensible but maintainable

 57
with Apache Sling: State of the Art
 • Modularity and dynamics (OSGi)
 • Content Management (JCR)
 • Resource oriented architecture
   (REST)
 • Scripting inside




  58
Apache Sling – The Fun is Back!
•    Web Framework
•    Java Content Repository
•    REST
•    Scripting inside
•    OSGi
•    Apache Open Source project
•    Check it out today!



    59
Apache Sling


     Thanks for your attention!



               Q&A


60

More Related Content

What's hot

Rest and Sling Resolution
Rest and Sling ResolutionRest and Sling Resolution
Rest and Sling ResolutionDEEPAK KHETAWAT
 
Content Management With Apache Jackrabbit
Content Management With Apache JackrabbitContent Management With Apache Jackrabbit
Content Management With Apache JackrabbitJukka Zitting
 
Introduction to JCR and Apache Jackrabbi
Introduction to JCR and Apache JackrabbiIntroduction to JCR and Apache Jackrabbi
Introduction to JCR and Apache JackrabbiJukka Zitting
 
Spring Framework - MVC
Spring Framework - MVCSpring Framework - MVC
Spring Framework - MVCDzmitry Naskou
 
AEM Sightly Deep Dive
AEM Sightly Deep DiveAEM Sightly Deep Dive
AEM Sightly Deep DiveGabriel Walt
 
Spring Framework - AOP
Spring Framework - AOPSpring Framework - AOP
Spring Framework - AOPDzmitry Naskou
 
AEM Sightly Template Language
AEM Sightly Template LanguageAEM Sightly Template Language
AEM Sightly Template LanguageGabriel Walt
 
Understanding Sling Models in AEM
Understanding Sling Models in AEMUnderstanding Sling Models in AEM
Understanding Sling Models in AEMAccunity Software
 
Spring Framework - Data Access
Spring Framework - Data AccessSpring Framework - Data Access
Spring Framework - Data AccessDzmitry Naskou
 
MongoDB Fundamentals
MongoDB FundamentalsMongoDB Fundamentals
MongoDB FundamentalsMongoDB
 
ePub 3, HTML 5 & CSS 3 (+ Fixed-Layout)
ePub 3, HTML 5 & CSS 3 (+ Fixed-Layout)ePub 3, HTML 5 & CSS 3 (+ Fixed-Layout)
ePub 3, HTML 5 & CSS 3 (+ Fixed-Layout)Clément Wehrung
 
PLAT-13 Metadata Extraction and Transformation
PLAT-13 Metadata Extraction and TransformationPLAT-13 Metadata Extraction and Transformation
PLAT-13 Metadata Extraction and TransformationAlfresco Software
 
HTL(Sightly) - All you need to know
HTL(Sightly) - All you need to knowHTL(Sightly) - All you need to know
HTL(Sightly) - All you need to knowPrabhdeep Singh
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDBMike Dirolf
 
Html 5 tutorial - By Bally Chohan
Html 5 tutorial - By Bally ChohanHtml 5 tutorial - By Bally Chohan
Html 5 tutorial - By Bally Chohanballychohanuk
 

What's hot (20)

Rest and Sling Resolution
Rest and Sling ResolutionRest and Sling Resolution
Rest and Sling Resolution
 
Content Management With Apache Jackrabbit
Content Management With Apache JackrabbitContent Management With Apache Jackrabbit
Content Management With Apache Jackrabbit
 
Introduction to JCR and Apache Jackrabbi
Introduction to JCR and Apache JackrabbiIntroduction to JCR and Apache Jackrabbi
Introduction to JCR and Apache Jackrabbi
 
Spring Framework - MVC
Spring Framework - MVCSpring Framework - MVC
Spring Framework - MVC
 
AEM Sightly Deep Dive
AEM Sightly Deep DiveAEM Sightly Deep Dive
AEM Sightly Deep Dive
 
Spring Framework - AOP
Spring Framework - AOPSpring Framework - AOP
Spring Framework - AOP
 
AEM Sightly Template Language
AEM Sightly Template LanguageAEM Sightly Template Language
AEM Sightly Template Language
 
An introduction to MongoDB
An introduction to MongoDBAn introduction to MongoDB
An introduction to MongoDB
 
Understanding Sling Models in AEM
Understanding Sling Models in AEMUnderstanding Sling Models in AEM
Understanding Sling Models in AEM
 
Spring Framework - Data Access
Spring Framework - Data AccessSpring Framework - Data Access
Spring Framework - Data Access
 
MongoDB Fundamentals
MongoDB FundamentalsMongoDB Fundamentals
MongoDB Fundamentals
 
Osgi
OsgiOsgi
Osgi
 
ePub 3, HTML 5 & CSS 3 (+ Fixed-Layout)
ePub 3, HTML 5 & CSS 3 (+ Fixed-Layout)ePub 3, HTML 5 & CSS 3 (+ Fixed-Layout)
ePub 3, HTML 5 & CSS 3 (+ Fixed-Layout)
 
PLAT-13 Metadata Extraction and Transformation
PLAT-13 Metadata Extraction and TransformationPLAT-13 Metadata Extraction and Transformation
PLAT-13 Metadata Extraction and Transformation
 
Gradle Introduction
Gradle IntroductionGradle Introduction
Gradle Introduction
 
HTL(Sightly) - All you need to know
HTL(Sightly) - All you need to knowHTL(Sightly) - All you need to know
HTL(Sightly) - All you need to know
 
CSS
CSSCSS
CSS
 
Alfresco Certificates
Alfresco Certificates Alfresco Certificates
Alfresco Certificates
 
Introduction to MongoDB
Introduction to MongoDBIntroduction to MongoDB
Introduction to MongoDB
 
Html 5 tutorial - By Bally Chohan
Html 5 tutorial - By Bally ChohanHtml 5 tutorial - By Bally Chohan
Html 5 tutorial - By Bally Chohan
 

Viewers also liked

Monitoring OSGi Applications with the Web Console
Monitoring OSGi Applications with the Web ConsoleMonitoring OSGi Applications with the Web Console
Monitoring OSGi Applications with the Web ConsoleCarsten Ziegeler
 
Lean Microservices with OSGi - Christian Schneider
Lean Microservices with OSGi - Christian SchneiderLean Microservices with OSGi - Christian Schneider
Lean Microservices with OSGi - Christian Schneidermfrancis
 
WebSockets and Equinox OSGi in a Servlet Container - Nedelcho Delchev
WebSockets and Equinox OSGi in a Servlet Container - Nedelcho DelchevWebSockets and Equinox OSGi in a Servlet Container - Nedelcho Delchev
WebSockets and Equinox OSGi in a Servlet Container - Nedelcho Delchevmfrancis
 
OSGi for outsiders - Milen Dyankov
OSGi for outsiders - Milen DyankovOSGi for outsiders - Milen Dyankov
OSGi for outsiders - Milen Dyankovmfrancis
 
Distributed Eventing in OSGi - Carsten Ziegeler
Distributed Eventing in OSGi - Carsten ZiegelerDistributed Eventing in OSGi - Carsten Ziegeler
Distributed Eventing in OSGi - Carsten Ziegelermfrancis
 
Programming WebSockets - OSCON 2010
Programming WebSockets - OSCON 2010Programming WebSockets - OSCON 2010
Programming WebSockets - OSCON 2010sullis
 
Getting to the Next Level with Eclipse Concierge - Jan Rellermeyer + Tim Verb...
Getting to the Next Level with Eclipse Concierge - Jan Rellermeyer + Tim Verb...Getting to the Next Level with Eclipse Concierge - Jan Rellermeyer + Tim Verb...
Getting to the Next Level with Eclipse Concierge - Jan Rellermeyer + Tim Verb...mfrancis
 
OSGi Specification Evolution - BJ Hargrave
OSGi Specification Evolution - BJ HargraveOSGi Specification Evolution - BJ Hargrave
OSGi Specification Evolution - BJ Hargravemfrancis
 
Service oriented web development with OSGi
Service oriented web development with OSGiService oriented web development with OSGi
Service oriented web development with OSGiCarsten Ziegeler
 
OSGi Best Practices - Tim Ward
OSGi Best Practices - Tim WardOSGi Best Practices - Tim Ward
OSGi Best Practices - Tim Wardmfrancis
 
RESTful Web Applications with Apache Sling
RESTful Web Applications with Apache SlingRESTful Web Applications with Apache Sling
RESTful Web Applications with Apache SlingBertrand Delacretaz
 
Distributed Eventing in OSGi
Distributed Eventing in OSGiDistributed Eventing in OSGi
Distributed Eventing in OSGiCarsten Ziegeler
 
OSGi toolchain from the ground up - Matteo Rulli
OSGi toolchain from the ground up - Matteo RulliOSGi toolchain from the ground up - Matteo Rulli
OSGi toolchain from the ground up - Matteo Rullimfrancis
 
Use Case: Building OSGi Enterprise Applications (QCon 14)
Use Case: Building OSGi Enterprise Applications (QCon 14)Use Case: Building OSGi Enterprise Applications (QCon 14)
Use Case: Building OSGi Enterprise Applications (QCon 14)Carsten Ziegeler
 
Infrastructure as code: running microservices on AWS using Docker, Terraform,...
Infrastructure as code: running microservices on AWS using Docker, Terraform,...Infrastructure as code: running microservices on AWS using Docker, Terraform,...
Infrastructure as code: running microservices on AWS using Docker, Terraform,...Yevgeniy Brikman
 

Viewers also liked (17)

Monitoring OSGi Applications with the Web Console
Monitoring OSGi Applications with the Web ConsoleMonitoring OSGi Applications with the Web Console
Monitoring OSGi Applications with the Web Console
 
Lean Microservices with OSGi - Christian Schneider
Lean Microservices with OSGi - Christian SchneiderLean Microservices with OSGi - Christian Schneider
Lean Microservices with OSGi - Christian Schneider
 
WebSockets and Equinox OSGi in a Servlet Container - Nedelcho Delchev
WebSockets and Equinox OSGi in a Servlet Container - Nedelcho DelchevWebSockets and Equinox OSGi in a Servlet Container - Nedelcho Delchev
WebSockets and Equinox OSGi in a Servlet Container - Nedelcho Delchev
 
OSGi for outsiders - Milen Dyankov
OSGi for outsiders - Milen DyankovOSGi for outsiders - Milen Dyankov
OSGi for outsiders - Milen Dyankov
 
Distributed Eventing in OSGi - Carsten Ziegeler
Distributed Eventing in OSGi - Carsten ZiegelerDistributed Eventing in OSGi - Carsten Ziegeler
Distributed Eventing in OSGi - Carsten Ziegeler
 
Programming WebSockets - OSCON 2010
Programming WebSockets - OSCON 2010Programming WebSockets - OSCON 2010
Programming WebSockets - OSCON 2010
 
Getting to the Next Level with Eclipse Concierge - Jan Rellermeyer + Tim Verb...
Getting to the Next Level with Eclipse Concierge - Jan Rellermeyer + Tim Verb...Getting to the Next Level with Eclipse Concierge - Jan Rellermeyer + Tim Verb...
Getting to the Next Level with Eclipse Concierge - Jan Rellermeyer + Tim Verb...
 
Reactive applications
Reactive applicationsReactive applications
Reactive applications
 
OSGi Specification Evolution - BJ Hargrave
OSGi Specification Evolution - BJ HargraveOSGi Specification Evolution - BJ Hargrave
OSGi Specification Evolution - BJ Hargrave
 
Service oriented web development with OSGi
Service oriented web development with OSGiService oriented web development with OSGi
Service oriented web development with OSGi
 
OSGi Best Practices - Tim Ward
OSGi Best Practices - Tim WardOSGi Best Practices - Tim Ward
OSGi Best Practices - Tim Ward
 
RESTful Web Applications with Apache Sling
RESTful Web Applications with Apache SlingRESTful Web Applications with Apache Sling
RESTful Web Applications with Apache Sling
 
Distributed Eventing in OSGi
Distributed Eventing in OSGiDistributed Eventing in OSGi
Distributed Eventing in OSGi
 
OSGi toolchain from the ground up - Matteo Rulli
OSGi toolchain from the ground up - Matteo RulliOSGi toolchain from the ground up - Matteo Rulli
OSGi toolchain from the ground up - Matteo Rulli
 
Use Case: Building OSGi Enterprise Applications (QCon 14)
Use Case: Building OSGi Enterprise Applications (QCon 14)Use Case: Building OSGi Enterprise Applications (QCon 14)
Use Case: Building OSGi Enterprise Applications (QCon 14)
 
Infrastructure as code: running microservices on AWS using Docker, Terraform,...
Infrastructure as code: running microservices on AWS using Docker, Terraform,...Infrastructure as code: running microservices on AWS using Docker, Terraform,...
Infrastructure as code: running microservices on AWS using Docker, Terraform,...
 
The AI Rush
The AI RushThe AI Rush
The AI Rush
 

Similar to OSGi, Scripting and REST, Building Webapps With Apache Sling

Melbourne User Group OAK and MongoDB
Melbourne User Group OAK and MongoDBMelbourne User Group OAK and MongoDB
Melbourne User Group OAK and MongoDBYuval Ararat
 
Rails - getting started
Rails - getting startedRails - getting started
Rails - getting startedTrue North
 
Ruby On Rails
Ruby On RailsRuby On Rails
Ruby On Railsiradarji
 
JCR In Action (ApacheCon US 2009)
JCR In Action (ApacheCon US 2009)JCR In Action (ApacheCon US 2009)
JCR In Action (ApacheCon US 2009)Carsten Ziegeler
 
Spider进化论
Spider进化论Spider进化论
Spider进化论cjhacker
 
Data Science at Scale: Using Apache Spark for Data Science at Bitly
Data Science at Scale: Using Apache Spark for Data Science at BitlyData Science at Scale: Using Apache Spark for Data Science at Bitly
Data Science at Scale: Using Apache Spark for Data Science at BitlySarah Guido
 
Rails 3.1 Asset pipeline
Rails 3.1 Asset pipelineRails 3.1 Asset pipeline
Rails 3.1 Asset pipelinejeremyolliver
 
Play Framework and Activator
Play Framework and ActivatorPlay Framework and Activator
Play Framework and ActivatorKevin Webber
 
Drupal and Apache Stanbol
Drupal and Apache StanbolDrupal and Apache Stanbol
Drupal and Apache StanbolAlkuvoima
 
Programming the Semantic Web
Programming the Semantic WebProgramming the Semantic Web
Programming the Semantic WebLuigi De Russis
 
Eclipse Enterprise Content Repository (ECR)
Eclipse Enterprise Content Repository (ECR)Eclipse Enterprise Content Repository (ECR)
Eclipse Enterprise Content Repository (ECR)Florent Guillaume
 
Elasticsearch, Logstash, Kibana. Cool search, analytics, data mining and more...
Elasticsearch, Logstash, Kibana. Cool search, analytics, data mining and more...Elasticsearch, Logstash, Kibana. Cool search, analytics, data mining and more...
Elasticsearch, Logstash, Kibana. Cool search, analytics, data mining and more...Oleksiy Panchenko
 
Introduction to Riak and Ripple (KC.rb)
Introduction to Riak and Ripple (KC.rb)Introduction to Riak and Ripple (KC.rb)
Introduction to Riak and Ripple (KC.rb)Sean Cribbs
 
Open shift enterprise 3.1 paas on kubernetes
Open shift enterprise 3.1   paas on kubernetesOpen shift enterprise 3.1   paas on kubernetes
Open shift enterprise 3.1 paas on kubernetesSamuel Terburg
 
NoSQL, Apache SOLR and Apache Hadoop
NoSQL, Apache SOLR and Apache HadoopNoSQL, Apache SOLR and Apache Hadoop
NoSQL, Apache SOLR and Apache HadoopDmitry Kan
 
using-apache-spark-for-generating-elasticsearch-indices-offline
using-apache-spark-for-generating-elasticsearch-indices-offlineusing-apache-spark-for-generating-elasticsearch-indices-offline
using-apache-spark-for-generating-elasticsearch-indices-offlineAndrej Babolcai
 

Similar to OSGi, Scripting and REST, Building Webapps With Apache Sling (20)

Melbourne User Group OAK and MongoDB
Melbourne User Group OAK and MongoDBMelbourne User Group OAK and MongoDB
Melbourne User Group OAK and MongoDB
 
Rails - getting started
Rails - getting startedRails - getting started
Rails - getting started
 
Ruby On Rails
Ruby On RailsRuby On Rails
Ruby On Rails
 
JCR In Action (ApacheCon US 2009)
JCR In Action (ApacheCon US 2009)JCR In Action (ApacheCon US 2009)
JCR In Action (ApacheCon US 2009)
 
Spider进化论
Spider进化论Spider进化论
Spider进化论
 
Introduction to CQ5
Introduction to CQ5Introduction to CQ5
Introduction to CQ5
 
Data Science at Scale: Using Apache Spark for Data Science at Bitly
Data Science at Scale: Using Apache Spark for Data Science at BitlyData Science at Scale: Using Apache Spark for Data Science at Bitly
Data Science at Scale: Using Apache Spark for Data Science at Bitly
 
Rails 3.1 Asset pipeline
Rails 3.1 Asset pipelineRails 3.1 Asset pipeline
Rails 3.1 Asset pipeline
 
Play Framework and Activator
Play Framework and ActivatorPlay Framework and Activator
Play Framework and Activator
 
RDFauthor (EKAW)
RDFauthor (EKAW)RDFauthor (EKAW)
RDFauthor (EKAW)
 
Drupal and Apache Stanbol
Drupal and Apache StanbolDrupal and Apache Stanbol
Drupal and Apache Stanbol
 
Publishing Linked Data from RDB
Publishing Linked Data from RDBPublishing Linked Data from RDB
Publishing Linked Data from RDB
 
Programming the Semantic Web
Programming the Semantic WebProgramming the Semantic Web
Programming the Semantic Web
 
Eclipse Enterprise Content Repository (ECR)
Eclipse Enterprise Content Repository (ECR)Eclipse Enterprise Content Repository (ECR)
Eclipse Enterprise Content Repository (ECR)
 
Elasticsearch, Logstash, Kibana. Cool search, analytics, data mining and more...
Elasticsearch, Logstash, Kibana. Cool search, analytics, data mining and more...Elasticsearch, Logstash, Kibana. Cool search, analytics, data mining and more...
Elasticsearch, Logstash, Kibana. Cool search, analytics, data mining and more...
 
Apache Spark in Industry
Apache Spark in IndustryApache Spark in Industry
Apache Spark in Industry
 
Introduction to Riak and Ripple (KC.rb)
Introduction to Riak and Ripple (KC.rb)Introduction to Riak and Ripple (KC.rb)
Introduction to Riak and Ripple (KC.rb)
 
Open shift enterprise 3.1 paas on kubernetes
Open shift enterprise 3.1   paas on kubernetesOpen shift enterprise 3.1   paas on kubernetes
Open shift enterprise 3.1 paas on kubernetes
 
NoSQL, Apache SOLR and Apache Hadoop
NoSQL, Apache SOLR and Apache HadoopNoSQL, Apache SOLR and Apache Hadoop
NoSQL, Apache SOLR and Apache Hadoop
 
using-apache-spark-for-generating-elasticsearch-indices-offline
using-apache-spark-for-generating-elasticsearch-indices-offlineusing-apache-spark-for-generating-elasticsearch-indices-offline
using-apache-spark-for-generating-elasticsearch-indices-offline
 

More from Carsten Ziegeler

What's cool in the new and updated OSGi Specs
What's cool in the new and updated OSGi SpecsWhat's cool in the new and updated OSGi Specs
What's cool in the new and updated OSGi SpecsCarsten Ziegeler
 
What's cool in the new and updated OSGi specs
What's cool in the new and updated OSGi specsWhat's cool in the new and updated OSGi specs
What's cool in the new and updated OSGi specsCarsten Ziegeler
 
Apache Sling - Distributed Eventing, Discovery, and Jobs (adaptTo 2013)
Apache Sling - Distributed Eventing, Discovery, and Jobs (adaptTo 2013)Apache Sling - Distributed Eventing, Discovery, and Jobs (adaptTo 2013)
Apache Sling - Distributed Eventing, Discovery, and Jobs (adaptTo 2013)Carsten Ziegeler
 
Adobe AEM - From Eventing to Job Processing
Adobe AEM - From Eventing to Job ProcessingAdobe AEM - From Eventing to Job Processing
Adobe AEM - From Eventing to Job ProcessingCarsten Ziegeler
 
Embrace Change - Embrace OSGi
Embrace Change - Embrace OSGiEmbrace Change - Embrace OSGi
Embrace Change - Embrace OSGiCarsten Ziegeler
 
Apache Sanselan (ApacheCon US 2007 FFT)
Apache Sanselan (ApacheCon US 2007 FFT)Apache Sanselan (ApacheCon US 2007 FFT)
Apache Sanselan (ApacheCon US 2007 FFT)Carsten Ziegeler
 
Apache iBatis (ApacheCon US 2007)
Apache iBatis (ApacheCon US 2007)Apache iBatis (ApacheCon US 2007)
Apache iBatis (ApacheCon US 2007)Carsten Ziegeler
 
JCR In Action (ApacheCon US 2007)
JCR In Action (ApacheCon US 2007)JCR In Action (ApacheCon US 2007)
JCR In Action (ApacheCon US 2007)Carsten Ziegeler
 
Apache Portals Panel (ApacheCon US 2007)
Apache Portals Panel (ApacheCon US 2007)Apache Portals Panel (ApacheCon US 2007)
Apache Portals Panel (ApacheCon US 2007)Carsten Ziegeler
 
JCR In Action (ApacheCon EU 2008)
JCR In Action (ApacheCon EU 2008)JCR In Action (ApacheCon EU 2008)
JCR In Action (ApacheCon EU 2008)Carsten Ziegeler
 
Maven SCR Plugin (ApacheCon EU 2008 - FFT)
Maven SCR Plugin (ApacheCon EU 2008 - FFT)Maven SCR Plugin (ApacheCon EU 2008 - FFT)
Maven SCR Plugin (ApacheCon EU 2008 - FFT)Carsten Ziegeler
 

More from Carsten Ziegeler (12)

What's cool in the new and updated OSGi Specs
What's cool in the new and updated OSGi SpecsWhat's cool in the new and updated OSGi Specs
What's cool in the new and updated OSGi Specs
 
What's cool in the new and updated OSGi specs
What's cool in the new and updated OSGi specsWhat's cool in the new and updated OSGi specs
What's cool in the new and updated OSGi specs
 
Apache Sling - Distributed Eventing, Discovery, and Jobs (adaptTo 2013)
Apache Sling - Distributed Eventing, Discovery, and Jobs (adaptTo 2013)Apache Sling - Distributed Eventing, Discovery, and Jobs (adaptTo 2013)
Apache Sling - Distributed Eventing, Discovery, and Jobs (adaptTo 2013)
 
Adobe AEM - From Eventing to Job Processing
Adobe AEM - From Eventing to Job ProcessingAdobe AEM - From Eventing to Job Processing
Adobe AEM - From Eventing to Job Processing
 
Embrace Change - Embrace OSGi
Embrace Change - Embrace OSGiEmbrace Change - Embrace OSGi
Embrace Change - Embrace OSGi
 
Embrace OSGi
Embrace OSGiEmbrace OSGi
Embrace OSGi
 
Apache Sanselan (ApacheCon US 2007 FFT)
Apache Sanselan (ApacheCon US 2007 FFT)Apache Sanselan (ApacheCon US 2007 FFT)
Apache Sanselan (ApacheCon US 2007 FFT)
 
Apache iBatis (ApacheCon US 2007)
Apache iBatis (ApacheCon US 2007)Apache iBatis (ApacheCon US 2007)
Apache iBatis (ApacheCon US 2007)
 
JCR In Action (ApacheCon US 2007)
JCR In Action (ApacheCon US 2007)JCR In Action (ApacheCon US 2007)
JCR In Action (ApacheCon US 2007)
 
Apache Portals Panel (ApacheCon US 2007)
Apache Portals Panel (ApacheCon US 2007)Apache Portals Panel (ApacheCon US 2007)
Apache Portals Panel (ApacheCon US 2007)
 
JCR In Action (ApacheCon EU 2008)
JCR In Action (ApacheCon EU 2008)JCR In Action (ApacheCon EU 2008)
JCR In Action (ApacheCon EU 2008)
 
Maven SCR Plugin (ApacheCon EU 2008 - FFT)
Maven SCR Plugin (ApacheCon EU 2008 - FFT)Maven SCR Plugin (ApacheCon EU 2008 - FFT)
Maven SCR Plugin (ApacheCon EU 2008 - FFT)
 

Recently uploaded

Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Zilliz
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontologyjohnbeverley2021
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Orbitshub
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfOrbitshub
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxRemote DBA Services
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamUiPathCommunity
 

Recently uploaded (20)

Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)
 
Six Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal OntologySix Myths about Ontologies: The Basics of Formal Ontology
Six Myths about Ontologies: The Basics of Formal Ontology
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptx
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 

OSGi, Scripting and REST, Building Webapps With Apache Sling

  • 1. Carsten Ziegeler | Day Management AG OSGi, Scripting, REST Webapps with Apache Sling cziegeler@apache.org
  • 2. About • Member of the ASF – Sling, Felix, Cocoon, Portals, Sanselan, Excalibur, Incubator – PMC: Felix, Portals, Sling, Incubator, Excalibur (Chair) • RnD Team at Day Software • Article/Book Author, Technical Reviewer • JSR 286 Spec Group (Portlet API 2.0) 2
  • 3. Agenda – Apache Sling 1 Motivation 2 Content and JCR 3 Web and REST 4 Scripting 5 OSGi 6 Outlook 3
  • 5. Web Challenges • Publish huge amount of information – Different types – Highly dynamic – Different output formats • Web 2.0 ready – Collaboration and integration • Fast changing requirements – Rapid prototyping and development – Dynamic, extensible but maintainable 5
  • 6. Web Challenges • Publish huge amount of information – Different types JCR – Highly dynamic – Different output formats REST ROA • Web 2.0 ready – Collaboration and integration • Fast changing requirements Scripting – Rapid prototyping and development – Dynamic, extensible but maintainable OSGi 6
  • 7. Apache Sling – The Fun Is Back • Web framework th 5 Winner JAX Innovation Award 2008 • Java content repository (JCR) • ROA / REST • Scripting inside • OSGi • Apache Open Source top level project – http://sling.apache.org • Driving force behind several OSGi related projects at Apache 7
  • 10. Content Is Important • Apache Sling makes handling content easy • Java content repository (JCR) – Several different sources possible • Direct mapping: URL -> content – Configurable – http://myserver.domain/products/sling .html • Flexible rendering 10
  • 11. Content Repository I • Features of an RDBMS – Structure, integrity – Query, transactions • Features of a filesystem – Hierarchy, binaries – Locking, access control • All the other good stuff – Observation, versioning – Unstructured – Multi values, sort order, full text • Single repository for all content! 11
  • 12. JCR – JSR 170, JSR 283 • Content Repository for Java technology API • (Java) Standard – Supported by many vendors – Used by many products and projects – Several open source solutions • How do you connect to a CR? • How do you interact with a CR? JSR 283 – Version 2.0 – Final since September 09 12
  • 13. Sample Application: Slingshot • Digital Asset Management – Hierarchical storage of pictures – Upload – Tagging Poor man's flickr... – Searching – Automatic thumbnail generation 13 13
  • 14. Slingshot Content Structure Travel Family Europe Weddings Amsterdam Basel 2008 2007 City Photo Photo Photo Photo 14
  • 15. Content Repository II • Hierarchical content – Nodes and properties • Structured – Nodetypes and typed properties • And/or unstructured • Fine and coarse-grained • Single repository for all content! 15
  • 16. The Repository Model • Repository: one (or more) workspaces • Workspace contains a tree of items • Item: Node or property • Nodes provide the content structure – May have children • Actual data is stored as values of properties • Types and namespaces! 16
  • 17. Nodes and Properties Root Travel Family Europe “Images from Europe“ Weddings Amsterdam Basel 2008 2007 City Photo Photo Photo Photo „Once upon a time..“ Properties Implementation of JCR 17
  • 18. Apache Jackrabbit • JSR 170, JSR 283 reference implementation • Apache TLP since 2006 • Several releases • JCR 2.0 implementation end of 2009 • Additional components 18
  • 19. Leverage the standard node types • Type hierarchy • Content hierarchy nt:hierarchyNode nt:folder nt:file nt:linkedFile nt:unstructured 19
  • 20. Bottom-up modeling: Node types slingshot:album > nt:folder slingshot:tag - slingshot:description (string) - slingshot:description (string) - slingshot:date (date) slingshot:photo > nt:file - slingshot:description (string) - slingshot:location (string) - slingshot:tags (string[]) 20
  • 21. Top-down modeling: Hierarchy Travel Family Europe Weddings Amsterdam Basel 2008 2007 City Photo Photo Photo Photo 21
  • 22. Apache Sling 3 ROA and REST 22
  • 23. Resource Oriented Architecutre • Piece of information is a resource – News entry, product, photo... – (Descriptive) URI • Stateless – Request contains all relevant information • Use HTTP – Methods (GET, POST) for operations 23
  • 24. REST with Apache Sling • Default behaviour for GET • Creating/Updating content through POST – Default behaviour • Additional operations/method • Resource-first request processing! 24
  • 25. Resource • Sling's abstraction of the thing addressed by the request URI – Usually mapped to a JCR node – File system, database... • Properties of resources – Path, e.g. JCR Item path – Type, e.g. JCR node type – Metadata, e.g. last modification date 25
  • 26. Resource-first Request Processing • URI Decomposition – Resource and representation • /slingshout/albums/travel.print.a4.html Resource Path Selectors Extension • Content retrieved from repository • Rendering based on content type 26
  • 27. Basic Request Processing Steps • URI decomposition • Resolve the resource (using URI) • Resolve rendering script – Source: resource type – Scripts wrapped by generic servlet • Create rendering chain – Configurable (servlet) filters – Rendering servlet • Invoke rendering chain 27
  • 28. Resource Resolver I • Tasks: – Finding Resources – Getting Resources – Simplification of Query Execution 28
  • 29. Resource Resolver II • Gateway for resources • Abstracts the path resolution • Abstracts access to the persistence layer(s) • Configurable – Mappings (Multi-site mgmt, beautify paths) 29
  • 30. Resource-First Request Processing request Resource Resolver Resource (resource type) Script Resolver Script response 30
  • 32. Scripting Inside • It's your choice – JSP, servlet, ESP, Scala – javax.script (Apache BSF) – own script handlers • Scripts stored in OSGi bundles or repository • Scripts are searched at configurable locatiosn • Default servlets (or scripts) – JSON, XML – Registerable – Fallback / Last Ressort 32
  • 33. Script Resolving I • Path to script is built from ... – Configured search paths ( /apps, /libs ) – Resource type converted to path ( slingshot/Album ) – Selector string ( print/a4) – Request method & extension • GET --> Request URL Extension ( html ) • else --> Method Name ( POST, PUT, ... ) 33
  • 34. Script Resolving Example • URI: /slingshot/albums/travel.print.a4.html • Resource: /slingshot/albums/travel • Resource Type: slingshot:Album • Script for GET: – /apps/slingshot/Album/print/a4/html.* • Script for POST: – /libs/slingshot/Album/print/a4/POST.* 34
  • 35. Script Resolving II • Scripts are searched by best matching – /apps/slingshot/Album/print/a4/html.* – /libs/slingshot/Album/print/a4/html.* – /apps/slingshot/Album/html.* – /libs/slingshot/Album/html.* • Resource has a type and a super type – Script inheritance – Default script (JSON...) 35
  • 36. Powerful Scripting with Includes I Request: /slingshot/albums/travel.html Resource Resolver Resource, resource type: slingshot:Album Script Resolver Script: /libs/slingshot/Album/html.jsp Script Generates main html sling:include with selectors response 36
  • 37. Powerful Scripting with Includes II Request: /slingshot/albums/travel.html Script (/libs/slingshot/Album/html.jsp) for(current : ChildResources) <sling:include resource="<%= current %>" addSelectors="main"/> … Script Resolver Script: /libs/slingshot/Photo/tree.html.jsp Script response 37
  • 38. Resource-first Request Processing • ROA • URI decomposition • Resource resolving • Script resolving – Recursion • Flexible script search algorithm 38
  • 40. Runtime Framework: Requirements • Modularization – Modularity is key – Manage growing complexity – Support (dynamic) extensibility • Lifecycle management • Configuration management • Dependency management – Modules, services – Different distributions • Dynamic System Changes 40
  • 41. OSGi in 5..ehm..1 Minute • Specification of a framework • Module concept (bundles) with lifecycle • Simple but powerful component model – Lifecycle management – Publish/Find/Bind service registration • Dynamic! • Uses the concept of bundles 41
  • 42. An OSGi Bundle • Leverages the Java packaging mechanism: JAR files • Contains Java classes and resources • Additional meta-data – Implicit dependencies to other bundles – Package imports/exports 42
  • 43. Services • OSGi offers an API to register services – Service is registered by its interface name(s) – Implementation is bundle private – Several components for same service possible (from different bundles) • Bundles can query services – By interface names – With additional filters 43
  • 44. The OSGi Core • Minimal but sufficient API for services – Minimal overhead: Good for simple bundles – No support for component management – No support for configuration management – Requires sometimes a lot of Java coding • Additional (optional) OSGi extensions – Declarative Service Specification – Configuration Admin Service Specification 44
  • 45. Dynamic Services • OSGi Declarative Services Spec – XML Configuration (in a bundle) – Publishing services – Consuming services • Policy (static,dynamic), cardinality (0..1, 1..1, 0..n) – Default configuration – Service Lifecycle management • Various Implementations – Apache Felix SCR
  • 46. Config Admin and Metatype • OSGi Config Admin – Configuration Manager – Persistence storage – API to retrieve/update/remove configs – Works with Declarative Services • OSGi Metatype Service – Description of bundle metadata – Description of service configurations • Various Implementations – Apache Felix (Reference Implementation)
  • 47. Apache Felix • Top-level project (March 2007) • Healthy and diverse community • OSGi R4 (R4.2) implementation – Framework (frequent releases) – Services (continued development) • Tools – Maven Plugins, Web Console, iPojo • New sub project – Karaf : Runtime Environment (OSGi Kernel) – Sigil: OSGi tooling
  • 48. Contributions to Apache Felix • Declarative service • Config admin • Metatype service • Preferences service • Web console (!) • Maven SCR Plugin (!)
  • 49. Apache Sling Runtime • Uses Apache Felix • Runtime: Apache Sling Launchpad – Might be merged with Felix Karaf • Two flavours – Standalone Java Application – Web application • But Sling can be deployed in any OSGi framework!
  • 50. Standalone Java Application • One single executable JAR file • Small Launcher • Starts OSGi Framework (Apache Felix) • Uses Jetty in an OSGi Bundle 50
  • 51. Web Application • Extends Standalone Application – Replaces Main with a Servlet • Uses a bridge to connect Sling to the Servlet Container 51
  • 52. Facts about Sling • Sling API – No reference to JCR API – Uses resource abstraction • 36 maintained bundles (many optional) – Over 25 additional bundles • Highly modular and runtime configurable – OSGi framework – Everything is a OSGi bundle • ConfigAdmin, Declarative Services, Metatype • Felix Web Console 52
  • 54. Current State • Apache Sling is a top level project • New convenience Release – Frequent releases of various bundles • Demo Applications • Increasing interest -> Increasing community 54
  • 55. Development • Easy to get started – Add content, add script, add more content • Very flexible and dynamic • Tooling – Maven Plugins – Apache Felix SCR Plugin – Additional Sling Plugins – But not tied to Maven of course :) 55
  • 56. And remember... • (Nearly) Everything is content – Application content – HTML pages, CSS and JavaScript files, static images – Documentation, resource bundles, etc. – With versioning, export/import, full text search, etc. 56
  • 57. Manage the Web Challenges... • Publish huge amount of information – Different types – Highly dynamic – Different output formats • Web 2.0 ready – Collaboration and integration • Fast changing requirements – Rapid prototyping and development – Dynamic, extensible but maintainable 57
  • 58. with Apache Sling: State of the Art • Modularity and dynamics (OSGi) • Content Management (JCR) • Resource oriented architecture (REST) • Scripting inside 58
  • 59. Apache Sling – The Fun is Back! • Web Framework • Java Content Repository • REST • Scripting inside • OSGi • Apache Open Source project • Check it out today! 59
  • 60. Apache Sling Thanks for your attention! Q&A 60