SlideShare a Scribd company logo
1 of 19
Download to read offline
Rogue Bundles: Go to Jail

  Isolating bundles in OSGI 4.3 / eclipse
  equinox 3.7



                 Eclipseconeurope2011       1
Who we are
• Tobias Jenkner, edmPRO

• Matthias Pickel, Piterion GmbH

• Eclipse RCP Integration project at Daimler AG




                    Eclipseconeurope2011          2
Integrating existing osgi bundles

        …
     Plugin A1                 … Plugin B1                 …           …
       Plugin A2                   …Plugin B2
                           …
                                      Plugin B3
                                              …
       …
                      …
                         Integration
                           … …
                                   …         …
                                                           …       …
                                                                       …

 Plugin C Version 1.1.1 Sideeffects ?
                             …      …
                               …
                                                       …
                      …
  Plugin C Version 2.0.1                 …                             …

               …                             …
                                                               …
                           …
                               Eclipse Application



                                Eclipseconeurope2011                       3
Demo




       Eclipseconeurope2011   4
Integrating existing osgi bundles
    defaulthttpparams.a                             defaulthttpparams.b

    Provide:                                        Provide:
    DefaultHttpConn                                 DefaultHttpConn
    ectionFactory                                   ectionFactory
                                       ?
                             Conflicting
                            Requirements
        httpclient.a              &                     httpclient.b

    Require:                 capabilities           Require:
    http-connection-                                http-connection-
    timeout = 100                                   timeout = 5000

                     Integrated Eclipse Application A & B Application B
    Eclipse Application A                            Eclipse

                             Eclipseconeurope2011                         5
Conflicting capabilities             Conflicting requirements
 • Multiple instances of OSGI         • Different implementations
   services                             of an OSGI service
 • Multiple instances of              • Multiple instances of static
   Singleton-Bundles                    variables (e.g. for
 • Multiple exports of a                containing different
   package                              configuration data)

                                      • Incomplete versioning
                                        metadata


→ Write once ….         break in integration scenario ?
                          Eclipseconeurope2011                         6
Solutions ?
• Change the existing osgi bundles
  – Not always possible (source code not available)
  – Cost, time, ….


• Rogue bundles: Go to Jail!
  – Create isolated regions (jailcells) in our OSGI 4.3
    runtime



                        Eclipseconeurope2011              7
OSGI Runtime isolation
   defaulthttpparams.a                                 defaulthttpparams.b
   Provide:                                            Provide:
   DefaultHttpConn                                     DefaultHttpConn
   ectionFactory                                       ectionFactory

       httpclient.a                                        httpclient.b
   Require:                                            Require:
   http-connection-                                    http-connection-
   timeout = 100                                       timeout = 5000



                              Eclipse Framework
                               core components
                      Integrated Eclipse Application A & B

                                Eclipseconeurope2011                         8
Demo




       Eclipseconeurope2011   9
OSGI 4.3 Framework Hooks




            Eclipseconeurope2011   10
ResolverHook


        Create a new
        ResolverHook instance for
        every resolve process



          Decide if more than one
          instance of a singleton
          bundle may be installed




           Decide how bundles may
           be wired.



                     Eclipseconeurope2011   11
ResolverHook
    org.osgi.framework.hooks.resolver.ResolverHook


•     void filterSingletonCollisions(
         BundleCapability singleton, Collection<BundleCapability>
         collisionCandidates):
      Allow one instance of singleton-bundles to be installed in every Bundle-Jail-
      Cell.

•     void filterMatches(
         BundleRequirement requirement, Collection<BundleCapability>
         candidates):
      Do not allow to wire bundles between different Bundle-Jail-Cells.

•     void filterResolvable(Collection<BundleRevision> candidates);:
      not important for bundle jails

•     void end():
      lifecycle method not important for bundle jails



                                                  Eclipseconeurope2011                12
Find & Event Hooks
• BundleContext.getService… -> Service FindHook

• BundleContext.getBundles(…)-> Bundle FindHook

• ServiceEvents -> Service EventListenerHook

• BundleEvents -> Bundle EventHook




                     Eclipseconeurope2011         13
BundleJail implementation
Implementation of the Hook-Interfaces

                                                       Plugin A1                                          Plugin B1

How do the Hook                                        Provide X                                          Provide X



