SlideShare a Scribd company logo
Productivity Acceleration Tools for SOA Testers




             Evanthika Amarasiri   : Technical Lead - QA
             Nirodha Gallage       : Senior Software Engineer - QA


                                                       April 2013
About WSO2
●   Providing the only complete open source componentized
    cloud platform
    - Dedicated to removing all the stumbling blocks to enterprise agility
    - Enabling you to focus on business logic and business value

●   Recognized by leading analyst firms as visionaries and
    leaders
    - Gartner cites WSO2 as visionaries in all 3 categories of application
    infrastructure
    - Forrester places WSO2 in top 2 for API Management

●   Global corporation with offices in USA, UK & Sri Lanka
    - 200+ employees and growing

●   Business model of selling comprehensive support &
    maintenance for our products
150+ globally positioned support customers
Agenda

●   Advantages of using tools for SOA testing
●   Choosing the right tool that matches your requirement
●   Test Scenarios
    - soapUI
    - Apache JMeter
●   Tips on tools
Advantages of using tools & automation for testing
 ●   No need to re-invent the wheel : Reduce time of writing
     client programs from scratch
 ●   Reduces time on frequent recursive testing
 ●   Saves time to utilize the specialized knowledge effectively;
     i.e. to do exploratory testing
 ●   Reduces test execution time : Takes more time if done
     manually
 ●   Helps to release early & release often
 ●   Reduces the possibility of missing test scenarios
 ●   Ability to do dynamic data driven testing
Advantages of using tools & automation for testing
Contd...
●   Ability to do load/performance testing
●   Can generate result summaries and reports easily
●   Ability to integrate test suites in build systems and trigger
    automatically
Choosing the right tool...
soapUI - What does it support?
●   Automated request generation : i.e. Generate SOAP
    request messages when WSDL is provided
●   Ability to validate responses : i.e. assertions
●   Support for QoS : i.e. Security, MTOM
●   Ability to simulate service providers; i.e. mock services
●   Ability to do performance testing
●   Supports multiple protocols & message types : i.e. HTTP,
    HTTPS, REST, JMS, JSON
Examples with soapUI
●   Web Testcase support
●   Invoking secured web services with HTTP basic
    authentication
●   Invoking a web services secured with asymmetric binding
    policy
●   Assertions for responses
●   Sending HTTP chunk encoded messages
●   Executing soapUI test suites/test cases in headless mode
●   Testing RESTful APIs
Web Testcase support
 ●   Allows to test solutions without ?wsdl
 ●   Invoke simple HTTP methods; i.e. GET, POST, etc on
     different services within the same project.
Basic Authentication
An example
                                                                      Service Provider
Service Consumer




                                                                                Service A



                                                                    Service B
                   <GET https://192.168.217.1:
                   9443/services/HelloService/greet?name=SoapUI
                   HTTP/1.1
                   Accept-Encoding: gzip,deflate
                   Authorization: Basic ZXZhbjplZWVlZWU=                        Service C
                   Host: 192.168.217.1:9443
                   Connection: Keep-Alive
                   User-Agent: Apache-HttpClient/4.1.1 (java 1.5)
Signing SOAP messages
   ●    Asymmetric binding
       - message security is provided using asymmetric keys
          E.g.: public keys.

                           Client signs the message from his private key and
                           encrypts from server's public key




                           Server signs the message from his private key and
                           encrypts from client's public key                   Server's      Client's
Client's      Server's
              public key                                                       private key   public key
private key




 - assures confidentiality, integrity and the non-repudiation
Increase raw request/response size
     When raw view does not show large messages,
     configure UI settings ...




 ... and it will increase
 - size of raw request messages
 - size of raw response messages
Assertions
 ●   Validates responses
 ●   Added to test steps
 ●   Provides different types of assertions; assertions to be
     done on response message, for HTTP status codes, SOAP
     faults




                                                        Add Assertions
Sending chunked-encoded requests
 ●     Content-Length
       - The length of the request body in octets
     POST /services/Axis2Service HTTP/1.1
     Accept-Encoding: gzip,deflate
     Content-Type: text/xml;charset=UTF-8
     SOAPAction: "urn:echoInt"
     Content-Length: 3782
     Host: 127.0.0.1:9764
     Connection: Keep-Alive
     User-Agent: Apache-HttpClient/4.1.1 (java 1.5)




 ●      Chunked
        - Messages are sent in chunks
     POST /services/Axis2Service HTTP/1.1
     Accept-Encoding: gzip,deflate
     Content-Type: text/xml;charset=UTF-8
     SOAPAction: "urn:echoInt"
     Transfer-Encoding: chunked
     Host: 127.0.0.1:9764
     Connection: Keep-Alive
     User-Agent: Apache-HttpClient/4.1.1 (java 1.5)
Headless mode compatibility of soapUI
●   Windows
        ○   testrunner.bat -s Axis2Service_TestSuite -r -f C:soapUIlogsresponse -I
            C:soapUIprojectsmy_soapui-project.xml


●   Linux
        ○   testrunner.sh -s Axis2Service_TestSuite -r -f /opt/soapUI/logs/response -I
            /opt/soapUI/projects/my_soapui-project.xml




●   Parameter list
    s                      the test suite to run
    c                      the test case to run
    r                      prints summary report
    l                      ignore errors and continue
    f                      folder to which test results should be saved
