Answers: <p>It turns out there is no existing solution for such a configuration.</p>
  
  <p>I have to develop something on my own.</p>
  
  <p>A nice source for help might be a series of articles on <a href="https://aws.amazon.com/blogs/developer/serverless-service-discovery-part-1-get-started/" rel="nofollow noreferrer">the Amazon developer blog</a> and <a href="http://docs.aws.amazon.com/cli/latest/reference/apigateway/create-rest-api.html" rel="nofollow noreferrer">REST API documentation</a> for the Amazon API gateway service.</p>
  
Answers: CC BY-SA 4.0
Answers: 2017-12-14T13:13:50.050Z
Answers: 2018-06-12T18:14:38.313Z
Answers: 2018-06-12T18:14:38.313Z
Answers: rush
Body: <p>I'm trying to build an application infrastructure on Amazon AWS following a microservice pattern.</p>
  
  <p>However the configuration API gateway and service discovery tool together completely puzzles me.</p>
  
  <p>According to <a href="http://microservices.io/patterns/apigateway.html" rel="nofollow noreferrer">a pattern</a> I need both (and I understand that). I decided to go with <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/welcome.html" rel="nofollow noreferrer">Amazon API gateway</a> as API gateway and <a href="https://www.consul.io/" rel="nofollow noreferrer">Hashicorp Consul</a> as service discovery.</p>
  
  <p>From what I see in the configuration guide on Amazon, API gateway configuration is pretty much straightforward: I specify path and URL to follow and that's it.</p>
  
  <p>How in the world do I explain API gateway to get information from Consul?</p>
  
  <p>PS. There is a <a href="https://aws.amazon.com/quickstart/architecture/consul/" rel="nofollow noreferrer">Consul quickstart</a> guide, but it is just a deployment instruction. There is nothing about connecting it to the API gateway.</p>
  
Comments: CC BY-SA 4.0
Comments: 2018-09-11T04:58:24.447Z
Comments: Isn't it better to use Netflix API Gateway (deployed on Ec2 instance) that works perfect with Consul or Netflix Service Registry. That way we can get advantage of dynamic service lookup + client side load balancing (ribbon or similar).
Comments: Munish Chandel
Tags: <amazon-web-services><microservices>
Title: API gateway and service discovery on Amazon AWS
UserDisplayName: rush
ThreadText: # API gateway and service discovery on Amazon AWS
  
  (Asked by: username_0 on 2017-12-13)
  
  I'm trying to build an application infrastructure on Amazon AWS following a microservice pattern.
  
  However the configuration API gateway and service discovery tool together completely puzzles me.
  
  According to [a pattern](http://microservices.io/patterns/apigateway.html) I need both (and I understand that). I decided to go with [Amazon API gateway](https://docs.aws.amazon.com/apigateway/latest/developerguide/welcome.html) as API gateway and [Hashicorp Consul](https://www.consul.io/) as service discovery.
  
  From what I see in the configuration guide on Amazon, API gateway configuration is pretty much straightforward: I specify path and URL to follow and that's it.
  
  How in the world do I explain API gateway to get information from Consul?
  
  PS. There is a [Consul quickstart](https://aws.amazon.com/quickstart/architecture/consul/) guide, but it is just a deployment instruction. There is nothing about connecting it to the API gateway.
  
  **Tags:** amazon-web-services, microservices
  
  > **Comments:**
  > **username_1**: Isn't it better to use Netflix API Gateway (deployed on Ec2 instance) that works perfect with Consul or Netflix Service Registry. That way we can get advantage of dynamic service lookup + client side load balancing (ribbon or similar).  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_0 on 2017-12-14. Score: 0 | Accepted answer
  
  It turns out there is no existing solution for such a configuration.
  
  I have to develop something on my own.
  
  A nice source for help might be a series of articles on [the Amazon developer blog](https://aws.amazon.com/blogs/developer/serverless-service-discovery-part-1-get-started/) and [REST API documentation](http://docs.aws.amazon.com/cli/latest/reference/apigateway/create-rest-api.html) for the Amazon API gateway service.
  
  
  ---
  
  