Software Architecture and Tech Terminology

Rochak Agrawal
13 min readDec 31, 2022

--

While running tech remediation projects, there are numerous terms that I have come across.

I will try to summarize them here. Please leave your comments if you feel I have missed anything. I give credit to a number of excellent resources on the web for strengthening my understanding

Thinking Big Picture (Software Architecture)

How do you build an application architecture?

Start with the functional requirements, i.e., the business problem you are trying to solve, and then move on to the non-functional requirements (e.g., need for availability, scalability, etc.) that drive the choice of platform.

From left to right in the image below, these are the components you would need:

User requests (https) come from mobile devices or the web. We must serve these with static content (HTML, CSS, and images) from the location closest to the user.

  1. CDN traffic — use something like CloudFront to direct the user to the closest datacenter (availability zone) which host copies of your components.
  2. Reverse proxy — use something like Nginx, which is a web server and can serve static content like HTML/CSS and provide caching service. Since it acts as a reverse proxy, it can further direct queries with more dynamic content needs inside. Nginx (and Apache web) also have the capability of serving dynamic content using scripting languages like Python, Perl and PHP (usually through another backend). They can only do low level of business logic implementation. Higher level of business logic implementation will require a full-scale programming language like Java and a web server that has java servlet engine support. Note requests for images/pictures don’t go to API gateway. Since the pictures are publicly hosted on S3/Azure Blob, connections go directly from user’s client machine to download these images.
  3. API gateway — requests from Nginx will be captured by an API gateway. Consider an API gateway to be a specialized compute server that efficiently routes requests to the appropriate microservice. If needed you may have a load balancer in front of your API. The API Gateway helps with things like authentication, rate limits etc.
  4. Microservices — Consider microservices to be a combination of a compute server and a database that implements a discrete piece of business logic. E.g. Orders, Checkout etc. Each microservice can have its own selection of database (RDMS, NoSQL) to best suit its purpose. You can have an ELB (elastic load balancer) in front of your microservice compute server. Very likely you will be running multiple instances of your compute server (using auto scaling technology for e.g. or through Kubernetes containers). For databases — if the data is large, you can partition the database into shards. For availability and avoiding single point of failure, the database should be replicated constantly. You have an option of cold backup — i.e. storing data in offline tapes, or warm backup — i.e. storing data in replicated DB or hot backup — i.e. writing data multiple times to multiple DB’s at the same time and therefore avoiding replication completely.
  5. Message Brokers — in order to communicate efficiently between microservices, it’s necessary to use something like a message queue to allow asynchronous communication. This way one microservice doesn’t even need to know the existence of the other.
    How does MQ work: In general, TIBCO EMS clients produce messages and send them to the TIBCO EMS Server. Topics refers to pub/sub model and queues refer to point to point communication. Similarly, TIBCO EMS clients can connect to the TIBCO EMS Server and declare an interest in a particular queue or topic on that server. In doing so, it can consume messages that have been produced by another TIBCO EMS client.
  6. Notification service — you may use something like Amazon SNS to read these messages brokers to provide constant notifications (push/email) back to the user.

A high-level picture diagram of this can look something like this

Thinking lower level (what technology you use to build each of the lower components)

Let's start with servers. There are a few main kinds of servers.

  1. Web servers — like Nginx and Apache Web — they provide static content as well as dynamic content from scripting languages to implement some amount of business logic. These servers can also have a database running on them or connect to another server with a database.
  2. Application servers — this is the [more common] definition of server of processing business logic. In addition to web servers, they have engines to run a complete programming language (e.g. Java) inside it. For e.g. Tomcat or Jetty are popular ‘web containers’ that have Java servlet engine to run java code and presentation layer to render JSP page. They can also return JSON/XML for a restful app. A restful app is one that allows querying of objects e.g. movies inside a movie library. They differ from RPC — remote procedure call, which is a way for a backend service to run a method/function in another backend service e.g. run a function to debit the credit card of a user.
    Spring library is a common library with reusable content that developers use in addition to tomcat to speed up development . This entire combination is free and open source. Struts is another Apache competitor for developing web applications on the Java framework. Paid alternatives include IBM WebSphere, which combines web containers, libraries, spooling, caching, database connectivity, and other features required by developers. It’s a complete package mainly used for enterprise, traditional standalone applications.. An alternative to IBM WebSphere is Java Spring Boot which has the Sping Library + web containers (Tomcat, Jetty) to provide a free alternative esp. for microrservices architecture.
    Another popular technology is Node.JS. This allows JavaScript to be used in the server. It is primarily used as an HTTP web server for front-end JavaScript (e.g., Angular or React) web apps, and it is effective at sending IO requests to backend databases or services. Node. JS does little CPU computing itself.
    A picture diagram of how it looks like is here
  1. Database Servers — as the name implies this server hosts the database. database can be RDMS like MySQL or NoSQL — database that support partitioning and usually have key/value pair or document storage techniques (e.g. MongoDB)

