• Like
  • Save
AS7/OSGi One Day Talk 2012
Upcoming SlideShare
Loading in...5
×
 

AS7/OSGi One Day Talk 2012

on

  • 984 views

 

Statistics

Views

Total Views
984
Views on SlideShare
984
Embed Views
0

Actions

Likes
1
Downloads
0
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via as OpenOffice

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment
  • Welcome to the wonderful world of OSGi!

AS7/OSGi One Day Talk 2012 AS7/OSGi One Day Talk 2012 Presentation Transcript

  • JBoss AS7 OSGi Thomas Diesler thomas.diesler@jboss.com 1
  • Agenda• OSGi Core• Enterprise OSGi• OSGi in AS7
  • OSGi Core: Modularity• OSGi modules are called Bundles• Computed classloader delegation graph• Bundles can be added, removed & updated dynamically JRE JRE• Side-by-side versioning• Private truly private Lib A Lib A Lib B Lib B Lib A Lib A• No more Jar Hell• OSGi Bundle can be a Module A Module B Module A Module B plain Jar at the same time
  • OSGi Core: Services• “SOA inside the JVM”• Services looked up by type and/or custom filter – “I want a service that implements org.acme.Payment where location=US” – One or many• Dynamic! Services can be updated without taking down the consumers – OSGi Service Consumers react to dynamism
  • The Dawning of Life Attention on Modules Appreciation of module independence Concern about module life-cycle and governance …but the problem already existed!5 © 2011 IBM Corporation
  • Cost vs ComplexityCost Big ball of mud Traditional Many small & focused modules Modular Complexity Modularity highly improves * maintainability
  • OSGi Bundles vs. JBoss Modules• OSGi is a standard • Modules not portable• Uses a complex resolver • Uses explicit wiring• Wiring based on rich • Wiring based on module metadata. Package version name. Multiple “slots” are just one criteria supported• Many compendium • Exist in the context of AS7 specifications and other 3rd • Very fast resolution party bundles• Attachable Fragments• Sensitive to execution env
  • OSGi Service vs. MSC Services• Keyed by Interface they • Keyed by unique service implement name• LDAP filter supported • No filtering, name only• Lifecycle tied to owner • Lifecycle tied to owner bundle or explicit API owner or explicit API• Service dependency and • Service dependency and injection via DS, Blueprint injection by MSC API• ServiceListener supported • ServiceListener supported• ServiceFactory supported • Instance per service name• ConfigurationAdmin • ConfigAdmin in AS7
  • R5 Enterprise OSGi• Mapping of a number of EE specs – Webapp – JPA – JTA – JNDI – JDBC – JMX• Remote Services• Resolver• Repository• Subsystems• Blueprint
  • Enterprise OSGi - Future• RFC 146 JCA• RFP 133 Cloud Computing• RFP 146 - CDI Integration• RFP 152 - EJB Integration
  • OSGi Core in AS7• AS7 is a fully compliant OSGi 4.2 Core Framework – TCK tests pass 100%• Just deploy your OSGi Bundles – Through the standard AS7 deployment channels
  • OSGi Core Implementation• Implemented from scratch on top of jboss- modules and jboss-msc• For the OSGi resolver we use the one from Apache Felix – Resolver computes the bundle classloader wirings – Based on OSGi Metadata • e.g. Import-Package / Export-Package
  • AS7 OSGi Integration• Use OSGi services in EE components• Use EE components in OSGi services• JBoss modules/msc as integration layer• Every bundle is a module. Not every module is bundle• Support for WebApp, EJB, CDI, JAX-RS, JAX-WS, JPA as OSGi deployments• Support for Bundles in EAR files
  • Enterprise OSGi in AS7• AS7 out of the Box: – OSGi Core, Compendium APIs – Enterprise OSGi JMX, JNDI, JTA, WebApp, Blueprint – OSGi ConfigAdmin, EventAdmin, HttpServer – Management through WebConsole
  • OSGi in AS7 – Next Steps• OSGi R5 specification• OSGi Enterprise Applications• Provisioning service
  • Demo• Show how an EJB3 can access an OSGi payment service• Show how a Servlet can access an OSGi payment service
  • Q&A
  • Links• AS7 home page http://www.jboss.org/jbossas• AS7 OSGi home page http://www.jboss.org/jbossas/osgi• OSGi Specifications http://www.osgi.org/Download/Release4V42• JBoss OSGi Diary http://jbossosgi.blogspot.com
  • Acknowledgements• Cost vs Complexity, Hal Hildebrand http://bit.ly/i42uBo• Dawning of Life, Graham Charters, IBM