interfaces know which                                  Plugin A2
                                                       Require X
                                                                                                          Plugin B2
                                                                                                          Require X

bundle-jail-cell a bundle
belongs to?                                                                Eclipse Framework
                                                                            core components

                                                                   Integrated Eclipse Application A & B




→ Use the query part of the bundle install URL
→ Allows a bundle to be installed multiple times from the same location into
  different jail-cells
→ The install URL is available in the hooks

                                Eclipseconeurope2011                                                                  14
Open questions
P2 integration: Install bundles into jails

• Specify query part of the URL in Config.ini /
  bundles.info

• P2 installation: Specify BundleJailCell / region
  in P2-Metadata ?




                         Eclipseconeurope2011        15
Open questions
• Eclipse extension registry: mulitple singletons
  -> multiple instances of the same extensions?
  – Could be implemented with equinox transforms
    xslt
• Install location is shared between regions
• No PDE tooling support for custom URLs
• …


                    Eclipseconeurope2011            16
Look around: Equinox Regions
• Isolation Hooks implementations from the
  equinox team.
• Originally developed for eclipse virgo
• Directed Graph of bundle regions




                   Eclipseconeurope2011      17
Look around
• Google chrome: Separate process for every
  tab

-> Isolation through separate JVM instances ?
-> JSR 121: JVM Isolation API
  -> Not yet implemented in Oracle JVM



                   Eclipseconeurope2011         18
Thank you !
• Questions ?



• Democode: https://github.com/tobias-
  jenkner/org.eclipse.ece2011.roguebundles




                  Eclipseconeurope2011       19

More Related Content

What's hot

OSGi in 5 minutes
OSGi in 5 minutesOSGi in 5 minutes
OSGi in 5 minutesSerge Huber
 
Jax london 2011
Jax london 2011Jax london 2011
Jax london 2011njbartlett
 
Ekon 25 Python4Delphi_MX475
Ekon 25 Python4Delphi_MX475Ekon 25 Python4Delphi_MX475
Ekon 25 Python4Delphi_MX475Max Kleiner
 
EKON 25 Python4Delphi_mX4
EKON 25 Python4Delphi_mX4EKON 25 Python4Delphi_mX4
EKON 25 Python4Delphi_mX4Max Kleiner
 
Java 9 Modules: The Duke Yet Lives That OSGi Shall Depose
Java 9 Modules: The Duke Yet Lives That OSGi Shall DeposeJava 9 Modules: The Duke Yet Lives That OSGi Shall Depose
Java 9 Modules: The Duke Yet Lives That OSGi Shall DeposeNikita Lipsky
 
Apache Aries: A blueprint for developing with OSGi and JEE
Apache Aries: A blueprint for developing with OSGi and JEEApache Aries: A blueprint for developing with OSGi and JEE
Apache Aries: A blueprint for developing with OSGi and JEEmahrwald
 
What's Expected in Java 7
What's Expected in Java 7What's Expected in Java 7
What's Expected in Java 7Gal Marder
 
Hs P005 Reflective Dll Injection
Hs P005 Reflective Dll InjectionHs P005 Reflective Dll Injection
Hs P005 Reflective Dll InjectionKarlFrank99
 
Eclipse Code Recommenders @ cross-event Deutsche Telekom Developer Garden Tec...
Eclipse Code Recommenders @ cross-event Deutsche Telekom Developer Garden Tec...Eclipse Code Recommenders @ cross-event Deutsche Telekom Developer Garden Tec...
Eclipse Code Recommenders @ cross-event Deutsche Telekom Developer Garden Tec...Marcel Bruch
 
Apache DeltaSpike
Apache DeltaSpikeApache DeltaSpike
Apache DeltaSpikeos890
 
OpenWebBeans and DeltaSpike at ApacheCon
OpenWebBeans and DeltaSpike at ApacheConOpenWebBeans and DeltaSpike at ApacheCon
OpenWebBeans and DeltaSpike at ApacheConos890
 
The Web on OSGi: Here's How
The Web on OSGi: Here's HowThe Web on OSGi: Here's How
The Web on OSGi: Here's Howmrdon
 
Using the Android Native Development Kit (NDK)
Using the Android Native Development Kit (NDK)Using the Android Native Development Kit (NDK)
Using the Android Native Development Kit (NDK)Xavier Hallade
 
