You are viewing a plain text version of this content. The canonical link for it is here.
Posted to muse-dev@ws.apache.org by "Dan Jemiolo (JIRA)" <ji...@apache.org> on 2006/12/09 21:55:25 UTC

[jira] Updated: (MUSE-153) Child topics in topic set documents are being parsed as root topics by notification producer

     [ http://issues.apache.org/jira/browse/MUSE-153?page=all ]

Dan Jemiolo updated MUSE-153:
-----------------------------

    Fix Version/s: 2.2.0

> Child topics in topic set documents are being parsed as root topics by notification producer
> --------------------------------------------------------------------------------------------
>
>                 Key: MUSE-153
>                 URL: http://issues.apache.org/jira/browse/MUSE-153
>             Project: Muse
>          Issue Type: Bug
>          Components: WSN Topics
>    Affects Versions: 2.0.0
>         Environment: any
>            Reporter: Mohammad Fakhar
>         Assigned To: Dan Jemiolo
>             Fix For: 2.2.0
>
>
> The addTopic routines in SimpleNotificationProducer, which parse topic set documents to TopicNameSpace objects, are treating child topics in the topic set document as root topics.  
> Lets say I  have this topic set doucment (root and children belong to same namespace):
> <root1>
>     <child1/>
>     <child2/>
> </root1>
> Here is the sequence of events which leads to the erroneous behavior:
> 1) createTopicSetDocument in SimpleNotificationProducer calls addTopics on all root topics in document.
> 2) addTopics calls addTopic to add root1, and then recursively calls itself for all children of root.
> 3) Now, when addTopic is called with child1, the following code is executed (in the addTopic method):
>         Topic topic = new SimpleTopic(localName, topicSpace);
>         topicSpace.addTopic(topic);
> This causes the child1 to be added as a root topic as this code is executed in SimpleTopicSpace.addTopic: "_rootTopics.put(name, topic);"
> where the name is child1. Same applies to child2.
> The problem was exposed when I tried to evaluate a concrete topic expression against this topic set document; it was treating child1 and child2 as root topics in the namespace, instead of child topics of root1. 

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: muse-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: muse-dev-help@ws.apache.org