Testing RESTful APIs
 ●   Scenario 1 - Invoke Login API of WSO2 API Manager
In which situations we can use JMeter?
●   To simulate multiple user access/ load tests
●   For data driven testing
●   To analyze & measure performance of services
●   To validate responses; i.e. assertions
●   To create test suites with real world scenarios which involves
    executing multiple services sequentially or in parallel
●   Support for different transport protocols; i.e. HTTP, HTTPS,
    JMS, MAIL, FTP, JDBC, LDAP etc
Testing examples with JMeter
Scenario 1 : Testing a web service with dynamic data
 1. Send SOAP requests to a Stock Quote web service
 2. Need to send dynamic data inputs in the SOAP request
 3. Read the response and verify the response is valid



                1. Send request to the Web Service

                2. Send requests with dynamic inputs



                                                       Stock Quote
                                                       service
                      (Currency conversion rate)
Testing examples with JMeter
Scenario 1 : What JMeter components you will need?
 ●   Thread Group
 ●   Sampler > SOAP/XML-RPC Request
 ●   Config Element > CSV Data Set Config
 ●   Assertions > Response Assertion
 ●   Listener > View Results Tree
 ●   Listener > Aggregate Report




                         o
                   Dem
Testing examples with JMeter
Scenario 2 : Testing API's with WSO2 API Manager
 1. Call the login API [REST] and acquire an access token
 2. Use that access token to invoke the API
 3. Read the response and verify the response is correct



                         1. Invoke Login API

                                                                Login API
                           (Access Token)


            2. Invoke Stock Quote API with the Access Token
                                                              Stock Quote
                                                              API
                             (Response)
Testing examples with JMeter
Scenario 2 : What JMeter components you will need?
 ●   Thread Group
 ●   Config Element > HTTP Cookie Manager
 ●   Config Element > User Defined Variables
 ●   Sampler > HTTP Request
 ●   Config Element > HTTP Header Manager
 ●   Post Processors > Regular Expression Extractor
 ●   Assertions > Response Assertion
 ●   Logic Controller > Loop Controller
 ●   Listner > View Results Tree
 ●   Listner > Aggregate Report



                                                         o
                                                      Dem
Testing examples with JMeter
Scenario 3 : Running JMeter scripts in 'Headless' mode

 ● Create it once.... Run it anywhere!!!
 ● All you need is a JMeter distribution a JRE installed and a
      command shell
 ● Linux : ./jmeter.sh -n -t /path/to/JmeterTest.jmx -l /path/to/resultsFile.jtl
 ● Windows : jmeter.bat -n -t pathtoJmeterTest.jmx -l pathtoresultsFile.jtl
 ● Use Shell/ Batch scripts to change test parameters and execute
      programmatically, for recursive test scenarios.
  Refer : http://nirodhawrites.blogspot.com/2012/06/how-to-run-jmeter-tests-in-non-gui-mode.html
Tips...
    When sending http requests with Jmeter always select
    'httpclient4' as the implementation for high load scenarios
    When doing load tests disable "View Results Tree", as it
    affects thread creation rate.
    Always keep test parameters like endpoints, IPs, ports etc as
    configurable variables
    For high load tests run the Jmeter tests in headless mode, and
    write the result to a .jtl file. You can open them later in JMeter
    UI, to check results summary, and performance figures.
    When measuring performance figures with load tests make sure
    only the client and server are running in their respective
    machines
Tips...
   Other free external plugins are available for Jmeter
    ● Ant plugin   http://www.programmerplanet.org/pages/projects/jmeter-ant-task.php

      Allows you to run JMeter script as an ANT task
      Creates reports
    ● Google plugin       http://code.google.com/p/jmeter-plugins/

      Generates new set of graphs for performance test
      Have some new throughput controlling components
Q&A
Engage with WSO2
 ● Helping you get the most out of your deployments
 ● From project evaluation and inception to development
   and going into production, WSO2 is your partner in
   ensuring 100% project success
Engage with WSO2
Productivity Acceleration Tools for SOA Testers

More Related Content

What's hot

Oracle API Gateway
Oracle API GatewayOracle API Gateway
Oracle API Gateway
Rakesh Gujjarlapudi
 
JavaEE Microservices platforms
JavaEE Microservices platformsJavaEE Microservices platforms
JavaEE Microservices platforms
Payara
 
How to build a custom stack with WSO2 carbon
How to build a custom stack with WSO2 carbon How to build a custom stack with WSO2 carbon
How to build a custom stack with WSO2 carbon WSO2
 
How lagom helps to build real world microservice systems
How lagom helps to build real world microservice systemsHow lagom helps to build real world microservice systems
How lagom helps to build real world microservice systems
Markus Eisele
 
Designing distributed, scalable and reliable systems using NServiceBus
Designing distributed, scalable and reliable systems using NServiceBusDesigning distributed, scalable and reliable systems using NServiceBus
Designing distributed, scalable and reliable systems using NServiceBus
Mauro Servienti
 
Microservice Architecture Patterns, by Richard Langlois P. Eng.
Microservice Architecture Patterns, by Richard Langlois P. Eng.Microservice Architecture Patterns, by Richard Langlois P. Eng.
Microservice Architecture Patterns, by Richard Langlois P. Eng.
Richard Langlois P. Eng.
 