DWX 2013 Nuremberg
DWX 2013 NurembergDWX 2013 Nuremberg
DWX 2013 NurembergMarcel Bruch
 
Eclipse Code Recommenders @ MAJUG 2011
Eclipse Code Recommenders @ MAJUG 2011Eclipse Code Recommenders @ MAJUG 2011
Eclipse Code Recommenders @ MAJUG 2011Marcel Bruch
 
Zero-Copy Event-Driven Servers with Netty
Zero-Copy Event-Driven Servers with NettyZero-Copy Event-Driven Servers with Netty
Zero-Copy Event-Driven Servers with NettyDaniel Bimschas
 

What's hot (20)

OSGi in 5 minutes
OSGi in 5 minutesOSGi in 5 minutes
OSGi in 5 minutes
 
Jax london 2011
Jax london 2011Jax london 2011
Jax london 2011
 
Ekon 25 Python4Delphi_MX475
Ekon 25 Python4Delphi_MX475Ekon 25 Python4Delphi_MX475
Ekon 25 Python4Delphi_MX475
 
EKON 25 Python4Delphi_mX4
EKON 25 Python4Delphi_mX4EKON 25 Python4Delphi_mX4
EKON 25 Python4Delphi_mX4
 
Java 9 Modules: The Duke Yet Lives That OSGi Shall Depose
Java 9 Modules: The Duke Yet Lives That OSGi Shall DeposeJava 9 Modules: The Duke Yet Lives That OSGi Shall Depose
Java 9 Modules: The Duke Yet Lives That OSGi Shall Depose
 
Intro To OSGi
Intro To OSGiIntro To OSGi
Intro To OSGi
 
Apache Aries: A blueprint for developing with OSGi and JEE
Apache Aries: A blueprint for developing with OSGi and JEEApache Aries: A blueprint for developing with OSGi and JEE
Apache Aries: A blueprint for developing with OSGi and JEE
 
What's Expected in Java 7
What's Expected in Java 7What's Expected in Java 7
What's Expected in Java 7
 
Hs P005 Reflective Dll Injection
Hs P005 Reflective Dll InjectionHs P005 Reflective Dll Injection
Hs P005 Reflective Dll Injection
 
Eclipse Code Recommenders @ cross-event Deutsche Telekom Developer Garden Tec...
Eclipse Code Recommenders @ cross-event Deutsche Telekom Developer Garden Tec...Eclipse Code Recommenders @ cross-event Deutsche Telekom Developer Garden Tec...
Eclipse Code Recommenders @ cross-event Deutsche Telekom Developer Garden Tec...
 
Apache DeltaSpike
Apache DeltaSpikeApache DeltaSpike
Apache DeltaSpike
 
OpenWebBeans and DeltaSpike at ApacheCon
OpenWebBeans and DeltaSpike at ApacheConOpenWebBeans and DeltaSpike at ApacheCon
OpenWebBeans and DeltaSpike at ApacheCon
 
The Web on OSGi: Here's How
The Web on OSGi: Here's HowThe Web on OSGi: Here's How
The Web on OSGi: Here's How
 
OSGi overview
OSGi overviewOSGi overview
OSGi overview
 
Apache DeltaSpike the CDI toolbox
Apache DeltaSpike the CDI toolboxApache DeltaSpike the CDI toolbox
Apache DeltaSpike the CDI toolbox
 
Using the Android Native Development Kit (NDK)
Using the Android Native Development Kit (NDK)Using the Android Native Development Kit (NDK)
Using the Android Native Development Kit (NDK)
 
DWX 2013 Nuremberg
DWX 2013 NurembergDWX 2013 Nuremberg
DWX 2013 Nuremberg
 
Eclipse Code Recommenders @ MAJUG 2011
Eclipse Code Recommenders @ MAJUG 2011Eclipse Code Recommenders @ MAJUG 2011
Eclipse Code Recommenders @ MAJUG 2011
 
Zero-Copy Event-Driven Servers with Netty
Zero-Copy Event-Driven Servers with NettyZero-Copy Event-Driven Servers with Netty
Zero-Copy Event-Driven Servers with Netty
 
C# tutorial
C# tutorialC# tutorial
C# tutorial
 

Viewers also liked

Alameda County 2011-12 Proposed Budget Overview
Alameda County 2011-12 Proposed Budget OverviewAlameda County 2011-12 Proposed Budget Overview
Alameda County 2011-12 Proposed Budget OverviewKeith Carson
 
