SlideShare a Scribd company logo
1 of 57
Download to read offline
Multi-Bundle
                      Scoping in
                        OSGi
                                Glyn Normington


         50 µm lead sulphide
         assemblies each containing
         ~108 nanoparticles


Copyright VMware Inc. 2011. Licensed under the Eclipse Public License
Agenda
•Modules in Java
• Multi-bundle modules
• Scoping mechanisms
• Subsystems
Modules in Java
Modularity
the degree to which a system’s components
may be separated and recombined
the tightness of coupling between components
the degree to which the system architecture
controls the mixing and matching of components
Modularity
the degree to which a system’s components



information
may be separated and recombined
the tightness of coupling between components
the degree to which the system architecture



   hiding
controls the mixing and matching of components
Modules in Java
• Class
• Package
• JAR
• Class loader      }   OSGi bundle

• Module - Java 8
• Larger scale modules?
Multi-Bundle Modules
Information to Hide
• Bundle
• Package
• Generic capability
• Service
Example 1
Feature

 bundle       bundle

 bundle       bundle
Example 2
Scoped App

  bundle       bundle

  bundle       bundle
Example 3
Kernel

bundle       bundle

bundle       bundle
Scoping Mechanisms
Scoping Mechanisms
• x-internal/x-friends
• metadata rewriting
• composite bundle
• framework hooks
• region digraph
Eclipse x-* Directives
• Export-Package directives
• Enforced by framework
•   x-internal

•   x-friends

• Non-standard
• Naming friends is brittle
➡ Standard, maintainable mechanism
Metadata Rewriting
Hide internals:
   • Decorate referents
    • Bundles and packages
    • Generic capabilities
   • Fix references
   • Use service registry hooks
Metadata Rewriting
     in Virgo

     Demo ...
Metadata Rewriting
Issues:
• Suitable for isolated applications only
• Intrusive
• Complicates bundle update
• Can be coded round
• Non-standard
➡ Standard scoping in the framework
Composite Bundle
• OSGi draft spec
• Prototyped in Equinox, deprecated
• Uses framework instance
• Surrogate bundle represents “parent”
• Used in Virgo 2.1 to isolate the kernel
Composite Bundle
Issues:
• Implemented in the framework
• Cannot expose constituent bundles
• Hard to spec portably
➡ Superseded
Framework Hooks
• Part of OSGi 4.3 core
• Control visibility
• Enable framework to be partitioned
• 5 main hooks:
 • resolver hook
 • bundle find/event hooks
 • service find/event hooks
Framework Hooks
Issues:
• Low level
• Consistency of hooks
• Coexistence of sets of hooks
➡ Higher level API needed
Region Digraph
Graph Theory Interlude
Tree
DAG
Digraph
Graph
Region Digraph
•   Framework hook abstraction

•   Bundles partitioned into regions

•   Regions connected by filters

    •   Bundles

    •   Packages

    •   Generic capabilities

    •   Services
Example Digraph
    region A
       p3



            "allow p1"



      p1, p2



    region B
Example Digraph
    region A
                         visible: p1, p3
       p3



            "allow p1"



      p1, p2

                         visible: p1, p2
    region B
Example Digraph 2
region X



      "allow p1, p3"



  p1, p2          "allow p3, p4"     p3, p4



region Y                           region Z
Example Digraph 2
      region X
                         visible: p1, p3



             "allow p1, p3"



         p1, p2          "allow p3, p4"     p3, p4



      region Y                            region Z
visible: p1, p2, p3, p4
Region Digraph
• Equinox bundle
• Runs on standard framework hooks
• Persistent
• JMX
Region Digraph Uses
                                                     user region
• Virgo 3.0 kernel/user region
                                                               p3
                                                              s3, s4
                                                               b3


• Apache Aries “subsystems”                "allow s3"                  "allow p1, s1, b1"
  prototype                           (service of p1 type)




• Standalone:                                                 p1, p2
                                                              s1, s2
                                                              b1, b2
   “We're using [the region digraph]                         kernel
   essentially for a fully multi-tenant
   plugin system to Web applications.”
                          Robert Sauer
Region Digraph in Virgo
       Demo ...
Region Digraph API
public interface RegionDigraph ... {

	 Region createRegion(String regionName) throws BundleException;

    RegionFilterBuilder createRegionFilterBuilder();

    ...
}

public interface Region {

	 void connectRegion(Region headRegion, RegionFilter filter)
     throws BundleException;

    ...
}
Region Digraph
Issues:
• Too low level for application use
• Non-standard
➡ Standard, high-level programming model
Subsystems
Why Subsystems?
5 projects have multi-bundle constructs
• Poor portability
• Inconsistent terminology
• Diverse function
➡ Standard
Subsystems
• OSGi Enterprise Expert Group
• Scoping based on composite bundles
  framework hooks
• Public draft available (“RFC 152”)
What is a Subsystem?
• Group of constituents with dependencies
 • Constituents: bundles, subsystems, ...
 • Dependencies: loosely coupled pre-reqs
