Types of VPC Endpoints
Now we will look at the Gateway Endpoints that supports two services, i.e., Amazon S3 and Dynamo DB. Gateway Endpoints look similar to the NAT Gateway.
Let's look at the architecture of VPC without VPC Endpoints.
In the above architecture, we have a public and private subnet where public subnet consists of a public EC2 instance, and private subnet consists of a private EC2 instance. When EC2 instance in private subnet wants to store the file in S3, so it traverses through the NAT Gateway and then goes basically outside the AWS network to the S3 endpoints.
Let's look at the architecture of VPC that includes VPC Endpoint.
In the above architecture of VPC, an EC2 instance in private subnet sends the files to the VPC Gateway and then to the S3 which is in aws network.
How to create a VPC Endpoint
Service category: I select the AWS services that I will use through the VPC Endpoint.
Service name: Select the service that you want to use. Suppose I choose AWS S3 service.
VPC: Select the VPC that you have created. I have created javatpointvpc, so choose the javatpointvpc from the VPC drop-down menu.
Configure route tables: Choose the main route table that has been created in a javatpointvpc.