Tuesday, October 18, 2011

SOA Service Cost Estimation Modeling and Approach


Introduction

Cost estimation in Service Oriented Architecture (SOA) based software development efforts is more complex than other traditional non-distributed and silo-ed (web, desktop based rich internet applications etc) applications. In SOA projects, services are generally built using well-defined, reusable, and loosely coupled set of components. Services also comprise of logically grouped functionality and they are exposed to the rest of the world via a contract (Web Service WSDL or JMS Message Queues for example).

The loose coupling brings complexity when it comes to cost estimation as the project teams have to understand and establish all the component level relationships and dependencies involved. Because of the resulting uncertainty, traditional models such as COCOMO or Function Point Analysis cannot necessarily be sufficient for estimating costs of building SOA services. Cost estimation for developing building blocks of services must be done at the component level in order to truly reflect the activities of development involved. For combined components or choreographed services costs must be re-composed in a hierarchical form.

In this study, we propose estimation of costs for SOA services in a recursive fashion. For each component, a detailed work breakdown structure (WBS) that includes analysis, design, development, testing, deployment, integration, support and maintenance activities will be developed. Finally, we propose to include runtime and service level agreement (SLA) management costs if hosting is involved. Further, based on the timeline involved uncertainty in the requirements may be induced because of scope creep once the costs are calculated. For SOA services with longer requirement gathering periods and in whose cases where requirements are subject to change, we propose an additional factor increase in the time and cost of developing the project. However, this factor increase shall be determined directly by the operational managers that are experienced in running the operations within the organization. 

Estimation and Modeling Approach

Classification of SOA services is vital to any SOA governance at organization level as this helps to establish the types of services that the management is interested in investing. Among other types, few examples include data services, infrastructure services, and business services. Other technical categories include web services, file transfer services, identity and access services. Once the categories are finalized they are also governed (managed for changes or version controlled) in a corporate registry. While these types are applicable for implementation and development, we propose to use a different classification model for developing cost estimates. These categories include:
  1. New Services – A service that will be developed from scratch.
  2. Migrated Services – A service that already exists in the organization or its partners, but needs to be elevated to a different standard or technology stack.
  3. Integrated or Choreographed Service – A service that is integrated with yet another service in order to implement larger set of functionality without having to develop from scratch.

Service development may involve one or more aforementioned categories. Project teams (architects and business analysts) must undertake a discovery effort and determine relevant categories before developing a WBS for estimating costs. Once the determination is made, an effort must be put in place for determining all significant components. Every organization adopts a methodology for deriving a list of components. These methodologies could be used for this. We used Service Component Architecture (Apache Tuscany, IBM and Oracle SCA for various projects) reference modeling very effectively for this. A high level approach for achieving this is described in the graphic below:

Figure 1: SOA Service Breakdown Structure for Cost Estimation

Once a detailed list of components (BPEL Human Tasks, Web Services, JMS Queues, XSL Transformations, Security Access Control Lists etc) is developed we propose that project teams develop a high level or detailed (depending on the phase of the project) WBS as described below. The costs are primarily divided into two cost categories:
  1. SDLC costs for software implementation
  2. Hardware runtime costs (In this example a 5 year time period is used for deriving runtime operating costs and this needs to be adjusted by senior executive stakeholders on the project)

Tasks listed below can be categorized into the following:
  1. service discovery tasks – break down of components
  2. component design and architecture tasks
  3. component development tasks
  4. component migration tasks
  5. service integration tasks
  6. Other SDLC activities
 Figure 2: Cost Estimation Spreadsheet

Significant terms in the WBS can be elaborated as detailed below:
  • Component – List of components and other Software Development Lifecycle (SDLC) items that are identified through modeling efforts
  • High level Categorization for cost components – Software for capturing SDLC costs and Hardware for operational runtime costs
  • Tasks – Detailed listing of tasks that are required to develop each component
  • LOE – Level of effort either simply estimated by subject matter experts or from models such as the PERT
  • Risk – A factor that must be derived by the architect or the project manager based on knowns and unknowns.
  • Total LOE – Adjusted LOE per risk factors
  • Cost per Hour – Determined by senior executive managed of responsible organization
  • CPU Hours – Determined by the architect and software vendor for a given hardware, estimated payloads and SLAs
  • Costs per CPU Hour – Determined by the hosting provider based on their infrastructure management costs
  • Total Cost – Determined primarily by (Total LOE * Cost per Hour) for software SDLC and (CPU Hours * Costs per CPU Hour)
  • Overall Total Cost – Sum of all costs involved

Conclusion and Extended Analysis

Cost estimation of SOA services is complex because of the nature of loose coupling and complexity involved. We developed an approach to address the complexity by breaking down the list of activities involved that will incur significant costs. This breakdown approach should be inline with SOA itself without which significant deviation of costs may occur in estimation. Service component architecture and modeling is a prominent approach that is used by SOA practitioners for deriving components in a SOA service. In this study we propose to use this approach, however this can be supplemented and tailored using other approaches if any are adopted by the organization. In particular, tailoring should be applied for incorporating specific risks at the organization or group level if any. In addition to the methodology and development of work breakdown structure described above, we propose that a schedule with timeline and resources loaded be developed. This effort will produce a more reliable cost overall as it will include the resource management (matrix or vertical) aspects into the overall cost model.