What is Apache Kong?
Apache Kong is an Open Source Headless Service Proxy that provides routing, load balancing, and request-routing capabilities.
It is one of the most popular services proxy on the market, being both free and open source.
Kong can be installed on any server running Linux or FreeBSD operating systems and provides many different plugins to extend its capabilities with additional features. Apache Kong is also written in Go and is a great alternative to NodeJS for implementing microservices.
In this tutorial, we will see how we can install and configure the Apache Kong on Ubuntu 18.04 LTS, Ubuntu 16.04 LTS, Ubuntu 14.04 LTS and Ubuntu 12.
Note: We have tested this article with Kong version 1. Prerequisites. We assume you have basic knowledge of Linux and shell scripting. You can find the list of all our previous tutorials in our repository. You may want to backup your database before installing Kong or start it in offline mode. You should have an internet connection during the installation. If you don't have the default Kong repository installed, please refer to the official documentation. What is a service proxy? The service proxy acts as a gateway or middleware between the application (or node) running on your server and a network back-end. It acts as a reverse proxy or a reverse caching proxy that can be used to load balance the requests across multiple servers.
In the following example, Kong is acting as a reverse proxy to two servers; one server running a NodeJS application, another running a MySQL database. Now, when a user loads the route, Kong receives the request and forwards it to the NodeJS application server that is listening on port 8080 . In the following figure, Kong is configured to forward the requests to the NodeJS application server only on the /customer route. In the same way, Kong can also be used to forward requests to other services like a MySQL database server. Why do we need a service proxy? Service proxies are widely used to build applications that can scale out easily while keeping them secure and private. Let's look at a couple of examples: Chat Server. A chat application consists of a server side and a client side.
Is Kong the best API gateway?
The last month I have been talking with my client who has his own API gateway.
He was struggling with Kubernetes and now he wanted to give a try to Kong. He asked me to tell him what I think about Kong compared to other solutions.
Kong vs. Others In my opinion, Kong is a good option for someone who wants to provide a service which will be accessible from outside their company. If you want to use a solution that will work with your corporate network, you should not use Kong.
If you want to use an API gateway in a private cloud, I recommend you to use Kong. It's a great solution for internal use. The problem is when you want to expose your API. In this case, you need to use public cloud services or you need to use a VPN.
Why Kong? Kong is an open-source API Gateway written in Go. It's a great choice for developing API gateways. The project was started by StrongLoop, the company that runs Node.js.
It's a lightweight product. It uses HTTP as transport protocol. It supports API versioning and automatic authentication.
Kong is one of the most important projects in the ecosystem of Node. You can use it to create an API gateway, an API management solution or an API service provider. What Kong can do? Kong offers many features and it can be a good solution for small companies which have a small team. The main advantage of Kong is that it is a standalone solution. It has no dependencies. It works on Linux and Windows. It is easy to use. It has a CLI tool for creating API gateways. It also provides good documentation.
When you are creating a new API gateway, it gives you many options. You can easily configure the API gateway to work with other services like AWS Lambda, Google Functions, Azure Functions or Firebase. It supports both V1 and V2 of REST APIs. You can create a custom API by implementing your own implementation of the REST API protocol. It's easy to configure Kong to work with Kubernetes.
Is Kong a good API gateway? In my opinion, Kong is a good option if you want to work with Node.
Is APISIX better than Kong?
This is a discussion on ?
Within the Server & Virtualization Discussion forums, part of the Tech Support Forum category. Posted by shawnkoch I am currently using APISIX, but am looking at replacing it with Kong ( ). Is anyone .
I am currently using APISIX, but am looking at replacing it with Kong ( ). Is anyone familiar with these products? Is one better than the other? I am trying to replace it with a product that offers less code and maintenance.
I am currently using APISIX, but am looking at replacing it with Kong ( ). If I can find a product which includes all 3 of these in 1 - nginx for load balancing, apache for reverse proxying and application hosting. Well it won't take me long to get one in place. Until then I'll keep using apisix for sure.
Kong could do most of what apisix does, but I want the extra functionality. I want it to be easier to configure, have more configuration options, and better documentation. Kong is also more expensive. While there are lots of ways to set up apache reverse proxy so that apache runs the web app and serves static assets and dynamic content from different servers, you have to use a lot of the same configuration to do this.
There are very specific ways to configure apache to serve static content and dynamic content without using htaccess and having to maintain two webservers. Most of the posts on how to configure apache for reverse proxying to multiple servers use that method. And, because apache uses modrewrite and uses apache's config file, you need to manage this configuration as a single piece, which is very difficult. I found this setup easier and also used to work better.
And, most importantly, Kong doesn't offer a single service for load balancing. If you need a load balancer in your production environment, you will have to put it on a separate server, which means you have more configurations to maintain.
Related Answers
Is Kong API gateway free?
If you're building a service and want to serve web requests to it, you ma...
Is Kong better than MuleSoft?
The first time we used Kong, we did so in the pre-release and early days....
What is Kong open-source?
Kong Mesh is a mesh network project, created by Kong developers at Alibaba Cloud...