Logging system. Optimize Magento database by cleaning logs

Magento is a powerful and, at the same time, complex eCommerce system. One of the important parts of this system is a different events logging. After some time of functioning, Magento collects more and more events data and it might have the performance impact. Of course, the logs information can be cleaned manually in the database to avoid issues with performance, but this approach is not always handy. Therefore, in this article we want to review Magento logging system and built in tools for logs handling.