Real time event feeds with NServiceBus and SignalR
Real time event feeds with NServiceBus and SignalRReal time event feeds with NServiceBus and SignalR
Real time event feeds with NServiceBus and SignalR
Roy Cornelissen
 
Oracle API Gateway Installation
Oracle API Gateway InstallationOracle API Gateway Installation
Oracle API Gateway Installation
Rakesh Gujjarlapudi
 
Cloud Messaging with NServiceBus and Microsoft Azure
Cloud Messaging with NServiceBus and Microsoft AzureCloud Messaging with NServiceBus and Microsoft Azure
Cloud Messaging with NServiceBus and Microsoft Azure
Particular Software
 
Understanding the WSO2 Platform
Understanding the WSO2 PlatformUnderstanding the WSO2 Platform
Understanding the WSO2 Platform
WSO2
 
Monitoring and Tuning GlassFish
Monitoring and Tuning GlassFishMonitoring and Tuning GlassFish
Monitoring and Tuning GlassFish
C2B2 Consulting
 
Developing Micro-Services for Cloud using Java
Developing Micro-Services for Cloud using JavaDeveloping Micro-Services for Cloud using Java
Developing Micro-Services for Cloud using Java
WSO2
 
Growing Adoption of Open Source in Enterprises
Growing Adoption of Open Source in EnterprisesGrowing Adoption of Open Source in Enterprises
Growing Adoption of Open Source in EnterprisesWSO2
 
Keynote-Service Orientation – Why is it good for your business
Keynote-Service Orientation – Why is it good for your businessKeynote-Service Orientation – Why is it good for your business
Keynote-Service Orientation – Why is it good for your businessWSO2
 
Learn Oracle WebLogic Server 12c Administration
Learn Oracle WebLogic Server 12c AdministrationLearn Oracle WebLogic Server 12c Administration
Learn Oracle WebLogic Server 12c Administration
Revelation Technologies
 
AAI-4847 Full Disclosure on the Performance Characteristics of WebSphere Appl...
AAI-4847 Full Disclosure on the Performance Characteristics of WebSphere Appl...AAI-4847 Full Disclosure on the Performance Characteristics of WebSphere Appl...
AAI-4847 Full Disclosure on the Performance Characteristics of WebSphere Appl...
WASdev Community
 
Was liberty
Was libertyWas liberty
Was liberty
Ian Robinson
 
AAI-1445 Managing Dynamic Workloads with WebSphere ND and in the Cloud
AAI-1445 Managing Dynamic Workloads with WebSphere ND and in the CloudAAI-1445 Managing Dynamic Workloads with WebSphere ND and in the Cloud
AAI-1445 Managing Dynamic Workloads with WebSphere ND and in the Cloud
WASdev Community
 
Camel Based Development Application
Camel Based Development ApplicationCamel Based Development Application
Camel Based Development Application
Return on Intelligence
 
Microservices with Node and Docker
Microservices with Node and DockerMicroservices with Node and Docker
Microservices with Node and Docker
Tony Pujals
 

What's hot (20)

Oracle API Gateway
Oracle API GatewayOracle API Gateway
Oracle API Gateway
 
JavaEE Microservices platforms
JavaEE Microservices platformsJavaEE Microservices platforms
JavaEE Microservices platforms
 
How to build a custom stack with WSO2 carbon
How to build a custom stack with WSO2 carbon How to build a custom stack with WSO2 carbon
How to build a custom stack with WSO2 carbon
 
How lagom helps to build real world microservice systems
How lagom helps to build real world microservice systemsHow lagom helps to build real world microservice systems
How lagom helps to build real world microservice systems
 
Designing distributed, scalable and reliable systems using NServiceBus
Designing distributed, scalable and reliable systems using NServiceBusDesigning distributed, scalable and reliable systems using NServiceBus
Designing distributed, scalable and reliable systems using NServiceBus
 
Microservice Architecture Patterns, by Richard Langlois P. Eng.
Microservice Architecture Patterns, by Richard Langlois P. Eng.Microservice Architecture Patterns, by Richard Langlois P. Eng.
Microservice Architecture Patterns, by Richard Langlois P. Eng.
 
Real time event feeds with NServiceBus and SignalR
Real time event feeds with NServiceBus and SignalRReal time event feeds with NServiceBus and SignalR
Real time event feeds with NServiceBus and SignalR
 
Oracle API Gateway Installation
Oracle API Gateway InstallationOracle API Gateway Installation
Oracle API Gateway Installation
 
Cloud Messaging with NServiceBus and Microsoft Azure
Cloud Messaging with NServiceBus and Microsoft AzureCloud Messaging with NServiceBus and Microsoft Azure
Cloud Messaging with NServiceBus and Microsoft Azure
 
Understanding the WSO2 Platform
Understanding the WSO2 PlatformUnderstanding the WSO2 Platform
Understanding the WSO2 Platform
 
Monitoring and Tuning GlassFish
Monitoring and Tuning GlassFishMonitoring and Tuning GlassFish
Monitoring and Tuning GlassFish
 
Developing Micro-Services for Cloud using Java
Developing Micro-Services for Cloud using JavaDeveloping Micro-Services for Cloud using Java
Developing Micro-Services for Cloud using Java
 
Growing Adoption of Open Source in Enterprises
Growing Adoption of Open Source in EnterprisesGrowing Adoption of Open Source in Enterprises
Growing Adoption of Open Source in Enterprises
 