Alameda County Budget Workgroup Forum (February 2011)
Alameda County Budget Workgroup Forum (February 2011)Alameda County Budget Workgroup Forum (February 2011)
Alameda County Budget Workgroup Forum (February 2011)Keith Carson
 
Alameda County Budget Workgroup May 16, 2011
Alameda County Budget Workgroup May 16, 2011Alameda County Budget Workgroup May 16, 2011
Alameda County Budget Workgroup May 16, 2011Keith Carson
 
Everything you need to know about pay per click advertising but were afraid t...
Everything you need to know about pay per click advertising but were afraid t...Everything you need to know about pay per click advertising but were afraid t...
Everything you need to know about pay per click advertising but were afraid t...e-CBD
 

Viewers also liked (7)

Alameda County 2011-12 Proposed Budget Overview
Alameda County 2011-12 Proposed Budget OverviewAlameda County 2011-12 Proposed Budget Overview
Alameda County 2011-12 Proposed Budget Overview
 
Alameda County Budget Workgroup Forum (February 2011)
Alameda County Budget Workgroup Forum (February 2011)Alameda County Budget Workgroup Forum (February 2011)
Alameda County Budget Workgroup Forum (February 2011)
 
F inc 34_bugaboo
F inc 34_bugabooF inc 34_bugaboo
F inc 34_bugaboo
 
Alameda County Budget Workgroup May 16, 2011
Alameda County Budget Workgroup May 16, 2011Alameda County Budget Workgroup May 16, 2011
Alameda County Budget Workgroup May 16, 2011
 
Ingles Cei Campana 2011
Ingles Cei Campana 2011Ingles Cei Campana 2011
Ingles Cei Campana 2011
 
Runtime surgery
Runtime surgeryRuntime surgery
Runtime surgery
 
Everything you need to know about pay per click advertising but were afraid t...
Everything you need to know about pay per click advertising but were afraid t...Everything you need to know about pay per click advertising but were afraid t...
Everything you need to know about pay per click advertising but were afraid t...
 

Similar to Rogue bundles

Eclipse RCP outside of Eclipse IDE - Gradle to the rescue!
Eclipse RCP outside of Eclipse IDE - Gradle to the rescue!Eclipse RCP outside of Eclipse IDE - Gradle to the rescue!
Eclipse RCP outside of Eclipse IDE - Gradle to the rescue!Michał Ćmil
 
Enterprise OSGi at eBay
Enterprise OSGi at eBayEnterprise OSGi at eBay
Enterprise OSGi at eBayTony Ng
 
Comparing Popular Eclipse Development Projects
Comparing Popular Eclipse Development ProjectsComparing Popular Eclipse Development Projects
Comparing Popular Eclipse Development ProjectsBlack Duck by Synopsys
 
Eclipse IDE, 2019.09, Java Development
Eclipse IDE, 2019.09, Java Development Eclipse IDE, 2019.09, Java Development
Eclipse IDE, 2019.09, Java Development Pei-Hsuan Hsieh
 
Dockerize it: stop living in the past and embrace the future by Alex Nadalin
 Dockerize it: stop living in the past and embrace the future by Alex Nadalin Dockerize it: stop living in the past and embrace the future by Alex Nadalin
Dockerize it: stop living in the past and embrace the future by Alex NadalinCodemotion Dubai
 
Dockerize it! @ Codemotion 2016 in Rome
Dockerize it! @ Codemotion 2016 in RomeDockerize it! @ Codemotion 2016 in Rome
Dockerize it! @ Codemotion 2016 in RomeAlessandro Nadalin
 
Dockerize it: stop living in the past and embrace the future
Dockerize it: stop living in the past and embrace the futureDockerize it: stop living in the past and embrace the future
Dockerize it: stop living in the past and embrace the futureCodemotion
 
EclipseCon 2016 - OCCIware : one Cloud API to rule them all
EclipseCon 2016 - OCCIware : one Cloud API to rule them allEclipseCon 2016 - OCCIware : one Cloud API to rule them all
EclipseCon 2016 - OCCIware : one Cloud API to rule them allMarc Dutoo
 
OCCIware Project at EclipseCon France 2016, by Marc Dutoo, Open Wide
OCCIware Project at EclipseCon France 2016, by Marc Dutoo, Open WideOCCIware Project at EclipseCon France 2016, by Marc Dutoo, Open Wide
OCCIware Project at EclipseCon France 2016, by Marc Dutoo, Open WideOCCIware
 