• Named and versioned
• Defined lifecycle
Subsystem Scoping

Subsystem type     Scoping

   application   contents hidden

   composite      configurable

    feature           none
Example 1

 Application


  Feature
Example 2
 Feature A


 Feature C


 Feature B
Example 3

Application A

Application B

Composite C
Scoping and Regions
Subsystem scoping can be
• defined in terms of
• implemented using
a region digraph
Complex Scoping 1
  App3

         FeatureQ
         FeatureR
         FeatureP

     CompositeC
Region Digraph
         Region A3
     App3   FeatureQ
              FeatureR
              FeatureP
                            App3

                                   FeatureQ
                                   FeatureR
Region C      CompositeC           FeatureP

                               CompositeC
Complex Scoping 2
        Root
    Application A
    Application B
    Composite C

    Composite D
    Application E
Region Digraph
         Root


App A   Comp D   App E
                             Root
                         Application A
                         Application B

App V   Comp C           Composite C

                         Composite D
                         Application E
Dependencies
        FeatureX

App1                App2

        FeatureY

       CompositeF
Installing Dependencies
                    Root
  "accept
transitive"


                 CompositeF



          App1                App2
Installing Dependencies
                  Root
  "accept
transitive"


               CompositeF



App1          App2   FeatureX   FeatureY
Region Digraph
Region    Region F     Region
 A1                     A2
          FeatureX

App1                   App2
          FeatureY

          CompositeF                    FeatureX

                                App1                App2

                                        FeatureY

                                       CompositeF
Conclusion
Modularity in Java:
• Class, package, JAR, class loader
• Modules in Java 8
• Larger modules?
Modularity in OSGi:
• Bundles
• Multi-bundle modules
• Subsystems
Further Information
•   Public draft of subsystems (RFC 152)
    •   http://www.osgi.org/Download/File?url=/download/osgi-early-draft-2011-09.pdf


•   Region digraph
    •   http://underlap.blogspot.com/2011/05/equinox-digraph-ready-for-use.html


•   Eclipse Virgo and the region digraph
    •   https://bugs.eclipse.org/bugs/show_bug.cgi?id=330776


•   Apache Aries use of region digraph
    •   https://issues.apache.org/jira/browse/ARIES-644


•   Multi-module modules and Java 8
    •   http://mail.openjdk.java.net/pipermail/jigsaw-dev/2011-October/001564.html
Thanks to...
• Wikipedia image courtesy of Wikipedia.org
• Field of Flowers by Paul Podsiadlo and Elena
  Shevchenko, courtesy of Argonne National
  Laboratory

More Related Content

What's hot

OpenSAF Symposium_Architecture_and_Roadmap_Update9.19.11
OpenSAF Symposium_Architecture_and_Roadmap_Update9.19.11OpenSAF Symposium_Architecture_and_Roadmap_Update9.19.11
OpenSAF Symposium_Architecture_and_Roadmap_Update9.19.11OpenSAF Foundation
 
OpenSAF Symposium_Python Bindings_9.21.11
OpenSAF Symposium_Python Bindings_9.21.11OpenSAF Symposium_Python Bindings_9.21.11
OpenSAF Symposium_Python Bindings_9.21.11OpenSAF Foundation
 
Subnet Pools and Pluggable IPAM
Subnet Pools and Pluggable IPAMSubnet Pools and Pluggable IPAM
Subnet Pools and Pluggable IPAMcarlbaldwin
 
Augmenting Flow Operations and Feedback on the Model Driven MD_SAL Approach i...
Augmenting Flow Operations and Feedback on the Model Driven MD_SAL Approach i...Augmenting Flow Operations and Feedback on the Model Driven MD_SAL Approach i...
Augmenting Flow Operations and Feedback on the Model Driven MD_SAL Approach i...Brent Salisbury
 
SimArch: A Layered Architectural Approach to Reduce the Development Effort of...
SimArch: A Layered Architectural Approach to Reduce the Development Effort of...SimArch: A Layered Architectural Approach to Reduce the Development Effort of...
SimArch: A Layered Architectural Approach to Reduce the Development Effort of...Daniele Gianni
 

What's hot (6)

OpenSAF Symposium_Architecture_and_Roadmap_Update9.19.11
OpenSAF Symposium_Architecture_and_Roadmap_Update9.19.11OpenSAF Symposium_Architecture_and_Roadmap_Update9.19.11
OpenSAF Symposium_Architecture_and_Roadmap_Update9.19.11
 
OpenSAF Symposium_Python Bindings_9.21.11
OpenSAF Symposium_Python Bindings_9.21.11OpenSAF Symposium_Python Bindings_9.21.11
OpenSAF Symposium_Python Bindings_9.21.11
 
BGP Advanced topics
BGP Advanced topicsBGP Advanced topics
BGP Advanced topics
 
Subnet Pools and Pluggable IPAM
Subnet Pools and Pluggable IPAMSubnet Pools and Pluggable IPAM
Subnet Pools and Pluggable IPAM
 