Keynote-Service Orientation – Why is it good for your business
Keynote-Service Orientation – Why is it good for your businessKeynote-Service Orientation – Why is it good for your business
Keynote-Service Orientation – Why is it good for your business
 
Learn Oracle WebLogic Server 12c Administration
Learn Oracle WebLogic Server 12c AdministrationLearn Oracle WebLogic Server 12c Administration
Learn Oracle WebLogic Server 12c Administration
 
AAI-4847 Full Disclosure on the Performance Characteristics of WebSphere Appl...
AAI-4847 Full Disclosure on the Performance Characteristics of WebSphere Appl...AAI-4847 Full Disclosure on the Performance Characteristics of WebSphere Appl...
AAI-4847 Full Disclosure on the Performance Characteristics of WebSphere Appl...
 
Was liberty
Was libertyWas liberty
Was liberty
 
AAI-1445 Managing Dynamic Workloads with WebSphere ND and in the Cloud
AAI-1445 Managing Dynamic Workloads with WebSphere ND and in the CloudAAI-1445 Managing Dynamic Workloads with WebSphere ND and in the Cloud
AAI-1445 Managing Dynamic Workloads with WebSphere ND and in the Cloud
 
Camel Based Development Application
Camel Based Development ApplicationCamel Based Development Application
Camel Based Development Application
 
Microservices with Node and Docker
Microservices with Node and DockerMicroservices with Node and Docker
Microservices with Node and Docker
 

Similar to Productivity Acceleration Tools for SOA Testers

Integration Testing as Validation and Monitoring
 Integration Testing as Validation and Monitoring Integration Testing as Validation and Monitoring
Integration Testing as Validation and Monitoring
Melissa Benua
 
POST/CON 2019 Workshop: Testing, Automated Testing, and Reporting APIs with P...
POST/CON 2019 Workshop: Testing, Automated Testing, and Reporting APIs with P...POST/CON 2019 Workshop: Testing, Automated Testing, and Reporting APIs with P...
POST/CON 2019 Workshop: Testing, Automated Testing, and Reporting APIs with P...
Postman
 
Writing Acceptance Tests Using Fitnesse
Writing Acceptance Tests Using FitnesseWriting Acceptance Tests Using Fitnesse
Writing Acceptance Tests Using Fitnesse
Facundo Farias
 
359686888-presentationJMeter-ppt.ppt
359686888-presentationJMeter-ppt.ppt359686888-presentationJMeter-ppt.ppt
359686888-presentationJMeter-ppt.ppt
JosEnriqueLoayzaSols
 
QSpiders - Presentation JMeter
QSpiders - Presentation JMeterQSpiders - Presentation JMeter
QSpiders - Presentation JMeter
Qspiders - Software Testing Training Institute
 
Rest assured
Rest assuredRest assured
Rest assured
Varun Deshpande
 
WSO2 API Microgateway for Easier Development and Greater Scalability
WSO2 API Microgateway for Easier Development and Greater ScalabilityWSO2 API Microgateway for Easier Development and Greater Scalability
WSO2 API Microgateway for Easier Development and Greater Scalability
WSO2
 
Mykola Kovsh - Functional API automation with Jmeter
Mykola Kovsh - Functional API automation with JmeterMykola Kovsh - Functional API automation with Jmeter
Mykola Kovsh - Functional API automation with Jmeter
Ievgenii Katsan
 
Performance testing jmeter
Performance testing jmeterPerformance testing jmeter
Performance testing jmeterBhojan Rajan
 
InterConnect 2016 Java EE 7 Overview (PEJ-5296)
InterConnect 2016 Java EE 7 Overview (PEJ-5296)InterConnect 2016 Java EE 7 Overview (PEJ-5296)
InterConnect 2016 Java EE 7 Overview (PEJ-5296)
Kevin Sutter
 
Structured Functional Automated Web Service Testing
Structured Functional Automated Web Service TestingStructured Functional Automated Web Service Testing
Structured Functional Automated Web Service Testing
rdekleijn
 
DevOpsDays Singapore - Continuous Auditing with Compliance as Code
DevOpsDays Singapore - Continuous Auditing with Compliance as CodeDevOpsDays Singapore - Continuous Auditing with Compliance as Code
DevOpsDays Singapore - Continuous Auditing with Compliance as Code
Matt Ray
 
Performancetestingjmeter 131210111657-phpapp02
Performancetestingjmeter 131210111657-phpapp02Performancetestingjmeter 131210111657-phpapp02
Performancetestingjmeter 131210111657-phpapp02Nitish Bhardwaj
 
Gatling Performance Workshop
Gatling Performance WorkshopGatling Performance Workshop
Gatling Performance Workshop
Sai Krishna
 
How to build Simple yet powerful API.pptx
How to build Simple yet powerful API.pptxHow to build Simple yet powerful API.pptx
How to build Simple yet powerful API.pptx
Channa Ly
 
DevSec Delight with Compliance as Code - Matt Ray - AgileNZ 2017
DevSec Delight with Compliance as Code - Matt Ray - AgileNZ 2017DevSec Delight with Compliance as Code - Matt Ray - AgileNZ 2017
DevSec Delight with Compliance as Code - Matt Ray - AgileNZ 2017
AgileNZ Conference
 
Protocol
ProtocolProtocol
Protocol
m_bahba
 
