Announcement Announcement Module
Collapse
No announcement yet.
Pluggable Spring-based Components Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Pluggable Spring-based Components

    I'm building a plugg-able architecture comprised of a runtime 'platform' that provides the majority of services, and a plugin API that supports the addition of plugins post-deployment. I need the plugins to be able to reference beans defined in the 'platform'.

    My plan was to have the 'platform' discover all the Spring config files defined by plugins at startup and build a single ApplicationContext comprised of all the beans defined by all plugins, specifying the ApplicationContext of the 'platform' as its parent.

    Does this make sense? Is there a better/easier way? Does anyone have experience building pluggable architectures using Spring?

    Thanks.
    -Mitch Christensen

  • #2
    Although I don't think its been released yet, have you looked into Spring OSGI?

    Comment


    • #3
      I think ultimately this is exactly what I was looking for. I was introduced to OSGI back when I was writing an Eclipse RCP application. It's a very nice framework, but a bit of a heavywieght.

      Unfortunately I've got schedule constraints that force me to work with what I have.

      I guess my question is whether the existance of Spring OSGI implies that what I am trying to do is going to be difficult or impossible?

      Comment


      • #4
        ...also, OSGI supports hot-deployment, which is less important to me. I'm fine with restarting my app to activate a new plugin.

        Comment


        • #5
          If all you want to do is load lots of context files then thats pretty simple. This thread a couple of days ago talked about the same thing. The other thing with yours is the location being dynamic. Resources do support wildcards though.

          http://forum.springframework.org/showthread.php?t=33648
          http://www.springframework.org/docs/...resource-paths

          Comment

          Working...
          X