I have a web service that does a simple task of 'auto-incrementing' a simple field.I test it using SoapUI. That is, whenever I run SoapUI, the response would be a value that is one plus it's previous value. Now, the catch is, I want to test simultaneous users running the same web service. Meaning, if they all access the web service at once, the web service will respond with the correct incremented value.
For instance, I have 3 users who accessed the service at the same time. I am expecting that the response (integer value) they would get will not be the same with each other. It should be incremental. That's what I want to test.
I'm thinking of maybe incorporating JMeter and SoapUI, but I'm not sure if that's even possible. Do you have any suggestions on how I can handle this?
SoapUI offers some limited load testing capabilities so if you think the load from one machine will be enough and you will be happy with the load test metrics which reflect only average/min/max response times and throughput - you can conduct your load test using SoapUI only.
If you decide to go for JMeter - be aware that you can migrate your test in at least 2 ways:
Record running SoapUI test scenario using JMeter's HTTP(S) Test Script Recorder
Taurus automation framework comes with SoapUI xml to JMeter jmx converter.
If you want to do it manually check out Building a SOAP WebService Test Plan JMeter User Manual chapter
In order to "tell" JMeter to execute HTTP Request samplers with the desired amount of virtual users at exactly the same moment add Synchronizing Timer as a child of the relevant HTTP Request sampler.
Related
While developing a web application I have the following use case:
a 3rd party Web Service with quite a lot of methods is deployed on a test server A (with a single endpoint, e.g. http://3rdPartyServer/3rdPartySvc?WSDL)
a new method is about to be implemented in the near future, but I need to use it now
the rest of the methods are used throughout my code extensively
So I would like to do the following:
Create a mock service in SoapUI locally, based on the new WSDL which includes the new WS method (i.e. a superset of the WS methods currently on server A)
point my local application server to use the SoapUI mock service endpoint
mock only the response of the new WS method (create a dummy response for it in SoapUI)
let the other WS method calls to reach server A and return whatever it returns normally (i.e. use SoapUI as a proxy for these calls)
I've gone through the SoapUI documentation regarding service mocking and have used it numerous times, but could not find an option for such "pass-through" behavior.
When you read in your WSDL, the endpoint will point to your server.
Open your service, and select the service endpoint.
Add a second endpoint, to point to your mock. SoapUI has little bit of documentation showing this here. Only step "2. Getting Started" applies, not step 3!
In each of your tests, where you are using the mocked method, you will need to select the mock endpoint. Further discussion is here.
I am trying to create a set of Regression Test scripts to test the different Web Services and the corresponding methods related to my Web Application in HP UFT. I am using the API testing feature of UFT. I have the request and response XMLs (obtained manually) of each web service method necessary for the testing. There are more than 50 web service methods to be tested. The test cases for all of them are same. The input data of the request is currently being set by parameterizing the data from an excel spreadsheet.
Since the test cases are exactly same and the input data for all the web service methods have similar fields, such as First Name, Last Name, LoginID etc., I want to know if there is a way to write a single script which dynamically reads the web service method name and the associated data from the spreadsheet and uses it in the request XML file (same name as the web service method) which is also loaded in run time.
In this way, after the script has been developed, all I need to do prepare a list of all the web service methods to be tested and enter them in the Test spreadsheet along with the required request data. The script would loop through all the web service methods and execute the test cases for each web service method one by one.
in your case I think you should use a Soap Request method rather than a Web Service Call. Using soap request, other than the message itself, you can parameterize also the Endpoint Address and the SoapAction
Hope this helps
Yossi
Due to the fall of SOAP::WSDL which had generated me real Perl modules I have to look for something other in order to handle a SOAP service. The generated modules won't work starting from Perl v5.18.
I have the following situation with my web application.
I have a PSGI compatible, Dancer2 driven, persistent web application.
The web application handles multiple concurrent customers.
The web application is between the customer and an external SOAP service.
The SOAP service uses customer sessions via cookies which have to be integrated on the web application internally for the customer.
The web application holds an WSDL file copy of the SOAP service.
I'm looking for a module that creates an interface out of the WSDL file and handles parameter/schema validation and communication with the SOAP service. I would like to call a method (SOAP call) with parameters (SOAP call parameters) and receive a cleaned data or object structure of the response.
The problem is that the web application needs to handle multiple concurrent customer cookie sessions. So I need a module which offers the possibility to override the cookie jar for that particular request and extract the cookies after the request without causing interference with other concurrent requests.
I found XML::Compile which I can initialize as a singleton at web application start up. But with this solution I ran into problems with interfering other customer requests. So the requests are not separated. Initializing XML::Compile for every request is not the solution either because it will parse the WSDL and generate handlers over and over again for every request the customer sends to the web application.
Is there any solution/module that fits my needs or do I miss something with XML::Compile and it's possible with it?
Are you using Catalyst?
I've been happy using Catalyst::Controller::SOAP and its companion Catalyst::Model::SOAP to build SOAP/WSDL servers and consumers, being able to integrate Perl Applications even with Microsoft Document Literal-Wrapped thing.
Even if not using Catalyst you may probably learn from its code. It uses XML::Compile::WSDL11.
Before just answering: Use SoapUI. Please read the Question, because I tried SoapUI.
I have a lot big wsdl Files. Every Method works like this:
First do a synchronous Call:
Request: Please do foo and send Request to URI: XY
Response: Ok, your Job has UUID: abc
After the Job is done, my Sevice will respond to URI: XY, by sending only a request Message synchronously:
Request: Ok I finished your Job with the UUID: abc and the result is bar
We needed to use this behavior, because we have a pool where all answers will be stored and are identified by UUID.
Do you know a possibility to test such a SOAP Service?
I tried:
SOAP UI
BPEL Unit (I think it should be possible with BPEL Unit but I can't make it work properly)
Please don't recommend writing my own JAVA tests, because I have more than 100 methods to test.
Also the Tests need to be run and the results need to be analyzed automatically in a Test-suite, I can't do this for 100 Methods by hand everytime I change the code of the Web Service.
I'm one of the SoapUI Guys, so you'll probably HATE my answer...
But the solution is using SoapUI; more specifically using MockResponse TestSteps. SoapUI is NOT very strong when it comes to BPEL testing, but using MockResponse Steps you can fix it.
Look here: http://www.soapui.org/SOAP-and-WSDL/testing-asynchronous-services.html. Even though all calls are done synchronously, this can still be considered asynch testing since we have more than plain request/response.
I also know that Oracle has got a great write up on this.
What you need to do is to create a mock service that will receive the second call which signals that the job processing is done. This is can be done in SOAP UI, you can read about how to create a mock web-service here.
You can test Web Services by using Eclipse.
Just put the WSDL file on your project -> right click on the file -> web services -> test using web service explorer.
You will have an interface showing all your WSDL operations and fields which are needed.
I am trying to test a stress test a web service using JMeter but the requests keep stopping after around 4 hours.
I submit 10 requests per second from JMeter. The web service is still functioning properly after JMeter completes.
I am using only 1 soap request and I do not specify to rad the soap response.
Why JMeter gives up after a certain amount of time?
There are several suggestions to check:
Use the latest version of JMeter.
Use latest/different JDK version/vendor.
Try running JMeter in command line mode (in case you have run it in GUI before).
Check networking/firewall setup between your client and your server.