Rest Api Performance Testing with JMeter and EC2
Rest Api Performance Testing with JMeter and EC2Rest Api Performance Testing with JMeter and EC2
Rest Api Performance Testing with JMeter and EC2
Maneesh Srivastava
 
Creating Great REST and gRPC API Experiences (in Swift)
Creating Great REST and gRPC API Experiences (in Swift)Creating Great REST and gRPC API Experiences (in Swift)
Creating Great REST and gRPC API Experiences (in Swift)
Tim Burks
 

Similar to Productivity Acceleration Tools for SOA Testers (20)

Integration Testing as Validation and Monitoring
 Integration Testing as Validation and Monitoring Integration Testing as Validation and Monitoring
Integration Testing as Validation and Monitoring
 
POST/CON 2019 Workshop: Testing, Automated Testing, and Reporting APIs with P...
POST/CON 2019 Workshop: Testing, Automated Testing, and Reporting APIs with P...POST/CON 2019 Workshop: Testing, Automated Testing, and Reporting APIs with P...
POST/CON 2019 Workshop: Testing, Automated Testing, and Reporting APIs with P...
 
Writing Acceptance Tests Using Fitnesse
Writing Acceptance Tests Using FitnesseWriting Acceptance Tests Using Fitnesse
Writing Acceptance Tests Using Fitnesse
 
359686888-presentationJMeter-ppt.ppt
359686888-presentationJMeter-ppt.ppt359686888-presentationJMeter-ppt.ppt
359686888-presentationJMeter-ppt.ppt
 
QSpiders - Presentation JMeter
QSpiders - Presentation JMeterQSpiders - Presentation JMeter
QSpiders - Presentation JMeter
 
Rest assured
Rest assuredRest assured
Rest assured
 
WSO2 API Microgateway for Easier Development and Greater Scalability
WSO2 API Microgateway for Easier Development and Greater ScalabilityWSO2 API Microgateway for Easier Development and Greater Scalability
WSO2 API Microgateway for Easier Development and Greater Scalability
 
Mykola Kovsh - Functional API automation with Jmeter
Mykola Kovsh - Functional API automation with JmeterMykola Kovsh - Functional API automation with Jmeter
Mykola Kovsh - Functional API automation with Jmeter
 
Performance testing jmeter
Performance testing jmeterPerformance testing jmeter
Performance testing jmeter
 
InterConnect 2016 Java EE 7 Overview (PEJ-5296)
InterConnect 2016 Java EE 7 Overview (PEJ-5296)InterConnect 2016 Java EE 7 Overview (PEJ-5296)
InterConnect 2016 Java EE 7 Overview (PEJ-5296)
 
Servlet
ServletServlet
Servlet
 
Structured Functional Automated Web Service Testing
Structured Functional Automated Web Service TestingStructured Functional Automated Web Service Testing
Structured Functional Automated Web Service Testing
 
DevOpsDays Singapore - Continuous Auditing with Compliance as Code
DevOpsDays Singapore - Continuous Auditing with Compliance as CodeDevOpsDays Singapore - Continuous Auditing with Compliance as Code
DevOpsDays Singapore - Continuous Auditing with Compliance as Code
 
Performancetestingjmeter 131210111657-phpapp02
Performancetestingjmeter 131210111657-phpapp02Performancetestingjmeter 131210111657-phpapp02
Performancetestingjmeter 131210111657-phpapp02
 
Gatling Performance Workshop
Gatling Performance WorkshopGatling Performance Workshop
Gatling Performance Workshop
 
How to build Simple yet powerful API.pptx
How to build Simple yet powerful API.pptxHow to build Simple yet powerful API.pptx
How to build Simple yet powerful API.pptx
 
DevSec Delight with Compliance as Code - Matt Ray - AgileNZ 2017
DevSec Delight with Compliance as Code - Matt Ray - AgileNZ 2017DevSec Delight with Compliance as Code - Matt Ray - AgileNZ 2017
DevSec Delight with Compliance as Code - Matt Ray - AgileNZ 2017
 
Protocol
ProtocolProtocol
Protocol
 
Rest Api Performance Testing with JMeter and EC2
Rest Api Performance Testing with JMeter and EC2Rest Api Performance Testing with JMeter and EC2
Rest Api Performance Testing with JMeter and EC2
 
Creating Great REST and gRPC API Experiences (in Swift)
Creating Great REST and gRPC API Experiences (in Swift)Creating Great REST and gRPC API Experiences (in Swift)
Creating Great REST and gRPC API Experiences (in Swift)
 

More from WSO2

Accelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with PlatformlessAccelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with Platformless
WSO2
 
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital TransformationWSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2
 
architecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdfarchitecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdf
WSO2
 
Driving Innovation: Scania's API Revolution with WSO2
Driving Innovation: Scania's API Revolution with WSO2Driving Innovation: Scania's API Revolution with WSO2
Driving Innovation: Scania's API Revolution with WSO2
WSO2
 
Less Is More: Utilizing Ballerina to Architect a Cloud Data Platform
Less Is More: Utilizing Ballerina to Architect a Cloud Data PlatformLess Is More: Utilizing Ballerina to Architect a Cloud Data Platform
Less Is More: Utilizing Ballerina to Architect a Cloud Data Platform
WSO2
 
