felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Guillaume Sauthier (JIRA)" <j...@apache.org>
Subject [jira] Created: (FELIX-2685) Wrong Element name when XML namespace contains ':'
Date Thu, 04 Nov 2010 10:29:42 GMT
Wrong Element name when XML namespace contains ':'

                 Key: FELIX-2685
                 URL: https://issues.apache.org/jira/browse/FELIX-2685
             Project: Felix
          Issue Type: Bug
          Components: iPOJO
    Affects Versions: iPOJO-1.6.0
            Reporter: Guillaume Sauthier

Here here my metadata.xml

  <session name="session"
           xmlns="http://jasmine.ow2.org/rules/1.0.0" />

Notice that the XML namespace is "http://jasmine.ow2.org/rules/1.0.0".
When I parse the Element/Attribute structure generated from this XML, i cannot access my "configuration"

An Element.toString() gives the fiollowing result:
//jasmine.ow2.org/rules/1.0.0:knowledge-base name="my-super-base"
		//jasmine.ow2.org/rules/1.0.0:property name="drools.multiThreadEvaluation" value="true"
		//jasmine.ow2.org/rules/1.0.0:property name="drools.eventProcessingMode" value="stream"

Element name is "//jasmine.ow2.org/rules/1.0.0:configuration", not only "configuration" :'(

The problem is probably due to a bug in ManifestMetadataParser.parseElements(String), where
we considere that the namespace stops at the first ':' character.

The easiest solution will probably to gather the composite element name (namespace+name) completely,
and then get the index of the last ':', then split the string.


This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message