title: To apply rate limit to a spring boot particular api that is hosted on AWS cloud and running on multiple pods
body: <p>I have a spring boot application and, I want to apply rate limits on some APIs which are integrated with 3rd party API for Payments that has rate limits. Basically a common pool for this external API, so that the API calls made to the 3rd party APIs don't exceed the rate limit. </p>
  
  <p>I have gone through this link :
  <a href="https://medium.com/teamarimac/implementing-throttling-in-java-spring-boot-ec4723cfce9f" rel="nofollow noreferrer">https://medium.com/teamarimac/implementing-throttling-in-java-spring-boot-ec4723cfce9f</a>.</p>
  
  <p>In this link <code>acquire()</code> method defines my actual requirement.</p>
  
  <p>But I have my application running on <code>AWS cloud</code> having <code>multiple instances</code>. The method mentioned in the link applies on single instance only, but I want a solution which will work with all the <code>instances combined</code>.</p>
  
  <p>Thnaks</p>