Augmenting Flow Operations and Feedback on the Model Driven MD_SAL Approach i...
Augmenting Flow Operations and Feedback on the Model Driven MD_SAL Approach i...Augmenting Flow Operations and Feedback on the Model Driven MD_SAL Approach i...
Augmenting Flow Operations and Feedback on the Model Driven MD_SAL Approach i...
 
SimArch: A Layered Architectural Approach to Reduce the Development Effort of...
SimArch: A Layered Architectural Approach to Reduce the Development Effort of...SimArch: A Layered Architectural Approach to Reduce the Development Effort of...
SimArch: A Layered Architectural Approach to Reduce the Development Effort of...
 

Viewers also liked

Conole vilnius 3_nov
Conole vilnius 3_novConole vilnius 3_nov
Conole vilnius 3_novgrainne
 
Conole poe
Conole poeConole poe
Conole poegrainne
 
Conole svea
Conole sveaConole svea
Conole sveagrainne
 
Conole compendium ld
Conole compendium ldConole compendium ld
Conole compendium ldgrainne
 
Conole ld overview
Conole ld overviewConole ld overview
Conole ld overviewgrainne
 
Conole sydney
Conole sydneyConole sydney
Conole sydneygrainne
 
Conole TechItUp Conference Kamloops
Conole TechItUp Conference KamloopsConole TechItUp Conference Kamloops
Conole TechItUp Conference Kamloopsgrainne
 
Klantreis De Nieuwe GGZ vanuit het perspectief van een hulpverlener
Klantreis De Nieuwe GGZ vanuit het perspectief van een hulpverlenerKlantreis De Nieuwe GGZ vanuit het perspectief van een hulpverlener
Klantreis De Nieuwe GGZ vanuit het perspectief van een hulpverlenerMichael Milo
 
Conole keynote bali
Conole keynote baliConole keynote bali
Conole keynote baligrainne
 
Conole iaidis 22_july
Conole iaidis 22_julyConole iaidis 22_july
Conole iaidis 22_julygrainne
 
Oer panel
Oer panelOer panel
Oer panelgrainne
 
2 09 groinne conole_july_final_2011
2 09 groinne conole_july_final_20112 09 groinne conole_july_final_2011
2 09 groinne conole_july_final_2011grainne
 
Chapters overview
Chapters overviewChapters overview
Chapters overviewgrainne
 
Conole opal webinar
Conole opal webinarConole opal webinar
Conole opal webinargrainne
 
Conole finland workshop
Conole finland workshopConole finland workshop
Conole finland workshopgrainne
 
Conole vilnius 3_nov
Conole vilnius 3_novConole vilnius 3_nov
Conole vilnius 3_novgrainne
 
Conole keynote icde_sept_28
Conole keynote icde_sept_28Conole keynote icde_sept_28
Conole keynote icde_sept_28grainne
 
Conole finland 5_june
Conole finland 5_juneConole finland 5_june
Conole finland 5_junegrainne
 
Conole opal
Conole opalConole opal
Conole opalgrainne
 

Viewers also liked (20)

Conole vilnius 3_nov
Conole vilnius 3_novConole vilnius 3_nov
Conole vilnius 3_nov
 
Conole
ConoleConole
Conole
 
Conole poe
Conole poeConole poe
Conole poe
 
Conole svea
Conole sveaConole svea
Conole svea
 
Conole compendium ld
Conole compendium ldConole compendium ld
Conole compendium ld
 
Conole ld overview
Conole ld overviewConole ld overview
Conole ld overview
 
Conole sydney
Conole sydneyConole sydney
Conole sydney
 
Conole TechItUp Conference Kamloops
Conole TechItUp Conference KamloopsConole TechItUp Conference Kamloops
Conole TechItUp Conference Kamloops
 
Klantreis De Nieuwe GGZ vanuit het perspectief van een hulpverlener
Klantreis De Nieuwe GGZ vanuit het perspectief van een hulpverlenerKlantreis De Nieuwe GGZ vanuit het perspectief van een hulpverlener
Klantreis De Nieuwe GGZ vanuit het perspectief van een hulpverlener
 
Conole keynote bali
Conole keynote baliConole keynote bali
Conole keynote bali
 
Conole iaidis 22_july
Conole iaidis 22_julyConole iaidis 22_july
Conole iaidis 22_july
 
Oer panel
Oer panelOer panel
Oer panel
 
2 09 groinne conole_july_final_2011
2 09 groinne conole_july_final_20112 09 groinne conole_july_final_2011
2 09 groinne conole_july_final_2011
 
Chapters overview
Chapters overviewChapters overview
Chapters overview
 
Conole opal webinar
Conole opal webinarConole opal webinar
Conole opal webinar
 
Conole finland workshop
Conole finland workshopConole finland workshop
Conole finland workshop
 
Conole vilnius 3_nov
Conole vilnius 3_novConole vilnius 3_nov
Conole vilnius 3_nov
 