OpenDaylight Developers Experience 1.5: Eclipse Setup, HOT reload, future plans
OpenDaylight Developers Experience 1.5: Eclipse Setup, HOT reload, future plansOpenDaylight Developers Experience 1.5: Eclipse Setup, HOT reload, future plans
OpenDaylight Developers Experience 1.5: Eclipse Setup, HOT reload, future plansMichael Vorburger
 
Kubernetes 101 - A Cluster Operating System
Kubernetes 101 - A Cluster Operating SystemKubernetes 101 - A Cluster Operating System
Kubernetes 101 - A Cluster Operating Systemmikaelbarbero
 
Experiences from porting a commercial RCP application to Eclipse 4.x
Experiences from porting a commercial RCP application to Eclipse 4.xExperiences from porting a commercial RCP application to Eclipse 4.x
Experiences from porting a commercial RCP application to Eclipse 4.xFredrik Attebrant
 
Nice performance using Sf2 cache wrapping Sf1 application
Nice performance using Sf2 cache wrapping Sf1 applicationNice performance using Sf2 cache wrapping Sf1 application
Nice performance using Sf2 cache wrapping Sf1 applicationMarc Weistroff
 
zenject extenject-intro
zenject extenject-introzenject extenject-intro
zenject extenject-introRiver Wang
 
Import golang; struct microservice
Import golang; struct microserviceImport golang; struct microservice
Import golang; struct microserviceGiulio De Donato
 
Eclipse 2011 Hot Topics
Eclipse 2011 Hot TopicsEclipse 2011 Hot Topics
Eclipse 2011 Hot TopicsLars Vogel
 
Red Hat Forum Benelux 2015
Red Hat Forum Benelux 2015Red Hat Forum Benelux 2015
Red Hat Forum Benelux 2015Microsoft
 
OSGi & Java EE in GlassFish - Best of both worlds
OSGi & Java EE in GlassFish - Best of both worldsOSGi & Java EE in GlassFish - Best of both worlds
OSGi & Java EE in GlassFish - Best of both worldsArun Gupta
 

Similar to Rogue bundles (20)

Eclipse RCP outside of Eclipse IDE - Gradle to the rescue!
Eclipse RCP outside of Eclipse IDE - Gradle to the rescue!Eclipse RCP outside of Eclipse IDE - Gradle to the rescue!
Eclipse RCP outside of Eclipse IDE - Gradle to the rescue!
 
Enterprise OSGi at eBay
Enterprise OSGi at eBayEnterprise OSGi at eBay
Enterprise OSGi at eBay
 
Comparing Popular Eclipse Development Projects
Comparing Popular Eclipse Development ProjectsComparing Popular Eclipse Development Projects
Comparing Popular Eclipse Development Projects
 
Eclipse IDE, 2019.09, Java Development
Eclipse IDE, 2019.09, Java Development Eclipse IDE, 2019.09, Java Development
Eclipse IDE, 2019.09, Java Development
 
Dockerize it: stop living in the past and embrace the future by Alex Nadalin
 Dockerize it: stop living in the past and embrace the future by Alex Nadalin Dockerize it: stop living in the past and embrace the future by Alex Nadalin
Dockerize it: stop living in the past and embrace the future by Alex Nadalin
 
Dockerize it! @ Codemotion 2016 in Rome
Dockerize it! @ Codemotion 2016 in RomeDockerize it! @ Codemotion 2016 in Rome
Dockerize it! @ Codemotion 2016 in Rome
 
Dockerize it: stop living in the past and embrace the future
Dockerize it: stop living in the past and embrace the futureDockerize it: stop living in the past and embrace the future
Dockerize it: stop living in the past and embrace the future
 
EclipseCon 2016 - OCCIware : one Cloud API to rule them all
EclipseCon 2016 - OCCIware : one Cloud API to rule them allEclipseCon 2016 - OCCIware : one Cloud API to rule them all
EclipseCon 2016 - OCCIware : one Cloud API to rule them all
 
OCCIware Project at EclipseCon France 2016, by Marc Dutoo, Open Wide
OCCIware Project at EclipseCon France 2016, by Marc Dutoo, Open WideOCCIware Project at EclipseCon France 2016, by Marc Dutoo, Open Wide
OCCIware Project at EclipseCon France 2016, by Marc Dutoo, Open Wide
 
