You Can Now Set AWS X-Ray with Amazon API Gateway
What is AWS X-Ray
AWS X-Ray is a service for collecting, visualizing, and analyzing a series of request/response data (HTTP request, API call, etc.) generated within an application. AWS X-Ray is largely divided into two menus: service map and trace. AWS X-Ray works with AWS Elastic Beanstalk, Amazon EC2 Container Service (Amazon ECS), Amazon EC2 and AWS Lambda. One can use X-Ray with applications written in Node.js, .NET and Java that are deployed on these services.
It gets the name of X – Ray because it will look inside. Recent applications tend to make micro service such as separating front/API or use PaaS such as Lambda, S3, Dynamo DB, but as the number of characters increases, it is hard to follow the connection.
How It Works
Tracing Request – AWS X-Ray traces request made to your application. X-Ray collects the data about the request from each of the underlying application services it passes through.
Record Traces – X-Ray combines the data gathered from each service into singular units called traces.
View Service Map – View the service map to see trace data such as latencies, HTTP statuses and metadata for each service.
Analyze Issues – Drill into the service showing unusual behavior to identify the root issue.
Benefits of AWS X-Ray
- It can work with variety of simplex and complex applications
- One can trace multiple requests made to different Availability Zones, AWS Regions and AWS accounts
- One can analyze complex micro services applications, three-tier web applications and simple asynchronous event calls
- Improves application performance
- Easy to identify issues occurring in applications
- It enables user to keep end to end track of application performance
The following additions were added as API addition functions of the API Gateway
- API Gateway support simplifies tracking and analysis of requests to underlying services via API
- Start of support to control sampling rules with AWS X-Ray console and API
Price of AWS X-Ray
Since the free frame is also set widely, there is also a possibility of trying setting it valid for the time being. Also, AWS X – Ray can change the frequency of sampling, so you can adjust the cost there.
Amazon API Gateway
Amazon API Gateway is a managed API management service of AWS. One can create, distribute, maintain, monitor, protect, etc. about the API, and can also support large APIs. The Amazon API Gateway provides the following items necessary for API management, on the AWS side, without the need for customer-side implementation. Infrastructure management, operation, version control, authentication, API response status monitoring, monitoring etc.
The idea that API Gateway itself does not do something, API Gateway receives requests from outside, calls another thing, and returns the result. Also, since there is a function to change the contents of the request and the response using the template, there is an existing API which exchanges data by XML, for example, when the caller wishes to go with REST, the API Gateway one can enter and be in charge of the conversion.
Advantages of Using Amazon API Gateway
- Users do not need to perform operations on many tasks such as ‘API version management’, ‘API authentication management’ and ‘API monitoring’.
- Since Lambda can be used at the back end, infrastructure management/operation is unnecessary
- By using API Rate interface of Gateway, it is possible to greatly reduce development man-hours
- You can unify various APIs used in applications in one format
- Companies can wrap large enterprise applications with wrappers that can connect to web services