Loading

SOA Testing


SOA Testing:

SOA is an acronym for Service Oriented Architecture that provides a service which enables communication over the web via some communication protocol. SOA is a certain style of designing the web wherein a set of services provide certain functionalities.

'Services' can be thought of as loosely coupled functionalities having least dependency. A service can be thought of as an independent functionality such as filling online application for a bank account, viewing online bank statement etc. which are a complete individual functionalities independent of each other. Each service is self-sufficient and helps to fulfil various business needs.

SOA services are developed based on standard web languages like WSDL and XSD (XML Schema Definition).

SOA Lifecycle

An SOA lifecycle comprises of the following Steps:

  • MODEL:Business Requirement validations are done to balance current services and the desired service model requirements
  • ASSEMBLE:Apply necessary modifications in the service plan against the defined business policies
  • DEPLOY:Delivering quality services after testing functional, performance and security aspects
  • MANAGE:This is a continuous and consistent practice that involves tracking services stored in the registry and reporting their performance against defined SLA's

SOA Architecture:

SOA is designed as a complete structure that performs a wide range of operations. There's an interesting dimension to how SOA services are developed, is the technique of 'orchestration'. The technique is used by developers to establish an association among the various functionalities (services), using some tool, which lists the services along with their characteristics and the process for building an application with the help of these sources.

Service:

One can think of a SOA as an architecture for developing distributed application systems. What exactly do we mean by service in the context of an application?

Well a 'service' is precisely a logic that performs some operation or function that eventually delivers an outcome or result. Examples of such self-contained services are payment gateways, loan processing, weather reports etc. SOA services are generally available over the web using HTTP, that is, interaction among services are done using HTTP protocol. Each service is a complete functionality in itself.

Let us get a better insight into the architecture of SOA:

SOA Architecture

The architecture of SOA depicts the communication that takes place between the user and the system's backend components. The architectural breakdown is broadly classified at three levels - consumer, process and service.

  • At consumer level a user is accessing a website and wishes to opt for a service. He selects a service and begins to make payment for the same.
  • Now at the process level multiple operations occur simultaneously. The system authenticates the user credentials, locates his demography and invokes call to the payment gateway.
  • Finally, service level calls are made, that is, for each operation to be accomplished, there will be an appropriate service call to complete actions.

We often term SOA services as 'micro services' that are the most sought after services in today's world. Such services are pocket friendly means along with an advantage of providing an agility to the momentum of a company's business prospects. We simply need to integrate such services with a website so that it becomes a complete model for generating revenue for an enterprise.

Approach in SOA Testing:

By now we have acquired a clear understanding of how an SOA works, now let us shift focus on testing such applications.

SOA services are test upon integrating the different services or modules together, here's a glimpse:

Unit testing:

A unit or module is tested to verify the 'transformation logic'. So unit test transformation of SOA services can be done with XQuery or XSLT, post which the deviations in actual and expected results can be analysed using XMLUnit.

Integration testing:

In the context of SOA testing, the aim of integration testing is to assess the impact of interaction between the application and the backend services. The idea to check whether such an interaction produces an error and find a solution to the same.

A 'mock service' can be used in this scenario. A mock service is simply a replica of the actual service to be used, for example payment gateway service. Hence run the test suites to measure the performance of SOA service's integration.

Levels in SOA testing:

SOA test process follows a certain flow of tests, following a four step path to achieve the test objectives.

  1. Service level testing:The very initial task is to validate the services by mapping it to functional and non-functional requirements.
  2. Process testing:The process layer testing is to ensure that all components are working fine in collaboration with each other and deliver the desired result.
  3. End to End testing: To test whether the system structure designed as per consumer use is working as expected. That is the entire business flow of an application is tested.
  4. Regression testing:Regression suites are executed during testing to ensure that slight changes in the system does not break any portion of the application as a whole.

SOA Testing Tools:

Automation can ease the task of testing any application under consideration, though choice of an appropriate one is imperative. Here's a list of some of the most common types of SOA testing tools:

  • SOAP UI:The tool supports protocols like SOAP, REST, HTTP, JMS, JBC. Web service requests are invoked and request-response patterns are tracked and reported through inbuilt report tools.
  • iTKO LISA:LISA is a product suite from iTKO that enables regression, integration, load and performance testing.
  • HP Service Test:The tool supports interoperability testing by integrating JEE, AXIS and .NET environments. The best part of this tool is that it can store and manage huge amount of data and services.
  • Para Soft SOA Test: Developed by Parasoft, the tool is meant for API testing. Offers support for a range of features like web services, REST, JSON, HTTP, XML and facilitates unit, integration, functional, regression, security, performance and interoperability testing.
  • Apache JMeter:A product of Apache, it is meant for unit testing of JDBC connections, FTP, JMS, Webservices, HTTP. It is a load testing tool for measuring performance of an application.

Challenges in SOA Testing:

  • The impact of modularity:
    1. The challenge is to maintain consistency in performance of modules individually as well as in an integrated application
    2. More distributed any application is, more is the trouble in managing distributed assets
    3. A large number of services are difficult to manage, as the central idea of SOA is 'service'
  • Business perspective:
    1. Frequent updates are difficult to manage as they are bound to affect service and application level SLA's.
    2. Complexity is an inherent feature that is directly proportional to the size of an organisation, that is, bigger the company larger are the services which leads to management of huge amounts of data and services.

Summary:

SOA testing involves people, information and a process. Hence to summarise SOA testing, we would like to highlight some key points that shall guide the activities of the test engineers in a unified direction.

  • Begin with individual modules by testing their input and output
  • Segregate portions of logic and test their interaction
  • Gradually combine the smaller parts and perform an end-to-end testing

An SOA primarily deals with implementation of some business logic and the services act as a bridge between two or more entities, hence quality and consistent management of services eventually define the net worth of such a collaboration.