Conole keynote icde_sept_28
Conole keynote icde_sept_28Conole keynote icde_sept_28
Conole keynote icde_sept_28
 
Conole finland 5_june
Conole finland 5_juneConole finland 5_june
Conole finland 5_june
 
Conole opal
Conole opalConole opal
Conole opal
 

Similar to Conole vilnius 3_nov

EclipseCon Europe 2011 Virgo 3.0
EclipseCon Europe 2011 Virgo 3.0EclipseCon Europe 2011 Virgo 3.0
EclipseCon Europe 2011 Virgo 3.0Christopher Frost
 
Creating a Service Platform for .NET - Clément Escoffier, University of Grenoble
Creating a Service Platform for .NET - Clément Escoffier, University of GrenobleCreating a Service Platform for .NET - Clément Escoffier, University of Grenoble
Creating a Service Platform for .NET - Clément Escoffier, University of Grenoblemfrancis
 
Practical OSGi Subsystems
Practical OSGi SubsystemsPractical OSGi Subsystems
Practical OSGi Subsystemsglynnormington
 
The A2530x24xx AIR Module for ZigBee Standard Applications
The A2530x24xx AIR Module for ZigBee Standard ApplicationsThe A2530x24xx AIR Module for ZigBee Standard Applications
The A2530x24xx AIR Module for ZigBee Standard ApplicationsAnaren, Inc.
 
Data Diffing Based Software Architecture Patterns
Data Diffing Based Software Architecture PatternsData Diffing Based Software Architecture Patterns
Data Diffing Based Software Architecture PatternsHuahai Yang
 
Rook - cloud-native storage
Rook - cloud-native storageRook - cloud-native storage
Rook - cloud-native storageKarol Chrapek
 
CloudFest Denver Windows Azure Design Patterns
CloudFest Denver Windows Azure Design PatternsCloudFest Denver Windows Azure Design Patterns
CloudFest Denver Windows Azure Design PatternsDavid Pallmann
 
K8s Pod Scheduling - Deep Dive. By Tsahi Duek.
K8s Pod Scheduling - Deep Dive. By Tsahi Duek.K8s Pod Scheduling - Deep Dive. By Tsahi Duek.
K8s Pod Scheduling - Deep Dive. By Tsahi Duek.Cloud Native Day Tel Aviv
 
Docker Swarm and Traefik 2.0
Docker Swarm and Traefik 2.0Docker Swarm and Traefik 2.0
Docker Swarm and Traefik 2.0Jakub Hajek
 
meetPHP#8 - PHP startups prototypes
meetPHP#8 - PHP startups prototypesmeetPHP#8 - PHP startups prototypes
meetPHP#8 - PHP startups prototypesMax Małecki
 
Go語言開發APM微服務在Kubernetes之經驗分享
Go語言開發APM微服務在Kubernetes之經驗分享Go語言開發APM微服務在Kubernetes之經驗分享
Go語言開發APM微服務在Kubernetes之經驗分享Te-Yen Liu
 
The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ...
 The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ... The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ...
The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ...Josef Adersberger
 
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...QAware GmbH
 
Solaris cluster roadshow day 1 sales overview
Solaris cluster roadshow day 1 sales overviewSolaris cluster roadshow day 1 sales overview
Solaris cluster roadshow day 1 sales overviewxKinAnx
 
Velocity-EHF for Android
Velocity-EHF for AndroidVelocity-EHF for Android
Velocity-EHF for Androidmichaeljfawcett
 
Framework Engineering
Framework EngineeringFramework Engineering
Framework EngineeringYoungSu Son
 
HA and DR for Cloud Workloads
HA and DR for Cloud WorkloadsHA and DR for Cloud Workloads
HA and DR for Cloud Workloadsswamybabu
 
Apache Geode Meetup, London
Apache Geode Meetup, LondonApache Geode Meetup, London
Apache Geode Meetup, LondonApache Geode
 
2_ESNOG_arista.pptx
2_ESNOG_arista.pptx2_ESNOG_arista.pptx
2_ESNOG_arista.pptxVikram Reddy
 

Similar to Conole vilnius 3_nov (20)

Eclipse Virgo
Eclipse VirgoEclipse Virgo
Eclipse Virgo
 
EclipseCon Europe 2011 Virgo 3.0
EclipseCon Europe 2011 Virgo 3.0EclipseCon Europe 2011 Virgo 3.0
EclipseCon Europe 2011 Virgo 3.0
 
Creating a Service Platform for .NET - Clément Escoffier, University of Grenoble
Creating a Service Platform for .NET - Clément Escoffier, University of GrenobleCreating a Service Platform for .NET - Clément Escoffier, University of Grenoble
Creating a Service Platform for .NET - Clément Escoffier, University of Grenoble
 
Practical OSGi Subsystems
Practical OSGi SubsystemsPractical OSGi Subsystems
Practical OSGi Subsystems
 
The A2530x24xx AIR Module for ZigBee Standard Applications
The A2530x24xx AIR Module for ZigBee Standard ApplicationsThe A2530x24xx AIR Module for ZigBee Standard Applications
The A2530x24xx AIR Module for ZigBee Standard Applications
 
