[OSGi][Event] Fire event between controllers

18 views
Skip to first unread message

Nicolas Delsaux

unread,
Nov 12, 2015, 7:59:49 AM11/12/15
to wisdom-...@googlegroups.com
Hi,
In my application, I have two controllers :
- one settings controller, which handles changes to configuration of one
data type
- one publishing controller, which mainly emits websocket events to
browsers registered on specific instances of that data type.

I would like my publishing controller to fire a particular event when
one configuration is changed.

As to now, i suppose this can be done using OSGi events, which are
implemented using iPOJO @Publishes and @Subscribes annotations, as
described here :
https://felix.apache.org/documentation/subprojects/apache-felix-ipojo/apache-felix-ipojo-userguide/describing-components/event-admin-handlers.html

However, when I try to create my publisher, i'm quite puzzled, because
there is no Publisher interface on my CLASSPATH.
Is there any dependency I miss ?

Thanks

--
Nicolas Delsaux

clement escoffier

unread,
Dec 10, 2015, 2:24:14 AM12/10/15
to wisdom-discuss, nicolas...@gmx.fr
Hello,

To use the handler, you assign a field. Every time you assign the field it sends an event.

Clement
Reply all
Reply to author
Forward
0 new messages