Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 319022 - [DI] [UI]EventObjectSupplier doesn't work with wildcards in topic names
Summary: [DI] [UI]EventObjectSupplier doesn't work with wildcards in topic names
Status: RESOLVED FIXED
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: E4 (show other bugs)
Version: unspecified   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-06 11:41 EDT by Simon Chemouil CLA
Modified: 2012-12-13 15:00 EST (History)
1 user (show)

See Also:


Attachments
Fix for the EventObjectSupplier (2.47 KB, patch)
2010-07-06 11:43 EDT, Simon Chemouil CLA
no flags Details | Diff
Patch (7.76 KB, patch)
2010-07-06 15:21 EDT, Oleg Besedin CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Chemouil CLA 2010-07-06 11:41:34 EDT
Build Identifier: I20100705-2033

The OSGi spec allows to specify wildcards in topic names, ie, for an action group 
my/company/{ACTION1,ACTION2} one can listen on "my/company/*".

When using a wildcard in the topic in the @EventTopic annotation, the event is received but the Supplier can't find it back, and supplies null to the requestor.

The same problem exists with UIEventTopic / UIEventObjectSupplier

Reproducible: Always
Comment 1 Simon Chemouil CLA 2010-07-06 11:43:33 EDT
Created attachment 173572 [details]
Fix for the EventObjectSupplier

This patch fixes the problem by remembering the topic on which the requestor subscribed, rather than finding the full topic name from the received event.
Comment 2 Oleg Besedin CLA 2010-07-06 13:51:35 EDT
Simon, could you attach a patch against CVS Head? The patch seems to be using Git something-or-other.

Also, could you make a JUnit to make sure that the problem stays fixed?
Comment 3 Oleg Besedin CLA 2010-07-06 15:21:24 EDT
Created attachment 173589 [details]
Patch

Patch against CVS Head + JUnit + updated the UIEvent counterpart and its test.
Comment 4 Oleg Besedin CLA 2010-07-06 15:24:11 EDT
Patch applied to CVS Head. Thank Simon for finding this out and providing the fix!
Comment 5 Simon Chemouil CLA 2010-07-06 17:06:45 EDT
(In reply to comment #2)
> Simon, could you attach a patch against CVS Head? The patch seems to be using
> Git something-or-other.
> 
> Also, could you make a JUnit to make sure that the problem stays fixed?

I didn't see this earlier, thanks for applying the patch! (I'll provide my future patches in the appropriate format).