Data Diffing Based Software Architecture Patterns
Data Diffing Based Software Architecture PatternsData Diffing Based Software Architecture Patterns
Data Diffing Based Software Architecture Patterns
 
Rook - cloud-native storage
Rook - cloud-native storageRook - cloud-native storage
Rook - cloud-native storage
 
CloudFest Denver Windows Azure Design Patterns
CloudFest Denver Windows Azure Design PatternsCloudFest Denver Windows Azure Design Patterns
CloudFest Denver Windows Azure Design Patterns
 
K8s Pod Scheduling - Deep Dive. By Tsahi Duek.
K8s Pod Scheduling - Deep Dive. By Tsahi Duek.K8s Pod Scheduling - Deep Dive. By Tsahi Duek.
K8s Pod Scheduling - Deep Dive. By Tsahi Duek.
 
Docker Swarm and Traefik 2.0
Docker Swarm and Traefik 2.0Docker Swarm and Traefik 2.0
Docker Swarm and Traefik 2.0
 
meetPHP#8 - PHP startups prototypes
meetPHP#8 - PHP startups prototypesmeetPHP#8 - PHP startups prototypes
meetPHP#8 - PHP startups prototypes
 
Go語言開發APM微服務在Kubernetes之經驗分享
Go語言開發APM微服務在Kubernetes之經驗分享Go語言開發APM微服務在Kubernetes之經驗分享
Go語言開發APM微服務在Kubernetes之經驗分享
 
The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ...
 The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ... The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ...
The Good, the Bad and the Ugly of Migrating Hundreds of Legacy Applications ...
 
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
Migrating Hundreds of Legacy Applications to Kubernetes - The Good, the Bad, ...
 
Solaris cluster roadshow day 1 sales overview
Solaris cluster roadshow day 1 sales overviewSolaris cluster roadshow day 1 sales overview
Solaris cluster roadshow day 1 sales overview
 
Velocity-EHF for Android
Velocity-EHF for AndroidVelocity-EHF for Android
Velocity-EHF for Android
 
Framework Engineering
Framework EngineeringFramework Engineering
Framework Engineering
 
HA and DR for Cloud Workloads
HA and DR for Cloud WorkloadsHA and DR for Cloud Workloads
HA and DR for Cloud Workloads
 
Apache Geode Meetup, London
Apache Geode Meetup, LondonApache Geode Meetup, London
Apache Geode Meetup, London
 
2_ESNOG_arista.pptx
2_ESNOG_arista.pptx2_ESNOG_arista.pptx
2_ESNOG_arista.pptx
 

More from grainne

Theory methodology
Theory methodologyTheory methodology
Theory methodologygrainne
 
Conole ld
Conole ldConole ld
Conole ldgrainne
 
Conole creativity
Conole creativityConole creativity
Conole creativitygrainne
 
References may2011
References may2011References may2011
References may2011grainne
 
Conole graz 25_may
Conole graz 25_mayConole graz 25_may
Conole graz 25_maygrainne
 
Conole graz
Conole grazConole graz
Conole grazgrainne
 
References may2011
References may2011References may2011
References may2011grainne
 
Chapter 15 pedagogical planners
Chapter 15 pedagogical plannersChapter 15 pedagogical planners
Chapter 15 pedagogical plannersgrainne
 
Chapter 14 case study cloudworks
Chapter 14 case study  cloudworksChapter 14 case study  cloudworks
Chapter 14 case study cloudworksgrainne
 
Chapter 13 online communities and interactions
Chapter 13 online communities and interactionsChapter 13 online communities and interactions
Chapter 13 online communities and interactionsgrainne
 
Chapter 11 open educational resources
Chapter 11 open educational resourcesChapter 11 open educational resources
Chapter 11 open educational resourcesgrainne
 

More from grainne (12)

Theory methodology
Theory methodologyTheory methodology
Theory methodology
 
Conole ld
Conole ldConole ld
Conole ld
 
Conole creativity
Conole creativityConole creativity
Conole creativity
 
References may2011
References may2011References may2011
References may2011
 
Conole graz 25_may
Conole graz 25_mayConole graz 25_may
Conole graz 25_may
 
Conole graz
Conole grazConole graz
Conole graz
 
Conole
ConoleConole
Conole
 
References may2011
References may2011References may2011
References may2011
 
Chapter 15 pedagogical planners
Chapter 15 pedagogical plannersChapter 15 pedagogical planners
Chapter 15 pedagogical planners
 
Chapter 14 case study cloudworks
Chapter 14 case study  cloudworksChapter 14 case study  cloudworks
Chapter 14 case study cloudworks
 
Chapter 13 online communities and interactions
Chapter 13 online communities and interactionsChapter 13 online communities and interactions
Chapter 13 online communities and interactions
 
Chapter 11 open educational resources
Chapter 11 open educational resourcesChapter 11 open educational resources
Chapter 11 open educational resources
 

