• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Tim Moores
  • Carey Brown
  • Mikalai Zaikin
Bartenders:
  • Lou Hamers
  • Piet Souris
  • Frits Walraven

Spring Dynamic Modules

 
Ranch Hand
Posts: 527
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

Does Spring Dynamic Modules work for OSGi platform only? I know OSGi talks about loosely coupled component and can be added/removed dynamically in running system. How different "Spring Dynamic Modules" from traditional Spring's dependency injection.

Thanks.
 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
DI isn't dynamic.
 
author
Posts: 15
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Anil,

Yes, Spring DM targets OSGi platform only. To simplify, the aim of Spring DM is to leverage Spring facilities to develop OSGi components and make them interact through the OSGi service registry... For that, a dedicated Spring container is embedded in each Spring DM powered component and dependency injection can now be done between components. You are now able to develop same Spring (enterprise or not) applications within an OSGi container ;-)

Otherwise, as David said, the DI is static with Spring only but with Spring DM and OSGi, this behaviour is quite different since you can now update at runtime dependency graphs based on OSGi services. If you inject a service, you can update the dependency at runtime and it's automatically taken into account (internally basing on proxies). Spring DM natively integrates this dynamic behaviour of OSGi...

Hope it answers your question!
Thierry
 
Do not meddle in the affairs of dragons - for you are crunchy and good with ketchup. Crunchy tiny ad:
We need your help - Coderanch server fundraiser
https://coderanch.com/wiki/782867/Coderanch-server-fundraiser
reply
    Bookmark Topic Watch Topic
  • New Topic