Modernizing Legacy Systems Using Ballerina
Modernizing Legacy Systems Using BallerinaModernizing Legacy Systems Using Ballerina
Modernizing Legacy Systems Using Ballerina
WSO2
 
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2
 
WSO2CON 2024 Slides - Unlocking Value with AI
WSO2CON 2024 Slides - Unlocking Value with AIWSO2CON 2024 Slides - Unlocking Value with AI
WSO2CON 2024 Slides - Unlocking Value with AI
WSO2
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
WSO2
 
Quantum Leap in Next-Generation Computing
Quantum Leap in Next-Generation ComputingQuantum Leap in Next-Generation Computing
Quantum Leap in Next-Generation Computing
WSO2
 
WSO2CON 2024 - Elevating the Integration Game to the Cloud
WSO2CON 2024 - Elevating the Integration Game to the CloudWSO2CON 2024 - Elevating the Integration Game to the Cloud
WSO2CON 2024 - Elevating the Integration Game to the Cloud
WSO2
 
WSO2CON 2024 - OSU & WSO2: A Decade Journey in Integration & Innovation
WSO2CON 2024 - OSU & WSO2: A Decade Journey in Integration & InnovationWSO2CON 2024 - OSU & WSO2: A Decade Journey in Integration & Innovation
WSO2CON 2024 - OSU & WSO2: A Decade Journey in Integration & Innovation
WSO2
 
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open SourceWSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2
 
WSO2CON 2024 Slides - Open Source to SaaS
WSO2CON 2024 Slides - Open Source to SaaSWSO2CON 2024 Slides - Open Source to SaaS
WSO2CON 2024 Slides - Open Source to SaaS
WSO2
 
WSO2CON 2024 - Does Open Source Still Matter?
WSO2CON 2024 - Does Open Source Still Matter?WSO2CON 2024 - Does Open Source Still Matter?
WSO2CON 2024 - Does Open Source Still Matter?
WSO2
 
WSO2CON 2024 - IoT Needs CIAM: The Importance of Centralized IAM in a Growing...
WSO2CON 2024 - IoT Needs CIAM: The Importance of Centralized IAM in a Growing...WSO2CON 2024 - IoT Needs CIAM: The Importance of Centralized IAM in a Growing...
WSO2CON 2024 - IoT Needs CIAM: The Importance of Centralized IAM in a Growing...
WSO2
 
WSO2CON 2024 - WSO2's Digital Transformation Journey with Choreo: A Platforml...
WSO2CON 2024 - WSO2's Digital Transformation Journey with Choreo: A Platforml...WSO2CON 2024 - WSO2's Digital Transformation Journey with Choreo: A Platforml...
WSO2CON 2024 - WSO2's Digital Transformation Journey with Choreo: A Platforml...
WSO2
 
WSO2CON 2024 - Software Engineering for Digital Businesses
WSO2CON 2024 - Software Engineering for Digital BusinessesWSO2CON 2024 - Software Engineering for Digital Businesses
WSO2CON 2024 - Software Engineering for Digital Businesses
WSO2
 
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2
 
WSO2CON 2024 - Designing Event-Driven Enterprises: Stories of Transformation
WSO2CON 2024 - Designing Event-Driven Enterprises: Stories of TransformationWSO2CON 2024 - Designing Event-Driven Enterprises: Stories of Transformation
WSO2CON 2024 - Designing Event-Driven Enterprises: Stories of Transformation
WSO2
 

More from WSO2 (20)

Accelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with PlatformlessAccelerate Enterprise Software Engineering with Platformless
Accelerate Enterprise Software Engineering with Platformless
 
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital TransformationWSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
 
architecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdfarchitecting-ai-in-the-enterprise-apis-and-applications.pdf
architecting-ai-in-the-enterprise-apis-and-applications.pdf
 
Driving Innovation: Scania's API Revolution with WSO2
Driving Innovation: Scania's API Revolution with WSO2Driving Innovation: Scania's API Revolution with WSO2
Driving Innovation: Scania's API Revolution with WSO2
 
Less Is More: Utilizing Ballerina to Architect a Cloud Data Platform
Less Is More: Utilizing Ballerina to Architect a Cloud Data PlatformLess Is More: Utilizing Ballerina to Architect a Cloud Data Platform
Less Is More: Utilizing Ballerina to Architect a Cloud Data Platform
 
Modernizing Legacy Systems Using Ballerina
Modernizing Legacy Systems Using BallerinaModernizing Legacy Systems Using Ballerina
Modernizing Legacy Systems Using Ballerina
 
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
WSO2CON 2024 - Unlocking the Identity: Embracing CIAM 2.0 for a Competitive A...
 
WSO2CON 2024 Slides - Unlocking Value with AI
WSO2CON 2024 Slides - Unlocking Value with AIWSO2CON 2024 Slides - Unlocking Value with AI
WSO2CON 2024 Slides - Unlocking Value with AI
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
Quantum Leap in Next-Generation Computing
Quantum Leap in Next-Generation ComputingQuantum Leap in Next-Generation Computing
Quantum Leap in Next-Generation Computing
 
WSO2CON 2024 - Elevating the Integration Game to the Cloud
WSO2CON 2024 - Elevating the Integration Game to the CloudWSO2CON 2024 - Elevating the Integration Game to the Cloud
WSO2CON 2024 - Elevating the Integration Game to the Cloud
 