Recently uploaded

KubeConEU24-Monitoring Kubernetes and Cloud Spend with OpenCost
KubeConEU24-Monitoring Kubernetes and Cloud Spend with OpenCostKubeConEU24-Monitoring Kubernetes and Cloud Spend with OpenCost
KubeConEU24-Monitoring Kubernetes and Cloud Spend with OpenCostMatt Ray
 
Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1DianaGray10
 
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1DianaGray10
 
Basic Building Blocks of Internet of Things.
Basic Building Blocks of Internet of Things.Basic Building Blocks of Internet of Things.
Basic Building Blocks of Internet of Things.YounusS2
 
Cybersecurity Workshop #1.pptx
Cybersecurity Workshop #1.pptxCybersecurity Workshop #1.pptx
Cybersecurity Workshop #1.pptxGDSC PJATK
 
9 Steps For Building Winning Founding Team
9 Steps For Building Winning Founding Team9 Steps For Building Winning Founding Team
9 Steps For Building Winning Founding TeamAdam Moalla
 
IESVE Software for Florida Code Compliance Using ASHRAE 90.1-2019
IESVE Software for Florida Code Compliance Using ASHRAE 90.1-2019IESVE Software for Florida Code Compliance Using ASHRAE 90.1-2019
IESVE Software for Florida Code Compliance Using ASHRAE 90.1-2019IES VE
 
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPAAnypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPAshyamraj55
 
activity_diagram_combine_v4_20190827.pdfactivity_diagram_combine_v4_20190827.pdf
activity_diagram_combine_v4_20190827.pdfactivity_diagram_combine_v4_20190827.pdfactivity_diagram_combine_v4_20190827.pdfactivity_diagram_combine_v4_20190827.pdf
activity_diagram_combine_v4_20190827.pdfactivity_diagram_combine_v4_20190827.pdfJamie (Taka) Wang
 
Nanopower In Semiconductor Industry.pdf
Nanopower  In Semiconductor Industry.pdfNanopower  In Semiconductor Industry.pdf
Nanopower In Semiconductor Industry.pdfPedro Manuel
 
Videogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdfVideogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdfinfogdgmi
 
UiPath Community: AI for UiPath Automation Developers
UiPath Community: AI for UiPath Automation DevelopersUiPath Community: AI for UiPath Automation Developers
UiPath Community: AI for UiPath Automation DevelopersUiPathCommunity
 
Bird eye's view on Camunda open source ecosystem
Bird eye's view on Camunda open source ecosystemBird eye's view on Camunda open source ecosystem
Bird eye's view on Camunda open source ecosystemAsko Soukka
 
UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6DianaGray10
 
Building Your Own AI Instance (TBLC AI )
Building Your Own AI Instance (TBLC AI )Building Your Own AI Instance (TBLC AI )
Building Your Own AI Instance (TBLC AI )Brian Pichman
 
Linked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond OntologiesLinked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond OntologiesDavid Newbury
 
Introduction to Matsuo Laboratory (ENG).pptx
Introduction to Matsuo Laboratory (ENG).pptxIntroduction to Matsuo Laboratory (ENG).pptx
Introduction to Matsuo Laboratory (ENG).pptxMatsuo Lab
 
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...UbiTrack UK
 
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve DecarbonizationUsing IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve DecarbonizationIES VE
 

Recently uploaded (20)

KubeConEU24-Monitoring Kubernetes and Cloud Spend with OpenCost
KubeConEU24-Monitoring Kubernetes and Cloud Spend with OpenCostKubeConEU24-Monitoring Kubernetes and Cloud Spend with OpenCost
KubeConEU24-Monitoring Kubernetes and Cloud Spend with OpenCost
 
Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1Secure your environment with UiPath and CyberArk technologies - Session 1
Secure your environment with UiPath and CyberArk technologies - Session 1
 
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1UiPath Platform: The Backend Engine Powering Your Automation - Session 1
UiPath Platform: The Backend Engine Powering Your Automation - Session 1
 
Basic Building Blocks of Internet of Things.
Basic Building Blocks of Internet of Things.Basic Building Blocks of Internet of Things.
Basic Building Blocks of Internet of Things.
 
201610817 - edge part1
201610817 - edge part1201610817 - edge part1
201610817 - edge part1
 
Cybersecurity Workshop #1.pptx
Cybersecurity Workshop #1.pptxCybersecurity Workshop #1.pptx
Cybersecurity Workshop #1.pptx
 
9 Steps For Building Winning Founding Team
9 Steps For Building Winning Founding Team9 Steps For Building Winning Founding Team
9 Steps For Building Winning Founding Team
 
IESVE Software for Florida Code Compliance Using ASHRAE 90.1-2019
IESVE Software for Florida Code Compliance Using ASHRAE 90.1-2019IESVE Software for Florida Code Compliance Using ASHRAE 90.1-2019
IESVE Software for Florida Code Compliance Using ASHRAE 90.1-2019
 
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPAAnypoint Code Builder , Google Pub sub connector and MuleSoft RPA
Anypoint Code Builder , Google Pub sub connector and MuleSoft RPA
 
