Yandex Data Streams pricing
Data Streams supports two pricing modes:
- Based on allocated resources: You pay a fixed hourly rate for the established throughput limit and message retention period and additionally for the number of units of actually written data.
- On-demand: You pay for data writes and reads performed, the amount of data read/written, and the size of storage actually used for messages with a valid retention period.
The pricing mode is set for each data stream individually. By default, streams in Data Streams are created with pricing based on allocated resources.
Pricing based on allocated resources
If pricing for allocated resources is used, the number of units of written data and resources allocated for streaming data are billed.
Pricing for the allocated resources includes the established segment throughput limit as well as storage time and size.
Data stream services with the following properties are provided free of charge each month:
- Segment write speed: no more than 128 KBps.
- Message retention period: 1 hour.
- Number of data units written per month: no more than 2 million.
After you've used up your free service amounts, you will be charged at the applicable rate. The unused balance of free services is reset at the end of the month.
Examples of cost calculation
A single-shard stream receives two 50 KB messages per second. The message retention period is 12 hours.
Calculation of the monthly cost of processing data (provided that there are 31 days in the month):
⌈ 50 / 40 ⌉ = 2
Where:
- 50: Size of one message in KB.
- 40: Size of units of written data in KB.
- 2: Number of data units written per message.
While calculating the cost, the number of units of written data is rounded up to an integer. In this example, the number is rounded to 2.
2 × 2 = 4
Where:
- 2: Number of messages per second.
- 2: Number of data units written per message.
- 4: Number of data units written per second.
4 × 60 × 60 × 24 × 31 = 10,713,600
Where:
- 4: Number of data units written per second.
- 60 × 60 × 24 × 31: Number of seconds in the month.
- 10,713,600: Number of data units written per month.
0.001709 × 24 × 31 = 1.269264
Where:
- 0.001709 is the cost of allocated resources per hour when stored for 12 hours.
- 24 is the number of data storage hours.
- 31 is the number of days in a month.
- 1.269264 is the cost of allocated resources with a maximum data write speed of 128 KB/s and a storage period of 24 hours, $ per month, without VAT.
(10713600 - 2000000) / 1000000 × 0.015128 + 1.269264 = 1.401083
Where:
- 10713600 is the number of units of data written per month.
- 2000000 is the number of free units per month.
- 0.015128 is the cost of 1 million units of written data, $, without VAT.
- 1.269264 is the cost of allocated resources with a maximum data write speed of 128 KB/s and a storage period of 24 hours, $ per month, without VAT.
Total: $1.401083, without VAT.
Pricing
Cost per unit of written data
The first 2,000,000 units of written data per month are free of charge.
Unit size | Cost per million units, without VAT |
---|---|
40 KB | $0.009440 |
Cost of allocated resources
Pricing based on storage time
Cost of using allocated resources per hour:
Data retention period |
Cost of storing data with a throughput limit per shard of 128 KB/s, without VAT |
Cost of storing data with a throughput limit per shard of 512 KB/s, without VAT |
Cost of storing data with a throughput limit per shard of 1 MB/s, without VAT |
---|---|---|---|
1 hour, the first 744 hours of use per month | Free | Not provided | Not provided |
1 hour, over 744 hours of use per month* | $0.000800 | Not provided | Not provided |
4 hours | $0.000933 | $0.002133 | $0.003467 |
12 hours | $0.001067 | $0.003200 | $0.005067 |
24 hours | $0.001600 | $0.004800 | $0.007467 |
* The time of resource usage by multiple streams is summed up. For example, if two streams are running 24/7 during a month, the time of resource usage will be 2 × 24 × 30 = 1.440 hours. The first 744 hours are free of charge. They will be used up by the two streams in half a month. After that, you will start to be charged for the service.
Pricing based on storage size
Data is stored for up to 7 days.
Data write price:
Segment throughput limit | Cost, including VAT |
---|---|
Up to 128 KB/s | $0.384000 |
Up to 512 KB/s | $1.152000 |
Up to 1 MB/s | $1.920000 |
Data storage price:
Storage size | Cost, including VAT |
---|---|
1 GB | $0.086400 |
Minimum storage size: 50 GB per segment.
Pricing based on actual usage
If pricing based on the actual usage is used:
-
Data streams stored in YDB serverless databases are charged for based on the pricing policy for YDB serverless mode.
-
Data streams stored in YDB dedicated databases are not charged for separately (you only pay for a dedicated database, see the pricing policy for dedicated databases).