Hi Jason Wihardja. Thank you for reading the article.

The solution you mentioned is great and it works. However it has Thundering Herd problem because all the request would be waiting for the same promise.

One more thing one should worry about is what happens when the promise is rejected. Ideally we would want to have another request go through if the first one never returns or takes too long

Senior Staff Engineer @freshworks. Ex-McKinsey/Microsoft/Slideshare/SAP, Tech Enthusiast, Passionate about India. Opinions are mine