activity_diagram_combine_v4_20190827.pdfactivity_diagram_combine_v4_20190827.pdf
activity_diagram_combine_v4_20190827.pdfactivity_diagram_combine_v4_20190827.pdfactivity_diagram_combine_v4_20190827.pdfactivity_diagram_combine_v4_20190827.pdf
activity_diagram_combine_v4_20190827.pdfactivity_diagram_combine_v4_20190827.pdf
 
Nanopower In Semiconductor Industry.pdf
Nanopower  In Semiconductor Industry.pdfNanopower  In Semiconductor Industry.pdf
Nanopower In Semiconductor Industry.pdf
 
Videogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdfVideogame localization & technology_ how to enhance the power of translation.pdf
Videogame localization & technology_ how to enhance the power of translation.pdf
 
UiPath Community: AI for UiPath Automation Developers
UiPath Community: AI for UiPath Automation DevelopersUiPath Community: AI for UiPath Automation Developers
UiPath Community: AI for UiPath Automation Developers
 
Bird eye's view on Camunda open source ecosystem
Bird eye's view on Camunda open source ecosystemBird eye's view on Camunda open source ecosystem
Bird eye's view on Camunda open source ecosystem
 
UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6UiPath Studio Web workshop series - Day 6
UiPath Studio Web workshop series - Day 6
 
Building Your Own AI Instance (TBLC AI )
Building Your Own AI Instance (TBLC AI )Building Your Own AI Instance (TBLC AI )
Building Your Own AI Instance (TBLC AI )
 
Linked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond OntologiesLinked Data in Production: Moving Beyond Ontologies
Linked Data in Production: Moving Beyond Ontologies
 
Introduction to Matsuo Laboratory (ENG).pptx
Introduction to Matsuo Laboratory (ENG).pptxIntroduction to Matsuo Laboratory (ENG).pptx
Introduction to Matsuo Laboratory (ENG).pptx
 
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
UWB Technology for Enhanced Indoor and Outdoor Positioning in Physiological M...
 
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve DecarbonizationUsing IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
Using IESVE for Loads, Sizing and Heat Pump Modeling to Achieve Decarbonization
 

