Original link: Implementing the Sidecar Pattern in Microservices-based ASP.NET Core Applications / InfoQ.
The code shown is C#, but that is just syntax - principles apply fine to Java, PHP, Python etc..