Understanding Software Architecture

Raihan Armon
3 min readMay 24, 2021

How it works and why we need to use it consistently

Definition
Software Architecture is a structure derived from a system’s software mechanism that is responsible for controlling a bunch of components in one’s system. Software Architecture has the ability to quite easily show us the complexity of a system as a whole. This complexity is seen by the connections between components that is described by the Software Architecture

Why is it important?
In building a software, it is very important for us to be able to correctly identify a architectural structure that correctly suites our codes needs. “Why do we need to do this?” you might ask, the reason for this is that the proper architecture can greatly affect how well certain aspects perform such as higher quality CPU performance, better security, and it also becomes easier to maintain. Developers can waste a lot of time fixing a wrongly chosen architecture because of it’s long term effects on the system as a whole, so it is very important that we do our research before making such an important decision

Types of Architecture
There are of course many versions of architectural structures that you can use but to keep it simple I’m just gonna give you three of the most popular

  1. Event Driven Architecture
    This architecture does exactly what the name implies which is that it does all the production, detection, consumption and also react only when a specific event happens. There is a component in this architecture that will take in all the data that is coming in and pass it on to the other parts of the system so it can be used.
  2. Layered Architecture
    This architecture splits programs into smaller subgroups called layers. Each layer has its own level and they are individually unique to each other. The structure ends up being that the lower layers prop up or work to help provide for the upper layers.
  3. Microservices Architecture
    Complexity in a software mostly depends on the size of the program as a whole. This means that the bigger the program, the more complex the code becomes. What microservices does is help you manage this one giant program by splitting it into tinier services, also known as microservices. These services are separate so they must communicate with each other in order to function properly

How exactly do we choose the correct architecture?
From those 3 most popular choices I’m going to outline each of their individual strengths and weaknesses to help you choose the one that fits your projects needs the most! Remember do your research and learn thoroughly about which structure you wish to implement.

  1. Event Driven Architecture
    This is mainly used for a system with an asynchronous data flow and code/data flow that isn’t overly complex. Each data block only interacts with only few modules. So if your code is on the relatively more simple and smaller side, this might be just the thing you’re looking for.
  2. Layered Architecture
    Used for applications that need to be finished in a small amount of time while at the same time fulfill the necessary requirements such as maintainability and testing. So for all you deadliners this is perfect for you.
  3. Microservices Architecture
    Used mainly for websites and big applications that have separated features and actions. Also super helpful when used by a development team with a lot of people.’

Implementation in PPL
For my University project my group has implemented microservices in the pattern of Model-View-Template (MVT). The difference between MVC (Model-View-Controller) and MVT here is the Django itself does the work done by the controller part in the MVC architecture. Django does this work of controller by using templates. Precisely, the template file is a mixture of HTML part and Django Template Language also known as DTL. For a clearer example here is a diagram on how exactly that process is done.

The Template handles the UI/UX part of the website which is the design of the html. The model is where all the necessary data of the website is stored (users, passwords, dates, etc). Finally, the View is there as a connector between the model and template, the view gets the data from the model so that it can be displayed on the html in template. Django works as the controller that actually gets the url so that the application can detect what exactly the user has done/interacted with.

--

--