What Is My [Server] Throughput? (One-Click Audit)

Tags: performance, webdev, javascript, showdev
Published: 2021-06-08 09:24:19

# Have you wondered *how many users can be on your website* at the same time?

But you wanted a <ins>test framework</ins> that is...
- **More than a benchmark** (not JMeter or LoadRunner). 
- **Simulated real users**. 
- **Presentable and quick**
- **Provides a quick report, something like this:**

![Screen Shot 2021-06-05 at 11.18.36 AM](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qyjoqrotbyto9fl0cpk5.png) 
 

# WhatIsMyThroughput.com (beta)

In this article, I want to introduce to you [**WhatIsMyThroughput.com**](https://whatismythroughput.com). It is a tool that helps gauge whether your website is ready to handle X users concurrently.  

## Case Study of chaos.browserstorm.com

The [chaos server (which can seem down)](https://chaos.browserstorm.com) uses [`connect-chaos`](https://www.npmjs.com/package/connect-chaos) to generate errors on an express server randomly. This particular server can control what errors get generated and when, so it's a prime example of what systems can do at high loads. 

![Screen Shot 2021-06-05 at 10.51.21 AM](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ep6k8p2y82ukvj8oxnpy.png)
 
## Our Test Setup

1. Navigated to [WhatIsMyThroughput.com](https://www.whatismythroughput.com) 
2. Submitted a test with the following properties

| Property      | Value |
| ----------- | ----------- |
| Target URL      | https://chaos.browserstorm.com/       |
| Virtual Users   | 32       |

The test takes 15 minutes to run, so now we wait.

## What was the verdict?

Tik tok tik tok... and the results have come in! The test has **failed**! The website could NOT handle the load of 32 concurrent users. This test is a bit anti-climactic since the errors are expected. But in any other case, it's important to review the errors the users have experienced, shown below.  

![Screen Shot 2021-06-05 at 10.43.55 AM](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7milfzrxs88eudv9tr41.png)
 
## What were the errors?

View the test run and errors [here](https://www.whatismythroughput.com/test/zLaMmkMybK49OUk).

![Screen Shot 2021-06-05 at 10.44.19 AM](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ebgnmh84ig5hvfkhcsds.png)
 
## What then?

If a production server had errors similar to this test, then there is a problem. But in this case, it is expected. Generally speaking, at scale, the use of CDNs would improve the read scenarios. For write heavy situations, low-hanging fixes can include waiting rooms. There are more complex solutions 

## Custom Flows

This article focuses only on the Page Visit Flow. If you wanted to find out the throughput of flows on your server, like signing up or performing a search, they need to be implemented in JavaScript/TypeScript via. BrowserStorm (or at any other browser at scale test platform).

# Pricing

This tool is free for the most part. However, generating higher loads does cost, but that helps maintain it free for most users. 

# Conclusion

With Single Page Apps (SPAs) on the rise, the goal of BrowserStorm (and WhatIsMyThroughput) is to offer a "certificate" for a particular scale. This guarantee should give developers a sense of confidence and proof that their system can operate at production loads. 

> Both BrowserStorm and WhatIsMyThroughput are in active development. Feedback helps drive the direction of the product. Please let us know if you have any questions or concerns in the comments.