Backend Engineering

Reducing API Response Time with Asynchronous Processing

As a Backend engineer, one of the important parameters to validate the work is the number of ms at which the API returns the required resource.

By Vishal Nagarajan1 min read

Overview

As a Backend engineer, one of the important parameters to validate the work is the number of ms at which the API returns the required resource.

You make an API return the resource at 10ms all good, if the delay is visible you're the one who is responsible for the bad user experience.

There are many ways to reduce the API response time, one important and effective way is focusing on what part of the processing can be moved to asynchronous processing.

Key Points

  • Focus only on the resources that the client needs as a response.
  • Move everything else to async to reduce response time.
  • Use messaging brokers like Kafka for multi-service processing.
  • In Spring, use @EnableAsync and @Async for asynchronous tasks.
Next in Backend Engineering
The Importance of Documented Test CasesDocumented test cases will save your day when you end up with an issue due to the operations in your implementation.1 min read

This post is part of v.ish.al, where it all starts with a walk.