Conole vilnius 3_nov

  • 1. Multi-Bundle Scoping in OSGi Glyn Normington 50 µm lead sulphide assemblies each containing ~108 nanoparticles Copyright VMware Inc. 2011. Licensed under the Eclipse Public License
  • 2. Agenda •Modules in Java • Multi-bundle modules • Scoping mechanisms • Subsystems
  • 4. Modularity the degree to which a system’s components may be separated and recombined the tightness of coupling between components the degree to which the system architecture controls the mixing and matching of components
  • 5. Modularity the degree to which a system’s components information may be separated and recombined the tightness of coupling between components the degree to which the system architecture hiding controls the mixing and matching of components
  • 6. Modules in Java • Class • Package • JAR • Class loader } OSGi bundle • Module - Java 8 • Larger scale modules?
  • 8. Information to Hide • Bundle • Package • Generic capability • Service
  • 9. Example 1 Feature bundle bundle bundle bundle
  • 10. Example 2 Scoped App bundle bundle bundle bundle
  • 11. Example 3 Kernel bundle bundle bundle bundle
  • 13. Scoping Mechanisms • x-internal/x-friends • metadata rewriting • composite bundle • framework hooks • region digraph
  • 14. Eclipse x-* Directives • Export-Package directives • Enforced by framework • x-internal • x-friends • Non-standard • Naming friends is brittle ➡ Standard, maintainable mechanism
  • 15. Metadata Rewriting Hide internals: • Decorate referents • Bundles and packages • Generic capabilities • Fix references • Use service registry hooks
  • 16. Metadata Rewriting in Virgo Demo ...
  • 17. Metadata Rewriting Issues: • Suitable for isolated applications only • Intrusive • Complicates bundle update • Can be coded round • Non-standard ➡ Standard scoping in the framework
  • 18. Composite Bundle • OSGi draft spec • Prototyped in Equinox, deprecated • Uses framework instance • Surrogate bundle represents “parent” • Used in Virgo 2.1 to isolate the kernel
  • 19. Composite Bundle Issues: • Implemented in the framework • Cannot expose constituent bundles • Hard to spec portably ➡ Superseded
  • 20. Framework Hooks • Part of OSGi 4.3 core • Control visibility • Enable framework to be partitioned • 5 main hooks: • resolver hook • bundle find/event hooks • service find/event hooks
  • 21. Framework Hooks Issues: • Low level • Consistency of hooks • Coexistence of sets of hooks ➡ Higher level API needed
  • 24. Tree
  • 25. DAG
  • 27. Graph
  • 28. Region Digraph • Framework hook abstraction • Bundles partitioned into regions • Regions connected by filters • Bundles • Packages • Generic capabilities • Services
  • 29. Example Digraph region A p3 "allow p1" p1, p2 region B
  • 30. Example Digraph region A visible: p1, p3 p3 "allow p1" p1, p2 visible: p1, p2 region B
  • 31. Example Digraph 2 region X "allow p1, p3" p1, p2 "allow p3, p4" p3, p4 region Y region Z
  • 32. Example Digraph 2 region X visible: p1, p3 "allow p1, p3" p1, p2 "allow p3, p4" p3, p4 region Y region Z visible: p1, p2, p3, p4
  • 33. Region Digraph • Equinox bundle • Runs on standard framework hooks • Persistent • JMX
  • 34. Region Digraph Uses user region • Virgo 3.0 kernel/user region p3 s3, s4 b3 • Apache Aries “subsystems” "allow s3" "allow p1, s1, b1" prototype (service of p1 type) • Standalone: p1, p2 s1, s2 b1, b2 “We're using [the region digraph] kernel essentially for a fully multi-tenant plugin system to Web applications.” Robert Sauer
  • 35. Region Digraph in Virgo Demo ...
  • 36. Region Digraph API public interface RegionDigraph ... { Region createRegion(String regionName) throws BundleException; RegionFilterBuilder createRegionFilterBuilder(); ... } public interface Region { void connectRegion(Region headRegion, RegionFilter filter) throws BundleException; ... }
  • 37. Region Digraph Issues: • Too low level for application use • Non-standard ➡ Standard, high-level programming model
  • 39. Why Subsystems? 5 projects have multi-bundle constructs • Poor portability • Inconsistent terminology • Diverse function ➡ Standard
  • 40. Subsystems • OSGi Enterprise Expert Group • Scoping based on composite bundles framework hooks • Public draft available (“RFC 152”)
  • 41. What is a Subsystem? • Group of constituents with dependencies • Constituents: bundles, subsystems, ... • Dependencies: loosely coupled pre-reqs • Named and versioned • Defined lifecycle
  • 42. Subsystem Scoping Subsystem type Scoping application contents hidden composite configurable feature none
  • 44. Example 2 Feature A Feature C Feature B
  • 46. Scoping and Regions Subsystem scoping can be • defined in terms of • implemented using a region digraph
  • 47. Complex Scoping 1 App3 FeatureQ FeatureR FeatureP CompositeC
  • 48. Region Digraph Region A3 App3 FeatureQ FeatureR FeatureP App3 FeatureQ FeatureR Region C CompositeC FeatureP CompositeC
  • 49. Complex Scoping 2 Root Application A Application B Composite C Composite D Application E
  • 50. Region Digraph Root App A Comp D App E Root Application A Application B App V Comp C Composite C Composite D Application E
  • 51. Dependencies FeatureX App1 App2 FeatureY CompositeF
  • 52. Installing Dependencies Root "accept transitive" CompositeF App1 App2
  • 53. Installing Dependencies Root "accept transitive" CompositeF App1 App2 FeatureX FeatureY
  • 54. Region Digraph Region Region F Region A1 A2 FeatureX App1 App2 FeatureY CompositeF FeatureX App1 App2 FeatureY CompositeF
  • 55. Conclusion Modularity in Java: • Class, package, JAR, class loader • Modules in Java 8 • Larger modules? Modularity in OSGi: • Bundles • Multi-bundle modules • Subsystems
  • 56. Further Information • Public draft of subsystems (RFC 152) • http://www.osgi.org/Download/File?url=/download/osgi-early-draft-2011-09.pdf • Region digraph • http://underlap.blogspot.com/2011/05/equinox-digraph-ready-for-use.html • Eclipse Virgo and the region digraph • https://bugs.eclipse.org/bugs/show_bug.cgi?id=330776 • Apache Aries use of region digraph • https://issues.apache.org/jira/browse/ARIES-644 • Multi-module modules and Java 8 • http://mail.openjdk.java.net/pipermail/jigsaw-dev/2011-October/001564.html
  • 57. Thanks to... • Wikipedia image courtesy of Wikipedia.org • Field of Flowers by Paul Podsiadlo and Elena Shevchenko, courtesy of Argonne National Laboratory

Editor's Notes

  1. \n
  2. \n
  3. \n
  4. \n
  5. \n
  6. \n
  7. \n
  8. \n
  9. \n
  10. \n
  11. \n
  12. \n
  13. \n
  14. \n
  15. \n
  16. \n
  17. \n
  18. \n
  19. \n
  20. \n
  21. \n
  22. \n
  23. \n
  24. \n
  25. \n
  26. \n
  27. \n
  28. \n
  29. \n
  30. \n
  31. \n
  32. \n
  33. \n
  34. \n
  35. \n
  36. \n
  37. \n
  38. \n
  39. \n
  40. \n
  41. \n
  42. \n
  43. \n
  44. \n
  45. \n
  46. \n
  47. \n
  48. \n
  49. \n
  50. \n
  51. \n
  52. \n
  53. \n
  54. \n
  55. \n