26 October 2008

Virtualization - Cost effective and Environment friendly

In the last few years, the hardware industry and its technological advancements are on par with software technologies. To be precise and honest, the hardware industry in fact outperformed the software industry by introducing so many features. In the past, particularly the processor manufacturers were focussed on increasing the clock frequency of the processors. The clock frequency saturation forced the processor designer to focus on other aspects to increase the processing power. The processor vendors used variety of other techniques such as hyper-threading to improve upon the processing power.

The recent day computers/hardware devices have more processing power and the hard truth is that less than 50% percent of the hardware resources are used on an average basis. In a normal day, the hardware irrespective of whether it is a desktop system, servers or servers in data center, all the resources are under utilized.

The pace of hardware advancement also forces organizations to spend considerable money on upgradation. But the worst part in upgrading is it that it soon becomes outdated within few months after the upgrade. The organizations spend hefty sum on upgrades. Particularly, the hardware upgradation may not be considered as investment but as running cost to maintain the existing services. By and large, there is no ROI for the upgrade. Also, after the upgrade there is greater possibility of throwing the old and outdated hardware. Having a lot of physical resources directly affects the manageability such as security and regularly maintaining the resources.

The next problem and most important one is energy. There has been consistent appeal from the entire humanity of conserving power. Not only that it leads to depletion of energy but also increases the operating cost. The fuel and energy prices are increasing day by day and the organizations are looking out opportunities to reduce cost on energy. The conservation of energy has twin advantages. First it reduces the operating cost and secondly it leads to Green revolution. But the more the hardware, the more it consumes power directly affecting the operating cost. Secondly, because of the large number of physical hardware, a lot of heat is generated and which once again increases the energy demand (spend time and effort to improve infrastructure for quick heat dissipation). The over consumption of energy is recurrent problem. To summarize, there are three main issues - low resource utilization, higher maintenance cost and higher energy consumption.

Considering all the above facts, Virtualization as a technology offers a lot edge. Virtualization is software abstraction layer allowing us to run multiple virtual operating systems in parallel. With virtualization one can run multiple virtual machines simultaneously and thus improving the resource utilization of physical resources. Since these virtual machine run on single physical server, it leads to energy conservation. Also, it reduces the hardware upgradation cost to a larger extent.

Apart from the main advantages, being a software layer, virtualization offers lot of features which increases the productivity. The entire virtual machine is stored as single file leading to easy archival. An important feature that must be mentioned is "Isolation". Each virtual machine is isolated (sandbox) and even the virtual machines running on the same machine need to communication through virtual network. This particular feature boosts the security of the virtual machines.

Virtualization is used in many areas such as storage virtualization, server virtualization, virtualizing application and also in software development lifecycle. Based on the research by Gartner, the virtualization market is expected to grow exponentially and there will be lot of organization showing interest for adopting virtualization.

Hope this article would have given an overview about virtualization. In the upcoming articles, we will discuss more on various virtualization products.

Please do share your feedback/comments.

Design Pattern - Introduction

If you are a software developer, your responsibilities include design, implementation and unit testing the software. Once the software released, the whole bunch of new issues suddenly creeps into your code and then on you will be running after each bug and trying to chase it down to death. In most of the cases, the bug wins and the developers lose. Sometimes, I used to think that there is an egoistic clash between bugs and developers both of them willing to fight till the last breadth. Irrespective of the honest effort, the bugs manifest in multiple forms - usability, functionality, performance, scalability and so many jargons. With current time to market pressures, the software community is pro-actively by changing the software development models - Agile, Iterative, Test Driven Development. These software development models give a framework to tackle the changes in requirements. These days it has become unwritten law to change the requirements, quite often. Even though, we have software development models that offer flexibility, doing the fundamental right will give you a lot more flexibility. Design Pattern is one such tool that helps by providing conceptual solution to common problems and thus decreasing the software development time. 

Design patterns are solutions to common problems. It is not a software tool, framework or library. Design Patterns are simple and effective ideas for common/repeated problems.  Since it is a concept, it can be reused anywhere in software design. The concept of design pattern must have be adopted by software development community taking an inspiration from architecture of buildings or civil engineering. The fundamental concepts and theories of building various types of buildings such as houses, roads, flyovers, auditoriums, cinema halls, communities and etc are same. For example, there are blueprints available to make various types of buildings based on the land terrain, climatic conditions and so many factors. But given a set of requirements, any experienced architect or civil engineer will be able to give you the plan for the building and when followed with fundamental concepts, the building will be made. So, the developers in software community also thought in similar lines and came out with classical ways of solving design problems. Hence, Design Patterns are solutions of common problem.

Like a blueprint, Design Patterns are template for complex problems. Once again going back to the example, the architect or civil engineer will know how to build buildings and what needs to be done. In similar way, Design Patterns are just ideas/concepts. They are not specific to a platform, programming language or an operating system. Design Patterns might have been used atleast millions of times by software developers and the concepts, principles are time tested. Hence most of the Design Patterns states which problem that it is trying to solve and of course the solution. In order to make things clear, apart from the intent and associated text, the design patterns are explained with the help of UML class diagrams.

Design Pattern makes our life easier. Say for example, someone comes to you and asks for "Can you tell the place where people go from one city to another, purchasing tickets. They will also wait on a platform for the vehicle containing a series of boogies pulled by an engine powered by electricity or diesel?" Won't you run from him?. The job would be much easier the person asks for the way to railway station. In software development, without design patterns, the developers need to beat around the bush to express what is there in their mind and Design Patterns makes communication fast, crisp and clear. So, Design Patterns are communication tool.

Having discussed about the design patterns, the rest of the article discusses various types of design patterns. Based on the applicability, the design patterns can be categorized into three main types. They are

1. Creational Patterns which primarily deal with how the objects are created and how to create objects based on a specific situation. The examples of creational patterns are Singleton, Factory, Prototype.


2. Behavioral Patterns identifies common communication patterns between objects and offers flexibility in performing the communication. The examples are State, Strategy, Observer, Chain of Responsibility.


3. Structural Patterns deals with realization of relationships among objects. Decorator, Adapter and Flyweight patterns are examples of structural patterns.

In this blog, we saw the basics of design pattern and its types. In upcoming blogs we shall see about specific design pattern with real world examples, class diagrams and how to apply these concepts into software development.

Summary:
1. Design Patterns are solution to common and repeated problems
2. Design Patterns are not library, API or framework or source code
3. Design Patterns help developers to communicate fast and to the point.
4. Creational, Structural and Behavioral are three types of Design Patterns