NVM, I think I figured out.

Thanks
Alex Ough

On Wed, Dec 11, 2013 at 11:19 AM, Alex Ough <alex.o...@sungard.com> wrote:
> Hi Murali,
>
> Where will be the right place to add my implemented EventSubscriber to
> the EventBus?
>
> Thanks
> Alex Ough
>
> On Wed, Dec 11, 2013 at 5:39 AM, Murali Reddy <murali.re...@citrix.com> wrote:
>>
>> Sorry my bad. Sample code is using old way of loading beans before spring
>> is brought in. Please use 'ComponentContext.getComponent(EventBus.class);'
>> instead. You can refer to ActionEventUtils to see how to instantiate the
>> EventBus.
>>
>> On 09/12/13 11:55 PM, "Alex Ough" <alex.o...@sungard.com> wrote:
>>
>>>But I think there seems to be a missing package because I can't find
>>>the package, 'utils', that includes these 2 classes either.
>>>
>>>import com.cloud.utils.component.Adapters;
>>>import com.cloud.utils.component.ComponentLocator;
>>>
>>>FYI, I'm using the master.
>>>
>>>Thanks
>>>Alex Ough
>>>
>>>On Mon, Dec 9, 2013 at 12:18 PM, Nitin Mehta <nitin.me...@citrix.com>
>>>wrote:
>>>> Alex - I think that interface doesn't contain any function definition.
>>>>So
>>>> just create the interface yourself and use the example as given.
>>>> You will have to add in the configuration to instantiate this
>>>> implementation as well.
>>>>
>>>> Thanks,
>>>> -Nitin
>>>>
>>>> On 09/12/13 9:20 AM, "Alex Ough" <alex.o...@sungard.com> wrote:
>>>>
>>>>>Hi Muali,
>>>>>Thanks for your information, but in the sample codes,
>>>>>'EventNotificationSubscriberImpl' implements an interface,
>>>>>'EventNotificationsSubscriber', but I can't find
>>>>>'EventNotificationsSubscriber' in the project.
>>>>>Can you show me where it is located?
>>>>>
>>>>>Thanks again.
>>>>>Alex Ough
>>>>>
>>>>>On Mon, Dec 9, 2013 at 12:30 AM, Murali Reddy <murali.re...@citrix.com>
>>>>>wrote:
>>>>>> On 07/12/13 2:52 AM, "Alex Ough" <alex.o...@sungard.com> wrote:
>>>>>>
>>>>>>>All,
>>>>>>>
>>>>>>>To support the new feature, CLOUDSTACK-4992, I'd like to create an
>>>>>>>event subscriber that implements 'EventSubscriber' interface, but I'm
>>>>>>>not sure how to register that subscriber to make it running.
>>>>>>
>>>>>> Alex,
>>>>>>
>>>>>> I pasted a subscriber example at [1]. You need to register the
>>>>>>subscriber
>>>>>> with interested events. Subscriber should implement 'EventSubscriber'.
>>>>>>
>>>>>>
>>>>>>>
>>>>>>>Do I need to specify it in any config file or load it from anywhere
>>>>>>>when the management server is started?
>>>>>>
>>>>>> If your code is expected to run with management server, you can just
>>>>>>load
>>>>>> the EventBus, and subscribe to it. HTH
>>>>>>
>>>>>> [1] http://pastebin.com/XhFdfa1U
>>>>>>
>>>>>>>
>>>>>>>Your reply will be very appreciated.
>>>>>>>Thanks
>>>>>>>Alex Ough
>>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>
>>>>
>>>
>>
>>
>>

Reply via email to