Amazon ElastiCache offers different pricing models depending on customers' needs, including On-Demand and Reserved Instances. The latter can provide significant savings compared to On-Demand instances.
Reserved Instances (RIs) require a one-time, upfront payment and offer a significant discount compared with the hourly charge for On-Demand instances. There are three types of RIs - All Upfront, Partial Upfront, and No Upfront:
The duration of the term also impacts the cost of RIs, with longer terms providing a greater discount. Currently, Amazon offers 1-year and 3-year term options.
For specific prices, it's best to directly refer to Amazon's official ElastiCache Pricing page as rates can vary by region and instance type.
# Example Python code using boto3 to get RI pricing import boto3 pricing = boto3.client('pricing', region_name='us-east-1') response = pricing.get_products( ServiceCode='AmazonElastiCache', Filters=[ {'Type': 'TERM_MATCH', 'Field': 'termType', 'Value': 'Reserved'}, ], ) for product in response['Products']: # Print out product details here...
Note: You'd need to parse the JSON returned from the get_products
call to get the actual pricing information. Check for updates in AWS SDKs for possible changes.
Dragonfly is fully compatible with the Redis ecosystem and requires no code changes to implement.