WSO2CON 2024 - OSU & WSO2: A Decade Journey in Integration & Innovation
WSO2CON 2024 - OSU & WSO2: A Decade Journey in Integration & InnovationWSO2CON 2024 - OSU & WSO2: A Decade Journey in Integration & Innovation
WSO2CON 2024 - OSU & WSO2: A Decade Journey in Integration & Innovation
 
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open SourceWSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
WSO2CON 2024 - Freedom First—Unleashing Developer Potential with Open Source
 
WSO2CON 2024 Slides - Open Source to SaaS
WSO2CON 2024 Slides - Open Source to SaaSWSO2CON 2024 Slides - Open Source to SaaS
WSO2CON 2024 Slides - Open Source to SaaS
 
WSO2CON 2024 - Does Open Source Still Matter?
WSO2CON 2024 - Does Open Source Still Matter?WSO2CON 2024 - Does Open Source Still Matter?
WSO2CON 2024 - Does Open Source Still Matter?
 
WSO2CON 2024 - IoT Needs CIAM: The Importance of Centralized IAM in a Growing...
WSO2CON 2024 - IoT Needs CIAM: The Importance of Centralized IAM in a Growing...WSO2CON 2024 - IoT Needs CIAM: The Importance of Centralized IAM in a Growing...
WSO2CON 2024 - IoT Needs CIAM: The Importance of Centralized IAM in a Growing...
 
WSO2CON 2024 - WSO2's Digital Transformation Journey with Choreo: A Platforml...
WSO2CON 2024 - WSO2's Digital Transformation Journey with Choreo: A Platforml...WSO2CON 2024 - WSO2's Digital Transformation Journey with Choreo: A Platforml...
WSO2CON 2024 - WSO2's Digital Transformation Journey with Choreo: A Platforml...
 
WSO2CON 2024 - Software Engineering for Digital Businesses
WSO2CON 2024 - Software Engineering for Digital BusinessesWSO2CON 2024 - Software Engineering for Digital Businesses
WSO2CON 2024 - Software Engineering for Digital Businesses
 
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
WSO2CON 2024 - Navigating API Complexity: REST, GraphQL, gRPC, Websocket, Web...
 
WSO2CON 2024 - Designing Event-Driven Enterprises: Stories of Transformation
WSO2CON 2024 - Designing Event-Driven Enterprises: Stories of TransformationWSO2CON 2024 - Designing Event-Driven Enterprises: Stories of Transformation
WSO2CON 2024 - Designing Event-Driven Enterprises: Stories of Transformation
 

