Your SlideShare is downloading. ×
0
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
OSGi: Don't let me be Misunderstood
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

OSGi: Don't let me be Misunderstood

386

Published on

Published in: Technology, Business
1 Comment
1 Like
Statistics
Notes
  • Excellent presentation!
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
No Downloads
Views
Total Views
386
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
0
Comments
1
Likes
1
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  1. Don’t let mebe misunderstoodMikaël Barbero6 June 2013OSGiNOT SURE IF ACCIDENTALLYCOMPLEXOR JUST ESSENTIALLY COMPLICATED
  2. Geek and Poke cartoon, 27 July 2011: Graph Theory for Geeks (CC-BY-ND)Original site: http://geekandpoke.typepad.com/geekandpoke/2011/07/graph-theory-for-geeks.html
  3. Culprit ?
  4. java -cp "Test.jar;lib/*" my.package.MainClass
  5. ExecutionEnvironmentFactory/Listenerpatterns are keyto modularityClasses areidentified by aunique nameJava visibility aresufficientboundariesModule identify==Module artifactPermGen ispermanent
  6. W R O N G !W R O N G !W R O N G !W R O N G !
  7. minimizing changes need to support theevolution of itself and its dependenciesModularity
  8. ExecutionEnvironmentClasses areidentified by aunique nameJava visibilitycreatessufficientboundariesMix up moduleidentify andmodule artifactPermGen ispermanentFactory/Listenerpatterns are keyto modularity
  9. CDLC/MIDPJ2SE 1.3, 1.4,5, 6, 7...CDC/FPOSGIMin.
  10. CDLC/MIDPJ2SE 1.3, 1.4,5, 6, 7...CDC/FPOSGIMin.MANIFEST.MFBundle-RequiredExecutionEnvironment: J2SE-1.6
  11. OS + HardwareEEModulesLifecycleServiceSecuritryApplications(bundles)
  12. ExecutionEnvironmentClasses areidentified by aunique nameJava visibilitycreatessufficientboundariesMix up moduleidentity andmodule artifactPermGen ispermanentFactory/Listenerpatterns are keyto modularity
  13. guava-14.0.1.jar15-Mar-20132.1 M69e12f4c6aeac392555f1ea86fab82b5e5e31ad4<groupId>com.google.guava</groupId><artifactId>guava</artifactId><version>14.0.1</version>Bundle-Vendor: Google, IncBundle-Name: com.google.guavaBundle-Version: 11.0.2.v201303041551
  14. <dependency>    <groupId>com.google.guava</groupId>    <artifactId>guava</artifactId>    <version>14.0.1</version></dependency>Require-Bundle: com.google.guava;bundle-version="11.0.2"
  15. OS + HardwareEEModulesLifecycleServiceSecuritryApplications(bundles)
  16. ExecutionEnvironmentClasses areidentified by aunique nameJava visibilitycreatessufficientboundariesMix up moduleidentify andmodule artifactPermGen ispermanentFactory/Listenerpatterns are keyto modularity
  17. Good fences make good neighbors
  18. com.acme.myApp-1.2.jarpackagecom.acme.corepackagecom.acme.core.implorg.logging.fmk-1.0.1.jarpackageorg.logging.fmk.implpackageorg.logging.fmk
  19. com.acme.myApp-1.2.jarorg.logging.fmk-1.0.1.jarpackagecom.acme.corepackagecom.acme.core.implpackageorg.logging.fmk.implpackageorg.logging.fmk
  20. com.acme.myApp-1.2.jarorg.logging.fmk-1.0.1.jarpackagecom.acme.corepackagecom.acme.core.implpackageorg.logging.fmk.implpackageorg.logging.fmk
  21. com.acme.myApp-1.2.jarorg.logging.fmk-1.0.1.jarpackagecom.acme.corepackagecom.acme.core.implpackageorg.logging.fmk.implpackageorg.logging.fmk
  22. Bundle com.acme.myApp; version=1.2Bundle org.logging.fmk; version=1.0.1Xpackagecom.acme.corepackagecom.acme.core.implpackageorg.logging.fmk.implpackageorg.logging.fmk
  23. Bundle com.acme.myApp; version=1.2Bundle org.logging.fmk; version=1.0.1packagecom.acme.corepackagecom.acme.core.implpackageorg.logging.fmk.implpackageorg.logging.fmk
  24. Bundle com.acme.myApp; version=1.2Bundle org.logging.fmk; version=1.0.1packagecom.acme.corepackagecom.acme.core.implpackageorg.logging.fmk.implpackageorg.logging.fmk
  25. Export-package: com.acme.core
  26. Export-package: com.acme.core;version="1.0.2"
  27. SemanticVersionsmajor.minor.micro.qualifier• major: different major versions are completely incompatible• minor: same major and different minor versions are compatible forconsumer only (callers of the API)• micro: used to signal bufixes with no backward incompatibility issues• qualifier: build identity
  28. OS + HardwareEEModulesLifecycleServiceSecuritryApplications(bundles)
  29. ExecutionEnvironmentClasses areidentified by aunique nameJava visibilitycreatessufficientboundariesMix up moduleidentify andmodule artifactPermGen ispermanentFactory/Listenerpatterns are keyto modularity
  30. My KillerApplicationLoggingFramework
  31. My KillerApplicationLoggingFrameworkXXX Framework
  32. My KillerApplicationLoggingFramework v1XXX FrameworkLoggingFramework v2
  33. My Killer Application
  34. JavaVirtual MachineApplicationExtensionFoundation BasicUIConvenienceBorrowed from Peter Kriens presentation: http://www.slideshare.net/pkriens/osgi-and-java-modularity-1642537
  35. Borrowed from Peter Kriens presentation: http://www.slideshare.net/pkriens/osgi-and-java-modularity-1642537
  36. ClassNotFoundExceptionBorrowed from Peter Kriens presentation: http://www.slideshare.net/pkriens/osgi-and-java-modularity-1642537
  37. Class Object Identity==Qualified Class Name + ClassLoader Object
  38. Bundle com.acme.myApp; version=1.2Bundle org.logging.fmk; version=1.0.1packagecom.acme.core;v=1.0packagecom.acme.core.implpackageorg.logging.fmk.implpackageorg.logging.fmk;v=1.2
  39. Bundle com.acme.myApp; version=1.2Bundle org.logging.fmk; version=1.0.1Xpackagecom.acme.core.implpackageorg.logging.fmk.implpackagecom.acme.core;v=1.0packageorg.logging.fmk;v=1.2
  40. Bundle com.acme.myApp; version=1.2Bundle org.logging.fmk; version=1.0.1packagecom.acme.core.implpackageorg.logging.fmk.implpackageorg.logging.fmkpackagecom.acme.core;v=1.0packageorg.logging.fmk;v=1.2
  41. Import-package: com.acme.core;version="[1.0.2, 1.1.0)"Consumer Provider[X.Y.Z.q, X+1.0.0) [X.Y.Z, X.Y+1.0)
  42. Bundle com.acme.myApp; version=1.2Bundle org.logging.fmk; version=1.0.1packagecom.acme.core.implpackageorg.logging.fmk.implpackageorg.logging.fmkpackagecom.acme.core;v=1.0packageorg.logging.fmk;v=1.2
  43. Bundle com.acme.myApp; version=1.2packagecom.acme.core.implpackagecom.acme.core;v=1.0Bundle org.logging.fmk; version=1.0.1packageorg.logging.fmk.implpackageorg.logging.fmk;v=1.2Bundle org.logging.fmk; version=2.3.0packageorg.logging.fmk.implpackageorg.logging.fmk;v=2.2Bundl exxx.fmk; version=1.2packagexxxpackageorg.logging.fmk;v=[2.2,3)packagexxx.exported;v=1.0packageorg.logging.fmk;v=[1.2,2.0)packagexxx.exported
  44. OS + HardwareEEModulesLifecycleServiceSecuritryApplications(bundles)
  45. ExecutionEnvironmentClasses areidentified by aunique nameJava visibilitycreatessufficientboundariesMix up moduleidentify andmodule artifactPermGen ispermanentFactory/Listenerpatterns are keyto modularity
  46. Bundle-Activator: com.acme.core.ActivatorBundle-ActivationPolicy: lazy
  47. public class Activator implements BundleActivator {public void start(BundleContext bc) {...}public void stop(BundleContext bc) {...}}
  48. OS + HardwareEEModulesLifecycleServiceSecuritryApplications(bundles)
  49. ExecutionEnvironmentClasses areidentified by aunique nameJava visibilitycreatessufficientboundariesMix up moduleidentify andmodule artifactPermGen ispermanentFactory/Listenerpatterns arekeys tomodularity
  50. ConsumerClassInterfaceProviderClass
  51. ConsumerClassInterfaceProviderClassuses implFactory PatternFactory ???
  52. ConsumerClassInterfaceProviderClassimpl usesListener PatternProviderInterfaceimpl
  53. ConsumerClassInterfaceProviderClassDependency injectionDI
  54. ConsumerClassInterfaceProviderClassμServicesμServices
  55. ConsumerClassProviderClassμServicesget register
  56. Declaring and getting servicesProgrammatically DeclarativelyService RegistryServiceTrackerDecl. ServicesBlueprint
  57. OS + HardwareEEModulesLifecycleServiceSecuritryApplications(bundles)
  58. OS + HardwareEEModulesLifecycleServiceSecuritryApplications(bundles)
  59. Minimizing changes need to support theevolution of itself and its dependenciesModularity
  60. High cohesion Low coupling EncapsulationModularity
  61. PDE
  62. You want to bean achiever?
  63. Give Feedback1} Sign in www.eclipsecon.org2} Select Session Evaluate3} Vote +1, 0 or -1ervisevichttp://www.flickr.com/photos/23979265@N07/4745520501/
  64. Mikaël Barberomikael.barbero@obeo.fr+Mikaël Barbero@mikbarberoObeohttp://www.obeo.fr(cc) TheAlieness GiselaGiardino²³ http://www.flickr.com/photos/36613169@N00/304120801/
  65. Q&A(cc) InstantVantage http://www.flickr.com/photos/44312356@N04/6023508805

×