less than 1 minute read

Peripheral tasks such as Monitoring, Logging etc are critical to most applications and often integrated within them. However, these tasks run alongside the same process as the application which is potentially inefficient and points to improper separation of concerns. Plus, outages caused in these monitoring and logging components could severely impact the entire application functions.

Solution: Co-locate as Sidecar

  1. Co-locate the set of tasks along with the application but place them in their process or container as a Sidecar
  2. Sidecars are typically small/pluggable components and can be written in different languages
  3. Both application and sidecar are deployed as a single unit, therefore latency is low
  4. The sidecar can be used for modifying how the application container works without having to make any changes to the code
  5. The sidecar is bolted to the application and its lifecycle is dependent on the application
  6. If the sidecar container logic gets complex or tightly coupled with the main application, it may better be integrated with the main application’s code instead