Too many times I have seen brash young developers put aside the thoughts of having a good architecture in lieu of quick and fast software development. So, I would like to express what is Software Architecture and how it can turn a good software into a great and maintanable one.
What is Architecture Actually?
I have gone through some definitions but the following matches my take on Architecture:
The software architecture of a system is the set of structures needed to reason about the system, which comprise software elements, relations among them, and properties of both.
So, what is necessary to become a successful Architect?
I believe the skill first and fore-most a Software Architect should have is
Good understanding of the business problem domain, followed by
a) General strategies and tactics
b) Fundamentals of abstraction and modeling both business and technical concepts
c) How to assess the trade-offs involved when recommending an approach
And now his/her duties - nicely illustrated by the image that follows:
And Now something
CRUCIAL : Software Architects must also be adept at the Social Skills -> Soft Skills
Soft Skills? Seriously?
Yes, and that includes
1) Communication - Frequently communicate between the management and the team is to be guided.
2) Negotiation – Good understanding about what is possible and what is not given the context
3) PERSUASION to influence,
4) Need to know how to communicate what you are thinking so everyone understands them.
Now the million dollar question
WHY ARCHITECTURE ?
I would be short and succinct with this, and this is solely based on my experience:
i) Integrate New Features Easily
ii) Maintenance &Sustainability
iii) Team Work Through Modularization
iv) Pinpoint Potential Problem Areas
v) The possibility of entertaining Multiple Platforms
Prerequisites to great Architecture:
Firsly, Clarity of Intention – Clear idea in mind what you are about to do.
What that drives you towards is Reflection of that Intention in Coding, so others can (with a little bit of effort) understand what you have in mind.
And not to say the least THINK BEYOND THE LANGUAGE/TOOL
Now we are ready to get started, but First:
Improve day to day coding habits, let me count them down for you -
one: Lines and Lines and Lines of Comments – NO!!
two: Meaningful Variable and Class Names, Method and Function Names
-> Which Makes Sense and IS SUCCINCT and Precise
three: Short Notes as Comments on critical junctures
four: Tabs, Formatting and Indentation
five: PRACTICE BASE LEVEL ALGORITHMS AND HAVE GOOD GRASP ON DATA STRUCTURES (BE PATIENT)
What consitutes a good Architecture
Believe it or not - a layerd cake
The ingredients of the cake (Taking a leaf out of MSDN article mentioned in the above source):
1. Simplicity means you don't do in ten lines what you can do in five!! There is less to go wrong.
2. Readability means what it says: that others can read your code
3. Modularity means your program is built like the universe. Good programs erect large systems from smaller ones, which are built from even smaller building blocks.
4. Layering means that internally, your program resembles a layer cake. The app sits on the framework sits on the OS sits on the hardware. Modules and layers are defined by APIs, which delineate their boundaries. Thus, design is critical.
5. Design means you take time to plan your program before you build it. APIS should be codified => Arranged according to a plan or a system
Yes, it appears I copied from the article blindly and put up a compressed version of it here, but what can I do if my experience matches so closely with the points made in the article.
ICING ON THE CAKE
Efficiency & Elegance
The simple yet beautiful looking equation is the theory of General Relativity by the great Albert Einstein. Such a powerful theory yet can be expressed so eloquently. The elegance is the icing that makes the layers of the architecture maintanable and inspiring to look at, even after years.
And whenver there is elegance, chances are high the system is efficient.
As we take care of the basic factors of Software Architecture and design, we have to give some thoughts about the elegance aided by efficiency.
Have I ever used what I said in reality?
Yes, I have. I am involved in the designing of a social media site (lokkhi.io) for the Bangladeshi Community, a community I proudly belong to. And inorder to address popular user demands, we have tried to follow the cake based approach in developing a core API engine and the outer layers. It is possible to use this site for chatting, video conferencing, file transfer through web and native android app. The IOS based app is also on its way and should hit the market soon.
Not here to brag, but to show a practical example how we achieved it, here is an illustration:
And while we are at it, we try to be very careful about the pitfalls to Software Architecture and Design Patterns, which namely are
b) OVER OPTIMIZATIONS WITHOUT VERIFICATION
c) OVER-INHERITENCE & HIERARCHY
The point of the article was to stress the fact that no good sustainable development can last without the application of good Software Architecture Design. I am hopeful the possible success of sites such as https://lokkhi.io would be a good testimony behind this in days to come.
Article Submitted: 6th Feb, 2015