Yasir
Yasir

Reputation: 81

Why am I getting this strange response in JMeter where its working fine in SOAP UI?

When validating SOAP XML in JMeter/LoadRunner, getting below strange response: However it works fine in SOAPUI.

Replay Response:

#content{ FONT-SIZE: 0.7em; PADDING-BOTTOM: 2em; MARGIN-LEFT: 30px}BODY{MARGIN-TOP: 0px; MARGIN-LEFT: 0px; COLOR: #000000; FONT-FAMILY: Verdana; BACKGROUND-COLOR: white}P{MARGIN-TOP: 0px; MARGIN-BOTTOM: 12px; COLOR: #000000; FONT-FAMILY: Verdana}PRE{BORDER-RIGHT: #f0f0e0 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #f0f0e0 1px solid; MARGIN-TOP: -5px; PADDING-LEFT: 5px; FONT-SIZE: 1.2em; PADDING-BOTTOM: 5px; BORDER-LEFT: #f0f0e0 1px solid; PADDING-TOP: 5px; BORDER-BOTTOM: #f0f0e0 1px solid; FONT-FAMILY: Courier New; BACKGROUND-COLOR: #e5e5cc}.heading1{MARGIN-TOP: 0px; PADDING-LEFT: 15px; FONT-WEIGHT: normal; FONT-SIZE: 26px; MARGIN-BOTTOM: 0px; PADDING-BOTTOM: 3px; MARGIN-LEFT: -30px; WIDTH: 100%; COLOR: #ffffff; PADDING-TOP: 10px; FONT-FAMILY: Tahoma; BACKGROUND-COLOR: #003366}.intro{MARGIN-LEFT: -15px}XXX ServiceXXX Service


"You have created a service.To test this service, you will need to create a client and use it to call the service. You can do this using the svcutil.exe tool from the command line with the following syntax....."

Upvotes: 0

Views: 84

Answers (3)

Yasir
Yasir

Reputation: 81

I added below similar soap headers manually in my JMeter script, though these headers are not found in SOAP UI, which then works fine for me. Also the Method is "POST":

<wsse:Security xmlns:wsse="XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX">
   <wsse:UsernameToken wsu:Id="sample" 
       xmlns:wsu="XXXXXXXXXXXXXXXXXXXXXXXXXX">
    <wsse:Username>XXXXXXXXX</wsse:Username>
    <wsse:Password Type="wsse:PasswordText">XXXXXXXXX</wsse:Password>
    <wsu:Created>XXXXXXXXXXXXXX</wsu:Created>
   </wsse:UsernameToken>
  </wsse:Security>

Upvotes: 0

Dmitri T
Dmitri T

Reputation: 168092

Most probably you're not sending the same request like SoapUI does.

Use a 3rd-party sniffer tool to compare requests sent by both tools, identify the differences and amend your JMeter configuration so it would send exactly the same request as SoapUI does.

The most common reason of mismatch is missing HTTP Headers like Content-Type and/or SOAPAction so inspect your HTTP Header Manager

You can also consider recording the request from SoapUI using JMeter's HTTP(S) Test Script Recorder. If you configure SoapUI to use JMeter as the proxy JMeter will be able to intercept the request and generate the appropriate HTTP Request sampler and HTTP Header Manager.

Upvotes: 1

James Pulley
James Pulley

Reputation: 5692

Think about how your requests might vary architecturally. Are you including all of the same headers in Jmeter as you are in SOAPUI...........by default........?

Record the SOAPUI request, including all headers. Then look at what you are sending in Jmeter vs SOAPUI

Upvotes: 1

Related Questions