You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@jmeter.apache.org by mh...@aol.com on 2011/11/21 22:27:59 UTC

using XML as a data source instead of csv?

Is it possible (without custom module) to use XML as a data source?  I cannot use CSV and parameterization of values in generic XML (just take my word for it) for my specific testing.  And need to use the XML which has about 4000 nodes containing several elements.  Something like this:



<dom:MAIN xmlns:dom="http://api.com/1.6/main/domain" xmlns:ns="http://www.api.com/abc/Common/4">
    <dom:List>
        <dom:A>
            <dom:Address>
                <dom:ParsedList>
                    <dom:Parsed languageCode="eng">
                        <dom:StreetName>
                            <dom:BaseName>TENTH</dom:BaseName>
                            <dom:StreetType>ST</dom:StreetType>
                        </dom:StreetName>
                        <dom:HouseNumber>145</dom:HouseNumber>
                        <dom:CountryCode>AUS</dom:CountryCode>
                        <dom:PostalCode>3500</dom:PostalCode>
                    </dom:Parsed>
                </dom:ParsedList>
            </dom:Address>
            <dom:GeoPositionList>
                <dom:GeoPosition type="ROUTING">
                    <ns:Latitude>-34.18649</ns:Latitude>
                    <ns:Longitude>142.1572</ns:Longitude>
                </dom:GeoPosition>
            </dom:GeoPositionList>
        </dom:A>
    </dom:LocationList>
    <dom:Identity>
        <dom:Supplier>
            <dom:SupplierId>7</dom:SupplierId>
        </dom:Supplier>
    </dom:Identity>
</dom:MAIN>

<dom:MAIN xmlns:dom="http://api.com/1.6/main/domain" xmlns:ns="http://www.api.com/abc/Common/4">
    <dom:List>
        <dom:A>
            <dom:Address>
                <dom:ParsedList>
                    <dom:Parsed languageCode="eng">
                        <dom:StreetName>
                            <dom:BaseName>Hubbard</dom:BaseName>
                            <dom:StreetType>Ave</dom:StreetType>
                        </dom:StreetName>
                        <dom:HouseNumber>111</dom:HouseNumber>
                        <dom:CountryCode>USA</dom:CountryCode>
                        <dom:PostalCode>35005</dom:PostalCode>
                    </dom:Parsed>
                </dom:ParsedList>
            </dom:Address>            
        </dom:A>
    </dom:LocationList>
    <dom:Identity>
        <dom:Supplier>
            <dom:SupplierId>6</dom:SupplierId>
        </dom:Supplier>
    </dom:Identity>
</dom:MAIN>



The above should result in 2 separate REST calls for each MAIN node.  


Thanks
Matthew

Re: using XML as a data source instead of csv?

Posted by sebb <se...@gmail.com>.
On 21 November 2011 21:27,  <mh...@aol.com> wrote:
> Is it possible (without custom module) to use XML as a data source?

Depends what you mean by data source.

How are you using the data?

> I cannot use CSV and parameterization of values in generic XML (just take my word for it) for my specific testing.

Since you don't say anything about *what* you are trying to achieve,
it's difficult to offer any specific advice.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
For additional commands, e-mail: user-help@jmeter.apache.org