Closed Nuvindu closed 17 hours ago
This happen because, the included records does not inherit its metadata informations. Related spec issue - https://github.com/ballerina-platform/ballerina-spec/issues/1311
So this issue should be fixed from the language repository.
This issue is NOT closed with a proper Reason/ label. Make sure to add proper reason label before closing. Please add or leave a comment with the proper reason label now.
- Reason/EngineeringMistake - The issue occurred due to a mistake made in the past.
- Reason/Regression - The issue has introduced a regression.
- Reason/MultipleComponentInteraction - Issue occured due to interactions in multiple components.
- Reason/Complex - Issue occurred due to complex scenario.
- Reason/Invalid - Issue is invalid.
- Reason/Other - None of the above cases.
Description
When converting a record type annotated with
@xmldata:Namespace
to XML using thexmldata:toXml()
function, the generated XML does not include the namespace information specified in the annotations.Steps to Reproduce
Result:
<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope"><value>this is a string</value></soap:Envelope>
Expected Result:
<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope"><value xmlns:xs1="http://www.w3.org/2001/XMLSchema1">this is a string</value></soap:Envelope>
Version
2201.10.2
Environment Details (with versions)
No response