Lower the cost of building graph apps by up to 76% with Amazon Neptune T3 instances
When you are building a graph application, you want a fast, cost-effective instance as you iterate to build your Apache TinkerPop or RDF/SPARQL graph application. Amazon Neptune now allows you to choose burstable performance instances (T3) in addition to the fixed performance instances (R5 and R4). Amazon Neptune
db.t3.medium burstable performance instances are engineered specifically for these use cases and are 76% cheaper than the smallest fixed performance instances. When you are ready to go into production or need consistently high CPU performance for your database production workloads, you can quickly add fixed performance instances to your existing cluster using the AWS Management Console, AWS SDK, or AWS CLI.
This post discusses the Amazon Neptune T3 burstable performance instance and how to create a database cluster with this instance type.
Understanding burstable performance instances
Burstable performance instances provide a baseline level of CPU performance with the ability to burst above the baseline. A Neptune T3 instance can sustain high CPU performance for as long as a workload needs it. For most development and test workloads, T3 instances provide good performance at a low cost. The hourly T3 instance price covers all interim spikes in usage when the average CPU utilization of a T3 instance is at or less than the baseline over a 24-hour window.
The T3 instance baseline performance and ability to burst are governed by CPU credits. A CPU credit provides the performance of a full CPU core for 1 minute. Other combinations of the number of vCPUs, utilization, and time can also equate to one CPU credit. For example, one CPU credit is equal to one vCPU running at 50% utilization for 2 minutes, or two vCPUs running at 25% utilization for 2 minutes. T3 instances continuously earn (at a millisecond-level resolution) a set rate of CPU credits per hour, accrue CPU credits when they are idle, and use CPU credits when they are active. The accounting process for whether credits are accrued or spent also happens at a millisecond-level resolution, so you don’t have to worry about overspending CPU credits; a short burst of CPU uses a small fraction of a CPU credit. For more information, see CPU Credits and Baseline Performance for Burstable Performance Instances.
db.t3.medium instance has two vCPUs and earns CPU credits at a rate of 24 CPU credits per hour. This results in a baseline performance of 20% (12/60 minutes) per vCPU. If the instance does not use the credits it receives, it stores the credits in its CPU credit balance, up to a maximum of 576 CPU credits. When the
t3.medium instance needs to burst to more than 40% of a core, it draws from its CPU credit balance to handle this surge automatically.
Neptune T3 instances can burst above the baseline even when its CPU credit balance is zero. For a vast majority of database workloads where the average CPU utilization is at or below the baseline performance, the basic hourly price for
t3.medium covers all CPU bursts. For example, if the instance runs at an average 45% CPU utilization (5% above baseline) for 24 hours after its CPU credit balance is drawn to zero, it is charged an additional 15 cents per vCPU-hour for that duration. All other charges remain the same.
Amazon EC2 offers T3 instances in
standard modes. Neptune T3 instances only run in
unlimited mode, which means that you incur charges if your average CPU utilization over a rolling 24-hour period exceeds the baseline of the instance. There is no configuration to switch to
standard mode. For more information, see Unlimited Mode for Burstable Performance Instances.
Creating a database cluster with the Neptune T3 instance
You can create a Neptune database cluster using the
t3.medium instance from the console, AWS CLI, or SDK.
To create a cluster from the console, complete the following steps:
- On the Neptune console, choose Create Database.
- For Purpose, select Development and Testing.
- For DB instance class, choose db.t3.medium.
From the AWS CLI, you can specify the instance type with the
db-instance-class parameter. See the following code:
If you are using an AWS CloudFormation template for creating Neptune databases, set the
db.t3.medium in the stack details before deployment. For more information, see Creating a New Neptune DB Cluster Using AWS CloudFormation or Manually.
This post discussed the new Amazon Neptune T3 burstable performance instance and how to create a database cluster with this instance. For more information about spinning up a test cluster with
db.t3.medium, see Getting Started with Neptune. For the pricing information on T3, see Amazon Neptune Pricing. AWS always welcomes feedback. Please reach out using the comments section or via the support forums.
About the Authors
Karthik Bharathy leads product for Amazon Neptune.
Brad Bebee believes that graph is awesome, and he leads product and engineering for Amazon Neptune. If you agree, or want to find out, he’d love to hear from you on Twitter.