Load test with Odin
Introduction
Load testing is a type of performance testing that simulates a real-world load on any software, application, or website. Without it, your application could fail miserably in real-world conditions. A load testing can be performed on services or smaller components like database servers or firewalls.
Odin, as a developer tool, provides the capability to the users to perform load testing. In this article, we are going to understand the steps to perform load testing with the help of Odin. This will cover the following steps with the help of a sample:
Creating a load environment
Releasing a service
Deploying a service in load environment using provisioning config file
Configuring the components for scaling
Creating a load environment
User can create a load environment in Odin to perform load testing. Please use the following command for the same:
To view the load environment created with the above command, execute the following to see the status:
odin list env --env-type load
Releasing a Service
To release the service you have created and willing to load test, use the following command:
odin release service --path (path to directory)
Deploying a service in load environment using provisioning config file
Once the above step is completed, the AMI and the Docker image for the service gets created. Now a user needs to deploy the same in the load environment. The default deployment type in load environment is AWS EC based deployment. However, user can pass customised deployment type in provisioning config file to override the same. To deploy the service, please use the following command [the second command to pass provisioning config separately].
odin deploy service --name {serviceName} --version {serviceVersion} --env {envName}
odin deploy service --name {serviceName} --version {serviceVersion} --provisioning {provisioningFilePath} --env {envName}
Configuring the components for scaling
To perform a load testing, today a user has to follow the actions mentioned in the table below. In the rightmost column, you can see what exactly you need to specify using Odin and rest can remain as it is i.e rest can be performed via AWS console:
ASG upscale/downscale
Using AWS Console
LCU provisioning
Using AWS Console
RDS instance type
You can specify this using provisioning config
Add reader/writer in database
Using AWS Console
Add notes and shard in Redis
Using AWS Console
Parameter Group
Using AWS Console
Load Balancer Type
You can specify this using provisioning config
Last updated