By using AWS re:Post, you agree to the Terms of Use
/Clarifying MSK data transfer pricing within region or AZ/

Clarifying MSK data transfer pricing within region or AZ


Howdy - can someone clarify the MSK data transfer charges within a region or AZ?

The MSK pricing page says "You will pay standard AWS data transfer charges for data transferred in and out of Amazon MSK clusters" with a link to the EC2 on-demand pricing page.

The "Data Transfer within the same AWS Region" section of that page gives the pricing for different combinations of EC2 and various AWS services. Some combinations have free data transfer within a region. Some combos have free data transfer within an AZ. But MSK is not listed there so I can't tell what the pricing is.

Can someone clarify how the pricing between MSK and EC2 works within a region?

I'm particularly interesting in learning about steps I can take to achieve free data transfer between EC2 and the MSK cluster :-)

Thanks! JP

3 Answers
Accepted Answer

Hi JP - any data transfer that happens within the cluster (e.g., data replication between brokers) is included in the cost of the MSK brokers so you don't pay separately for it, and this cost does not vary.

For data in and out of the cluster, standard data transfer rates apply to this traffic.

If your EC2 clients are in the same AZ and region as the MSK broker it's connected to, per data transfer pricing the cost per GB is $0. If your clients are sending traffic to/from brokers in different AZs in the same region your clients generate cross AZ data transfer usage with a cost per GB that varies by the region the traffic is in. If your clients are in a different region than the MSK cluster, your clients generate cross region data transfer usage with a cost that varies by region source and region destination.

You can back into the AZ of the broker using the subnet.

answered 3 years ago

Thank you. So I could do some setup to constrain communication between an EC2 instance and a broker in one AZ, but since that broker may not be a leader for a partition, I'd still need to make cross-AZ requests to get at all the data and hence incur cross-AZ charges?


answered 3 years ago

Correct. If your partition leader is in a different AZ than your producer/consumer, then you will incur cross-AZ charge.

answered 3 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions