Forum Discussion

rajs2020's avatar
Frequent Contributor
4 years ago

Why do ReadyAPI and SoapUI convert database result into XML ?

I see that ReadyAPI and SoapUI convert relational database result into XML. Why do they do that? If it is possible to convert it into JSON instead, then why do they don't do it?
  • richie's avatar
    4 years ago
    Hey rajs2020,

    This is a complete guess on my part, but id suggest the reason is historic.

    Xml has been around a lot longer. I think json was only standardized quite recently (within the last decade) where xml's been knocking about for years.

    Im guessing Eviware (owners of SoapUI before Smartbear grabbed it) when they first added jdbc support to SoapUI, json wasnt standardized so the risk of making chsnges to its handling by altering it from xml to json just werent worth the risk of json never been stndardized and slipping into obscurity.

    Json advantages over xml just dont really add much incentive to switch from xml to json (e.g. a bit more lightweight, cos attribute names arent duplicated like they are in xml elements and datatypes are somewhat preserved in json where theyre not in xml...e.g. think numeric and text types. These are reflected by wrapping values in double quotes in json...this isnt done in xml).

    Personally i still struggle when im editing very complex json (i struggle with complex jsonpath), whereas i can spot malformed xml from a mile off.

    Ok. Thats just my guess/opinion and isnt necessarily true at all, but its the best guess i got!