OpenDaylight Developers Experience 1.5: Eclipse Setup, HOT reload, future plans
OpenDaylight Developers Experience 1.5: Eclipse Setup, HOT reload, future plansOpenDaylight Developers Experience 1.5: Eclipse Setup, HOT reload, future plans
OpenDaylight Developers Experience 1.5: Eclipse Setup, HOT reload, future plans
 
Mcollective introduction
Mcollective introductionMcollective introduction
Mcollective introduction
 
Kubernetes 101 - A Cluster Operating System
Kubernetes 101 - A Cluster Operating SystemKubernetes 101 - A Cluster Operating System
Kubernetes 101 - A Cluster Operating System
 
Experiences from porting a commercial RCP application to Eclipse 4.x
Experiences from porting a commercial RCP application to Eclipse 4.xExperiences from porting a commercial RCP application to Eclipse 4.x
Experiences from porting a commercial RCP application to Eclipse 4.x
 
Nice performance using Sf2 cache wrapping Sf1 application
Nice performance using Sf2 cache wrapping Sf1 applicationNice performance using Sf2 cache wrapping Sf1 application
Nice performance using Sf2 cache wrapping Sf1 application
 
Acceleo Code Generation
Acceleo Code GenerationAcceleo Code Generation
Acceleo Code Generation
 
zenject extenject-intro
zenject extenject-introzenject extenject-intro
zenject extenject-intro
 
Import golang; struct microservice
Import golang; struct microserviceImport golang; struct microservice
Import golang; struct microservice
 
Eclipse 2011 Hot Topics
Eclipse 2011 Hot TopicsEclipse 2011 Hot Topics
Eclipse 2011 Hot Topics
 
Red Hat Forum Benelux 2015
Red Hat Forum Benelux 2015Red Hat Forum Benelux 2015
Red Hat Forum Benelux 2015
 
OSGi & Java EE in GlassFish - Best of both worlds
OSGi & Java EE in GlassFish - Best of both worldsOSGi & Java EE in GlassFish - Best of both worlds
OSGi & Java EE in GlassFish - Best of both worlds
 

Recently uploaded

Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
Bluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfBluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfngoud9212
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr LapshynFwdays
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraDeakin University
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Neo4j
 
Unlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsUnlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsPrecisely
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxnull - The Open Security Community
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptxLBM Solutions
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Science&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfScience&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfjimielynbastida
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 

Recently uploaded (20)

Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Pigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping ElbowsPigging Solutions Piggable Sweeping Elbows
Pigging Solutions Piggable Sweeping Elbows
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
Bluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdfBluetooth Controlled Car with Arduino.pdf
Bluetooth Controlled Car with Arduino.pdf
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
 
Artificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning eraArtificial intelligence in the post-deep learning era
Artificial intelligence in the post-deep learning era
 
Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024Build your next Gen AI Breakthrough - April 2024
Build your next Gen AI Breakthrough - April 2024
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Unlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power SystemsUnlocking the Potential of the Cloud for IBM Power Systems
Unlocking the Potential of the Cloud for IBM Power Systems
 
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptxMaking_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
Making_way_through_DLL_hollowing_inspite_of_CFG_by_Debjeet Banerjee.pptx
 
Key Features Of Token Development (1).pptx
Key  Features Of Token  Development (1).pptxKey  Features Of Token  Development (1).pptx
Key Features Of Token Development (1).pptx
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Science&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfScience&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdf
 
The transition to renewables in India.pdf
The transition to renewables in India.pdfThe transition to renewables in India.pdf
The transition to renewables in India.pdf
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 

