'When would I use the StatsD protocol over EMF to track application metrics?

I want to track application metrics for my services and view those metrics in CloudWatch. AWS provides multiple options to do this, but the two I'm curious about are installing a CloudWatch agent & using the StatsD protocol vs. using PutMetricData.

I can't tell when I would use one approach versus the other and could use help in identifying the pro's vs con's of each approach.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source