Announcement Announcement Module

Spring Dynamic Modules forum decommissioned in favor of Eclipse Gemini Blueprint

With the official first release of Eclipse Gemini Blueprint shipped, the migration of the Spring Dynamic Modules code base to the Eclipse Foundation, as part of the Gemini project, has been completed.

As such, this forum has been decommissioned in favour of the Eclipse Gemini forums.
See more
See less
Question on Changing the applicationEventMulticaster Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Question on Changing the applicationEventMulticaster

    I have the need to use a custom event multicaster in my application. I configured a new bean in the spring/extender application context.xml called applicationEventMulticaster that uses my custom class. This bean is only ever sent one event - when the spring extender bundle starts. My understanding is that it should be sent events whenever any spring powered bundle is started. Can someone explain why events for other bundles are not sent to this multicaster?

  • #2
    did you use a fragment attached to the extender bundle to override the default event multicaster?

    If you did, I think you followed correctly what the reference documentation states, but unfortunately the reference documentation seems to be wrong. The bean to declare must be called "osgiApplicationEventMulticaster" and of type "org.springframework.osgi.context.event.OsgiBundle ApplicationContextEventMulticaster".

    By following the reference documentation, you override Spring's event multicaster, whose scope is limited to the owning application contex whereas the scope of Spring DM's event system is extended to all Spring-powered bundles. That's why you receive a event only once: when the application context of the extender starts.

    I'm not sure of all of this: it's based on the analysis of the source code. You should try my instructions before opening a JIRA to correct the documentation.


    • #3
      The documentation is indeed incorrect. Raised