Rogue bundles

  • 1. Rogue Bundles: Go to Jail Isolating bundles in OSGI 4.3 / eclipse equinox 3.7 Eclipseconeurope2011 1
  • 2. Who we are • Tobias Jenkner, edmPRO • Matthias Pickel, Piterion GmbH • Eclipse RCP Integration project at Daimler AG Eclipseconeurope2011 2
  • 3. Integrating existing osgi bundles … Plugin A1 … Plugin B1 … … Plugin A2 …Plugin B2 … Plugin B3 … … … Integration … … … … … … … Plugin C Version 1.1.1 Sideeffects ? … … … … … Plugin C Version 2.0.1 … … … … … … Eclipse Application Eclipseconeurope2011 3
  • 4. Demo Eclipseconeurope2011 4
  • 5. Integrating existing osgi bundles defaulthttpparams.a defaulthttpparams.b Provide: Provide: DefaultHttpConn DefaultHttpConn ectionFactory ectionFactory ? Conflicting Requirements httpclient.a & httpclient.b Require: capabilities Require: http-connection- http-connection- timeout = 100 timeout = 5000 Integrated Eclipse Application A & B Application B Eclipse Application A Eclipse Eclipseconeurope2011 5
  • 6. Conflicting capabilities Conflicting requirements • Multiple instances of OSGI • Different implementations services of an OSGI service • Multiple instances of • Multiple instances of static Singleton-Bundles variables (e.g. for • Multiple exports of a containing different package configuration data) • Incomplete versioning metadata → Write once …. break in integration scenario ? Eclipseconeurope2011 6
  • 7. Solutions ? • Change the existing osgi bundles – Not always possible (source code not available) – Cost, time, …. • Rogue bundles: Go to Jail! – Create isolated regions (jailcells) in our OSGI 4.3 runtime Eclipseconeurope2011 7
  • 8. OSGI Runtime isolation defaulthttpparams.a defaulthttpparams.b Provide: Provide: DefaultHttpConn DefaultHttpConn ectionFactory ectionFactory httpclient.a httpclient.b Require: Require: http-connection- http-connection- timeout = 100 timeout = 5000 Eclipse Framework core components Integrated Eclipse Application A & B Eclipseconeurope2011 8
  • 9. Demo Eclipseconeurope2011 9
  • 10. OSGI 4.3 Framework Hooks Eclipseconeurope2011 10
  • 11. ResolverHook Create a new ResolverHook instance for every resolve process Decide if more than one instance of a singleton bundle may be installed Decide how bundles may be wired. Eclipseconeurope2011 11
  • 12. ResolverHook org.osgi.framework.hooks.resolver.ResolverHook • void filterSingletonCollisions( BundleCapability singleton, Collection<BundleCapability> collisionCandidates): Allow one instance of singleton-bundles to be installed in every Bundle-Jail- Cell. • void filterMatches( BundleRequirement requirement, Collection<BundleCapability> candidates): Do not allow to wire bundles between different Bundle-Jail-Cells. • void filterResolvable(Collection<BundleRevision> candidates);: not important for bundle jails • void end(): lifecycle method not important for bundle jails Eclipseconeurope2011 12
  • 13. Find & Event Hooks • BundleContext.getService… -> Service FindHook • BundleContext.getBundles(…)-> Bundle FindHook • ServiceEvents -> Service EventListenerHook • BundleEvents -> Bundle EventHook Eclipseconeurope2011 13
  • 14. BundleJail implementation Implementation of the Hook-Interfaces Plugin A1 Plugin B1 How do the Hook Provide X Provide X interfaces know which Plugin A2 Require X Plugin B2 Require X bundle-jail-cell a bundle belongs to? Eclipse Framework core components Integrated Eclipse Application A & B → Use the query part of the bundle install URL → Allows a bundle to be installed multiple times from the same location into different jail-cells → The install URL is available in the hooks Eclipseconeurope2011 14
  • 15. Open questions P2 integration: Install bundles into jails • Specify query part of the URL in Config.ini / bundles.info • P2 installation: Specify BundleJailCell / region in P2-Metadata ? Eclipseconeurope2011 15
  • 16. Open questions • Eclipse extension registry: mulitple singletons -> multiple instances of the same extensions? – Could be implemented with equinox transforms xslt • Install location is shared between regions • No PDE tooling support for custom URLs • … Eclipseconeurope2011 16
  • 17. Look around: Equinox Regions • Isolation Hooks implementations from the equinox team. • Originally developed for eclipse virgo • Directed Graph of bundle regions Eclipseconeurope2011 17
  • 18. Look around • Google chrome: Separate process for every tab -> Isolation through separate JVM instances ? -> JSR 121: JVM Isolation API -> Not yet implemented in Oracle JVM Eclipseconeurope2011 18
  • 19. Thank you ! • Questions ? • Democode: https://github.com/tobias- jenkner/org.eclipse.ece2011.roguebundles Eclipseconeurope2011 19