Monitoring#

In most cases, when deploying an application in production, monitoring tools also need to be set up along side it, to make sure it is working as expected and to track errors when they occur.

Metrics#

To help setup metric collection and monitoring of applications, atoti exposes some of the Spring Boot Actuator endpoints at f"http://localhost:{session.port}/actuator". For instance, JVM and system metrics can be scraped with Prometheus from the /actuator/prometheus endpoint.

If security has been enabled, we recommend setting up a user with basic authentication for Prometheus to use when scraping data. The Secure a session guide details how to setup such a user for Prometheus.

Logging#

In order to make analyzing the application’s easier (e.g.: if you are using the Elastic Stack ), we recommend formatting the Python logs the same way atoti’s Java logs are formatted using logging.basicConfig() like this:

logging.basicConfig(format="%(asctime)s  %(levelname)s %(process)s --- [%(threadName)s] %(name)s : %(message)s")