Running in production
To successfully run a distributed application in production, we need to consider a few more aspects beyond the best practices and patterns that were presented in the preceding sections. One specific area that comes to mind is introspection and monitoring. Let’s go through the most important aspects in detail.
Logging
Once a distributed application is in production, it is not possible to live debug it. But how can we then find out what the root cause of the application malfunctioning is? The solution to this problem is that the application produces abundant and meaningful logging information while running. We briefly discussed this topic in an earlier section. But due to its importance, it is worth reiterating. Developers need to instrument their application services in such a way that they output helpful information, such as when an error occurs or a potentially unexpected or unwanted situation is encountered. Often, this information is output to...