Packaging: To speed up replication, a common approach is to “containerize” the application part of it. A container (e.g., using Docker) packages all application content on top of the OS. This combines the JVM (also known as the JDK) with web containers and application code (e.g., JAR files) in a container image. Another host OS only needs to install a container runtime environment and can now run any image (even if it was originally created for another OS ). The container runtime environment takes care of the translation of system calls between different operating systems.

Each microservice combination, i.e., application servers, will be made into a container. The database server can also be made into a container. For replication and creating multiple containers quickly, a service like “Kubernetes” is used for container orchestration. Depending on the needs, it can quickly create multiple containers, monitor which one is up or down, and support rolling upgrades without downtime. The way Kubernetes works is that it will put each container in its own POD (plus some ancillary files) and assign the POD an IP address. Pods talk to each other on the Kubernetes network through this IP address (which is different from the server IP address). In effect, the whole application and database layers in Kubernetes are abstracted from the underlying infrastructure. DevOps uses Kubernetes for operating the product.

Therefore, in the big picture, it would look like this: each microservice is made of multiple containers inside multiple pods—one each for the application server and database server. Kubernetes does the job of load balancing between these pods. The front-end web server can also be containerized for deployment in multiple geographies for CDN pickup.

Common Terminology

So now let’s talk about some common terminology in the context described above.

DevOps combines "develop”(one who writes and develops the code) and "operations” (one who operates the product in production). Operations is different from production support. Operations is “pro-active” that is monitoring, deploying,scaling while production is “reactive” looking at incident tickets, resolutin etc. In a modern tech stack, once you deploy something into production, you need a team to keep an eye on that application at all times. Monitoring them for alerts, adding capacity, scaling technology, and for deployment of the application This work is done by Operations [see image below in the appendix]. They also configure any servers that are necessary for scaling. They can automate configuration using CHEF, Ansible, and Puppet, which have command-line scripts to automate configuration. Operations heavily use Kubernetes for management.

Apache Web Server — A web server that runs static HTML content, PHP code, or scripting languages such as Perl or Python

IBM WebSphere and Oracle WebLogic are full-scale application servers that run Java servlets. It competes with Tomcat but is better as it implements more APIs from the Java EE stack and provides other services that a developer needs, which they get from the Spring library.

JBoss is a Java application server. Built by Red Hat and open source alternative to WebSphere.

Tomcat is a web container to run Java code (JSP) and a servlet container. open source. does not implement the full Java end-to-end stack. open source from Apache This is different from the Apache web server, which serves static content or content from scripting languages.

JaaS is used for securing and authenticating Java classes. used as an authentication module to connect to LDAP. Java authentication service This is implemented by Tomcat.

Wildfly is an application server that does more than Tomcat. Includes things like threading, spooling etc. and other developer features

Spring Boot. This is probably the best Java microservices framework. It combines a Java library with web containers like Tomcat or Jetty. Spring Boot gives you Java applications to use with your own apps via an embedded server. It uses Tomcat. provides the ability to create standalone Spring applications that can just be run immediately without the need for annotations, XML configuration, or writing lots of additional code.

https://azure.microsoft.com/en-us/resources/cloud-computing-dictionary/what-is-java-spring-boot/

Java Spring Framework — framework for developing production grade java applications [similar to .NET]

Struts, from Apache, is an open-source framework for developing Java enterprise web applications. It uses an MVC structure. Difference from Java spring is that Spring is much more featured and full-scale framework for app development

Log4j — open-source java library by Apache, that apps / server uses to store logs

Log4shell — software vulnerability in log4j. 2.17 is patched version of log4j

