You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by bu...@apache.org on 2005/12/15 18:08:02 UTC
DO NOT REPLY [Bug 37922] New: - XMLConfiguration doesn't support attribute names with a dot
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=37922>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=37922
Summary: XMLConfiguration doesn't support attribute names with a
dot
Product: Commons
Version: 1.1 Final
Platform: PC
OS/Version: Windows XP
Status: NEW
Severity: normal
Priority: P2
Component: Configuration
AssignedTo: commons-dev@jakarta.apache.org
ReportedBy: HC.Luis@gmail.com
This appeared to be fixed in 1.0 (bug 30205) but reappears in 1.1
With the new XMLConfiguration, which is hierarchical, properties with a dot in
their name apparently can be loaded, but the get methods don't find them.
For example:
<config>
<test>
<myservice-1.0>URL to my service 1.0</myservice-1.0>
<myservice-1.1>URL to my service 1.1</myservice-1.1>
</test>
</config>
I modified my configuration files to split dotted properties, for example:
<some.property>some value</some.property>
to
<some><property>some value</property></some>
This way we don't have to change our code and calls to
getString("some.property") continue to work.
The problem is that for some properties like myservice-1.0, splitting would
produce invalid xml:
<myservice-1><0>URL to my service 1.0</0></myservice-1>
so my clients are broken.
So now we have to change our config files and code, or continue using
Configuration 1.0
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org
DO NOT REPLY [Bug 37922] - [configuration] XMLConfiguration doesn't support attribute names with a dot
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=37922>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=37922
ebourg@apache.org changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |DUPLICATE
Summary| XMLConfiguration doesn't |[configuration]
|support attribute names with|XMLConfiguration doesn't
|a dot |support attribute names with
| |a dot
------- Additional Comments From ebourg@apache.org 2005-12-15 18:25 -------
Hi Luis, in this case you have to use the double dot syntax in your keys, for
example:
config.getURL("test.myservice-1..0");
This has been fixed in the upcoming 1.2 release, you can give a try at the
latest release candidate:
http://people.apache.org/~oheger/commons-configuration-1.2RC3
*** This bug has been marked as a duplicate of 35509 ***
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org
DO NOT REPLY [Bug 37922] - [configuration] XMLConfiguration doesn't support attribute names with a dot
Posted by bu...@apache.org.
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG�
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=37922>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND�
INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=37922
------- Additional Comments From HC.Luis@gmail.com 2005-12-15 20:46 -------
(In reply to comment #1)
> Hi Luis, in this case you have to use the double dot syntax in your keys, for
> example:
>
> config.getURL("test.myservice-1..0");
>
> This has been fixed in the upcoming 1.2 release, you can give a try at the
> latest release candidate:
> http://people.apache.org/~oheger/commons-configuration-1.2RC3
>
>
> *** This bug has been marked as a duplicate of 35509 ***
Cool.
I would have gone with the backslash notation though, as described in 35509.
At any rate, this should also be documented in the XML Howto.
Thanks.
--
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org