Productivity Acceleration Tools for SOA Testers

  • 1. Productivity Acceleration Tools for SOA Testers Evanthika Amarasiri : Technical Lead - QA Nirodha Gallage : Senior Software Engineer - QA April 2013
  • 2. About WSO2 ● Providing the only complete open source componentized cloud platform - Dedicated to removing all the stumbling blocks to enterprise agility - Enabling you to focus on business logic and business value ● Recognized by leading analyst firms as visionaries and leaders - Gartner cites WSO2 as visionaries in all 3 categories of application infrastructure - Forrester places WSO2 in top 2 for API Management ● Global corporation with offices in USA, UK & Sri Lanka - 200+ employees and growing ● Business model of selling comprehensive support & maintenance for our products
  • 3. 150+ globally positioned support customers
  • 4. Agenda ● Advantages of using tools for SOA testing ● Choosing the right tool that matches your requirement ● Test Scenarios - soapUI - Apache JMeter ● Tips on tools
  • 5. Advantages of using tools & automation for testing ● No need to re-invent the wheel : Reduce time of writing client programs from scratch ● Reduces time on frequent recursive testing ● Saves time to utilize the specialized knowledge effectively; i.e. to do exploratory testing ● Reduces test execution time : Takes more time if done manually ● Helps to release early & release often ● Reduces the possibility of missing test scenarios ● Ability to do dynamic data driven testing
  • 6. Advantages of using tools & automation for testing Contd... ● Ability to do load/performance testing ● Can generate result summaries and reports easily ● Ability to integrate test suites in build systems and trigger automatically
  • 8. soapUI - What does it support? ● Automated request generation : i.e. Generate SOAP request messages when WSDL is provided ● Ability to validate responses : i.e. assertions ● Support for QoS : i.e. Security, MTOM ● Ability to simulate service providers; i.e. mock services ● Ability to do performance testing ● Supports multiple protocols & message types : i.e. HTTP, HTTPS, REST, JMS, JSON
  • 9. Examples with soapUI ● Web Testcase support ● Invoking secured web services with HTTP basic authentication ● Invoking a web services secured with asymmetric binding policy ● Assertions for responses ● Sending HTTP chunk encoded messages ● Executing soapUI test suites/test cases in headless mode ● Testing RESTful APIs
  • 10. Web Testcase support ● Allows to test solutions without ?wsdl ● Invoke simple HTTP methods; i.e. GET, POST, etc on different services within the same project.
  • 11. Basic Authentication An example Service Provider Service Consumer Service A Service B <GET https://192.168.217.1: 9443/services/HelloService/greet?name=SoapUI HTTP/1.1 Accept-Encoding: gzip,deflate Authorization: Basic ZXZhbjplZWVlZWU= Service C Host: 192.168.217.1:9443 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.1.1 (java 1.5)
  • 12. Signing SOAP messages ● Asymmetric binding - message security is provided using asymmetric keys E.g.: public keys. Client signs the message from his private key and encrypts from server's public key Server signs the message from his private key and encrypts from client's public key Server's Client's Client's Server's public key private key public key private key - assures confidentiality, integrity and the non-repudiation
  • 13. Increase raw request/response size When raw view does not show large messages, configure UI settings ... ... and it will increase - size of raw request messages - size of raw response messages
  • 14. Assertions ● Validates responses ● Added to test steps ● Provides different types of assertions; assertions to be done on response message, for HTTP status codes, SOAP faults Add Assertions
  • 15. Sending chunked-encoded requests ● Content-Length - The length of the request body in octets POST /services/Axis2Service HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: text/xml;charset=UTF-8 SOAPAction: "urn:echoInt" Content-Length: 3782 Host: 127.0.0.1:9764 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.1.1 (java 1.5) ● Chunked - Messages are sent in chunks POST /services/Axis2Service HTTP/1.1 Accept-Encoding: gzip,deflate Content-Type: text/xml;charset=UTF-8 SOAPAction: "urn:echoInt" Transfer-Encoding: chunked Host: 127.0.0.1:9764 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.1.1 (java 1.5)
  • 16. Headless mode compatibility of soapUI ● Windows ○ testrunner.bat -s Axis2Service_TestSuite -r -f C:soapUIlogsresponse -I C:soapUIprojectsmy_soapui-project.xml ● Linux ○ testrunner.sh -s Axis2Service_TestSuite -r -f /opt/soapUI/logs/response -I /opt/soapUI/projects/my_soapui-project.xml ● Parameter list s the test suite to run c the test case to run r prints summary report l ignore errors and continue f folder to which test results should be saved
  • 17. Testing RESTful APIs ● Scenario 1 - Invoke Login API of WSO2 API Manager
  • 18. In which situations we can use JMeter? ● To simulate multiple user access/ load tests ● For data driven testing ● To analyze & measure performance of services ● To validate responses; i.e. assertions ● To create test suites with real world scenarios which involves executing multiple services sequentially or in parallel ● Support for different transport protocols; i.e. HTTP, HTTPS, JMS, MAIL, FTP, JDBC, LDAP etc
  • 19. Testing examples with JMeter Scenario 1 : Testing a web service with dynamic data 1. Send SOAP requests to a Stock Quote web service 2. Need to send dynamic data inputs in the SOAP request 3. Read the response and verify the response is valid 1. Send request to the Web Service 2. Send requests with dynamic inputs Stock Quote service (Currency conversion rate)
  • 20. Testing examples with JMeter Scenario 1 : What JMeter components you will need? ● Thread Group ● Sampler > SOAP/XML-RPC Request ● Config Element > CSV Data Set Config ● Assertions > Response Assertion ● Listener > View Results Tree ● Listener > Aggregate Report o Dem
  • 21. Testing examples with JMeter Scenario 2 : Testing API's with WSO2 API Manager 1. Call the login API [REST] and acquire an access token 2. Use that access token to invoke the API 3. Read the response and verify the response is correct 1. Invoke Login API Login API (Access Token) 2. Invoke Stock Quote API with the Access Token Stock Quote API (Response)
  • 22. Testing examples with JMeter Scenario 2 : What JMeter components you will need? ● Thread Group ● Config Element > HTTP Cookie Manager ● Config Element > User Defined Variables ● Sampler > HTTP Request ● Config Element > HTTP Header Manager ● Post Processors > Regular Expression Extractor ● Assertions > Response Assertion ● Logic Controller > Loop Controller ● Listner > View Results Tree ● Listner > Aggregate Report o Dem
  • 23. Testing examples with JMeter Scenario 3 : Running JMeter scripts in 'Headless' mode ● Create it once.... Run it anywhere!!! ● All you need is a JMeter distribution a JRE installed and a command shell ● Linux : ./jmeter.sh -n -t /path/to/JmeterTest.jmx -l /path/to/resultsFile.jtl ● Windows : jmeter.bat -n -t pathtoJmeterTest.jmx -l pathtoresultsFile.jtl ● Use Shell/ Batch scripts to change test parameters and execute programmatically, for recursive test scenarios. Refer : http://nirodhawrites.blogspot.com/2012/06/how-to-run-jmeter-tests-in-non-gui-mode.html
  • 24. Tips... When sending http requests with Jmeter always select 'httpclient4' as the implementation for high load scenarios When doing load tests disable "View Results Tree", as it affects thread creation rate. Always keep test parameters like endpoints, IPs, ports etc as configurable variables For high load tests run the Jmeter tests in headless mode, and write the result to a .jtl file. You can open them later in JMeter UI, to check results summary, and performance figures. When measuring performance figures with load tests make sure only the client and server are running in their respective machines
  • 25. Tips... Other free external plugins are available for Jmeter ● Ant plugin http://www.programmerplanet.org/pages/projects/jmeter-ant-task.php Allows you to run JMeter script as an ANT task Creates reports ● Google plugin http://code.google.com/p/jmeter-plugins/ Generates new set of graphs for performance test Have some new throughput controlling components
  • 26. Q&A
  • 27. Engage with WSO2 ● Helping you get the most out of your deployments ● From project evaluation and inception to development and going into production, WSO2 is your partner in ensuring 100% project success