JavaScript framework and libraries for your front-end web application. They typically route requests to Node.JS (the server's JavaScript engine) and then handle sending IO requests backend to a database or other services.

Angular — by Google
React — by Facebook. Good for UI design

IBM MQ is middleware for sending content pub/sub between applications. works on mainframes. Renamed once as WMQ — WebSphere MQ. WMQ and MQ are one and the same

TIBCO EMS competes with MQ. implements JMS (java messaging service). MQ also implements JMS. JMS is a standard protocol provided by SUN

Other JMS implementations of the JMS API (open source and commercial offerings): Apache ActiveMQ, Apache Qpid (using AMQP), IBM MQ (formerly MQSeries, then WebSphere MQ), JBoss HornetQ, Oracle AQ, RabbitMQ, TIBCO EMS, Solace, etc.

Tibco RV is the preferred choice for high-speed messaging, e.g., publishing of market data, while Tibco EMS, which is based upon JMS implementation, is mostly used for more reliable messaging, e.g., order and trade, and mostly works on acknowledgment. Good link https://javarevisited.blogspot.com/2011/01/tibco-tutorial-difference-between-tibco.html

Apache Kafka is similar to EMS-type messaging sending but also does real-time data streaming. Data processing happens outside Kafka. Apache Kafka is a data streaming platform that combines messaging, storage, data integration, and stream processing capabilities.

Apache Kafka products, cloud services, and rewrites (beyond the valid option of using just open-source Kafka): Confluent, Cloudera, Amazon MSK, Red Hat, Redpanda, Azure Event Hubs, etc.

In comparison to JMS, message brokers provide messaging capabilities to produce and consume messages.

https://www.kai-waehner.de/blog/2022/05/12/comparison-jms-api-message-broker-mq-vs-apache-kafka/

Docker is a provider for creating containers (images of full applications with dependencies). (e.g., app server, SQL database, and cache). Containers can also be created without Docker. Docker is a commercial containerization platform and runtime that helps developers create, deploy and run containers. Docker also provides a toolkit that is commonly used to package applications into immutable container images by writing it to a Docker file and then running the appropriate commands to create the image using Docker Server. These container images can then be deployed and run on any platform that supports containers, such as Kubernetes, Docker Swarm, Mesos or HashiCorp Nomad. An application typically has many containers — one for each microservice packaged as a container. Developers can create containers without Docker, but the Docker platform makes it easier to do so.

Docker build — component that builds containers

Docker engine — runs containers in any environment (docker compatible)

In Docker’s client-server architecture, the client talks to the daemon, which is responsible for building, running, and distributing Docker containers. While the Docker client and daemon can run on the same system, users can also connect a Docker client to a remote Docker daemon.

Kubernetes is a container orchestration service. helps manage multiple containers, upgrades containers without downtime, etc. It is tough to configure and, hence, managed services for Kubernetes are offered by cloud vendors.

Microservices—a modular way of development Application processes are broken up into microservices that communicate via APIs or message brokers.

A container is a mechanism that aids in the development of a Microservices architecture application. (Usually, one service will be placed into one container.) When you want to scale up, you just need to provision a new container and start it. When you want to scale down, simply stop your container.

IaaS — compute server only

PaaS: compute server + application installed, for example, MySQL. In this case PaaS becomes dBaaS

SaaS — end user software installed as well

Oracle Exadata Database Machine It’s both hardware and software to run an optimized Oracle DB for special services, e.g., data warehousing. Usually on prem but later can be moved to oracle cloud as well

It is a computing platform optimized for running Oracle databases. Exadata is a combined hardware and software platform that includes scale-out Intel x86-64 compute and storage servers, RoCE or InfiniBand networking, persistent memory (PMEM), NVMe flash, and specialized software.

GWT is a development toolkit for building and optimizing complex browser-based applications. Its goal is to enable productive development of high-performance web applications without the developer having to be an expert in browser quirks, XML HttpRequest, and JavaScript. It’s open-source, completely free, and used by thousands of developers around the world. The GWT SDK provides a set of core Java APIs and widgets. These allow you to write AJAX applications in Java and then compile the source into highly optimized JavaScript that runs across all browsers, including mobile browsers for Android and iPhone.

JavaScript Object Notation (JSON) is a standardised text-based format based on JavaScript object syntax for representing structured data. It is commonly used for transmitting data in web applications (for example, to send data from the server to the client so that it can be displayed on a web page, or vice versa)

Managed File Transfer (MFT) — it’s a mechanism to transfer file content internally or extenrally. There are many providers at enterprise grade who support MFT e.g. Axway Secure Transport. You can use various protocols when using MFT such as SFTP, Samba etc.

Front End Tech stack

HTML and CSS

JavaScript: Used to make web pages interactive. It’s a programming language that allows you to implement dynamic features on web pages with common libraries and frameworks like jQuery, React, Angular, and Vue. Many modern applications now also use TypeScript instead of basic JavaScript.

Back End Tech Stack

Scripting programming languages—used to build logic for apps links the web to a database. e.g., PHP, Python, and JavaScript. High-end business logic is coded via Java.

Frameworks—which provide support for apps in development E.g., Django for Python

Grail is a web application framework written in the Python programming language. Competes with FLASK and Django

web servers—to manage client requests. E.g. Apache

Databases — store content e.g. mongo DB

MERN is a common tech stack

MongoDB (NoSQL database) — document storage

Express(.js) — Node.js web framework

React(.js) — a client-side JavaScript framework

Node(.js) is the most popular JavaScript web server. similar to WebSphere is for Java. This is optimized for I/O to connect to back-end databases and services.

By making HTTP requests from our front-end, we can connect to Express functions that will use MongoDB’s Node.js drivers to access data that we have in our MongoDB database

Additional images as appendix

Dev vs Ops in DevOps

--

--

No responses yet