History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: XW-535
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: tm_jee
Reporter: tm_jee
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
XWork

external-ref tag's content cannot be read occasionally by some parser

Created: 01/Jul/07 09:37 AM   Updated: 12/Jun/08 08:58 AM
Component/s: None
Affects Version/s: 1.2.2
Fix Version/s: 1.2.3, 2.1.2


 Description  « Hide
external-ref tag's content cannot be read occasionally by some parser

See http://forums.opensymphony.com/thread.jspa?threadID=79530&tstart=0 for more info.

Currently in XmlHelper, the way <external-ref> content is being look up is that it doesn't take into account looking into each childNodes of the dom element, it just assumes its the first one, this is not how result and param's content are looked up (see XmlHelper#getParams(Element) and XmlConfigurationProvider#buildResults(Element, PackageConfig) respectively for more info). It should be implemented like XmlHelper#getParams(Element) does.

I think it'd be better if we refactor this logic into XmlHelper, (the logic of reading in a tag's content eg. <result>... the content...</result>, where it could be make a public static method in XmlHelper such that XmlHelper#getParams(Element) could make use of it, XmlConfigurationProvider#buildResults(Element, PackageConfig) and XmlConfigurationProvider#buildExternalRefs(Element, PackageConfig) could use it.



 All   Comments   Change History      Sort Order:
tm_jee - [01/Jul/07 09:41 AM ]
this issue is related to http://jira.opensymphony.com/browse/XW-457

the last time we fix this, we've left out <external-ref>..</external-ref>

We should refactor the logic where the content of tag eg. <external-ref>,..</external-ref> to be in XmlHelper, so it would be scatered arround like it currently is.


tm_jee - [01/Jul/07 09:45 AM ]
fixed. plase kindly review. cheers.

tmjee@tmjee-laptop:~/development/xwork/src$ svn commit
Sending src/java/com/opensymphony/xwork/config/providers/XmlConfigurationProvider.java
Sending src/java/com/opensymphony/xwork/config/providers/XmlHelper.java
Adding src/test/com/opensymphony/xwork/config/providers/XmlHelperTest.java
Transmitting file data ...
Committed revision 1539.

tm_jee - [01/Jul/07 09:51 AM ]
resolving this issue. If there's any problem, feel free to -reopen it. cheers.

Sohel Katchi - [02/Jul/07 02:11 AM ]
Hi, I just tested it with my app and the newest revision (1539) seems to have fixed the problem!

Thanks!