I have deployed a pretty simple REST API, which is a backend for another simple Angular application.
I have noticed the increased billing for “Network Internet Data Transfer”. When I checked the logs for API sent and received bytes, I saw that on average “Received bytes” is 5 times higher than “Sent bytes” which is strange. Based on this logic, the Angular application sends request API with 5 times more data than API returns data to the front-end. I have checked the networking and all payloads, and it does not make any sense.
Here is an example of a chart. I was making a random click in the Angular app, to trigger API calls so the log would be generated:
The chart spiked at received bytes at 295kb/s at 2:31pm
The log for API looks like this… it’s all but just GET requests, and the size of each request is about 1kb. I have calculated that made about 30-40 calls per minute, so the amount of traffic has to be around 40-50 kb per minute.
How come I see the “Received bytes” spiking up to 300kb per second? And this is all GET requests, which don’t have a payload. So the “Received bytes” should not show almost anything for the GET calls.
As a result of this weird behavior, I am seeing a spike in billing for “Internet Data Transfer Out North America to North America”. I understand that once I have more users of this service, my billing will be crazy…
Here is my billing chart. On March 6, it’s when the API was deployed and was more or less actively tested with UI altogether in the cloud. The previous billing from March 1 to March 5th includes other APIs that I run on the cloud, as it does not have billing for “Internet” at all. Pretty significant difference
Would be very appreciative for any insights.
Why do I see the spike in “Received bytes” and billing for usage of “Internet” and how else could I debug this to understand where is it coming from.
Thank you!



