[For beginners] What is middleware? Thorough explanation of types, roles, and functions!
Hello.
My name is Kita from Beyond and I recently started playing the popular Pokemon game.
Last time, I blogged
about how servers start up This time, I would like to explain what middleware is in an easy-to-understand way.
Although it may not be a term you are familiar with in your daily life, middleware is actually an important item that is essential for a system to operate.
This time, I will explain the functions and types of middleware, including illustrations, in a way that even beginners can understand, so please read until the end.
What is middleware?
First of all, to conclude, middleware is what is called intermediate software
As its name suggests, it is software that acts as a bridge between the OS (operating system) and applications.
There are many types of middleware, each specialized in a specific function and assisting the OS and applications.
Let's review some terminology here.
What is OS?
OS is an abbreviation for Operating System, and it is the most basic software that controls the normal functions of a computer.
In other words, the OS alone cannot provide advanced functions because it can only provide common functions.
What is an application?
An application is called applied software.
This is separate from the OS and is software that enables applied work.
For example, Microsoft's spreadsheet software Excel and text creation software Word are examples of this.
Furthermore, if we focus more on infrastructure operations,
EDISONE, a reservation management system like the one provided by Beyond, are useful for infrastructure operations. This corresponds to related application software.
Specific role of middleware
Now, let's dig deeper into the reservation system that we used as an example earlier.
When you think of a reservation system, you probably think of it as a service used to make reservations for conference rooms or shops, but that doesn't mean it can be created using just an OS.
When thinking about creating a reservation system, the first thing you need is an application that provides a reservation function.
In other words, it is the program code written by the developer.
However, a reservation system cannot be created with just an application (code); it requires a function to display the management screen and reservation information in a browser, a function to save/manage reservation data, and a function to send an email at the time of reservation. It's coming.
When you break down the reservation system in this way, you will need multiple functions.
These multiple functions are implemented on the premise of using middleware specialized for each purpose
The specific functions are as follows:
Web page = Apache
Store/Manage data = Database/MySQL
Ability to send email = Postfix
As such, middleware is required to fulfill each role.
Typical middleware
The diagram above shows typical types of middleware.
A commonly used configuration is Linux (OS) + Apache (web page) + MySQL (database) + PHP (programming language), each of which is called LAMP There are many.
①Apache
is said to be
most used web server *Currently, it seems to be competing for No. 1 with NGINX, which will be described later.
It is middleware that is widely used for large-scale commercial sites as well as home server construction for hobbyists.
There is a lot of information available on the internet, and it is often used as an entry point for server construction.
②NGINX
a web server the same role as Apache and is used all over the world.
It is more versatile than Apache and has functions such as reverse proxying, load balancer for load distribution, and caching of HTTP requests.
③MySQL
It is middleware called
a relational database management system (RDBMS), as the name suggests, it has the role of storing and managing databases.
This is also the most used RDBMS in the world.
Additionally, a middleware called PostgreSQL is often used in the same role as a database.
④Postfix
Postfix is a middleware that is often used when building a mail server, and
has the role of sending and forwarding mail
It depends on your requirements, but if you need to send and receive emails, it is often used in conjunction with Dovecot, which will be described later.
⑤Dovecot
This is similar to Postfix in its role, but
it is middleware that has the function of receiving IMAP/POP3 emails
To explain it simply, I think it will be easier to understand if you remember Postfix = for sending emails and Dovecot = for receiving emails
overall view
Finally, I will explain and review using diagrams.
A rough summary of the flow is as follows.
- Receive web page requests from users (Apache)
- Application program works (PHP)
- The program performs data matching from reservation management data (MySQL)
- Return a request for a web page (Apache)
- Send reservation completion email (Postfix)
The flow goes like this.
lastly
So far, what is middleware? Starting with that part, we explained in detail the functions and types.
There are various types of middleware, each with specialized functions for different purposes.
Behind the scenes of the various systems we use on a daily basis, middleware helps as intermediate software. Thank you for everything. Mr. Middleware.
was created with reference to the video of
Nezumiya's Infrastructure Engineer Dojo, a channel operated by our company you can learn knowledge about infrastructure from scratch , so if you are interested, please subscribe to the channel and give it a high rating!