In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)06/01 Report--
This article will explain in detail how to use the WebApi management and performance testing tool WebApiBenchmarks. The content of the article is of high quality, so the editor shares it for you as a reference. I hope you will have some understanding of the relevant knowledge after reading this article.
Speaking of WebApi management and testing tools are already very many, Postman, Swagger and so on are excellent in management and maintenance; there are also many tools in performance testing, such as wrk,bombardier,http_load and ab, and so on. However, these tools are single, good management and maintenance is relatively inefficient in performance testing, and good performance testing is not ideal in management and maintenance! The following mainly introduces a WebApiBenchmarks tool based on dotnet core, which can manage and maintain webapi and provide efficient performance testing capabilities. next, let's preview the functions of this gadget and then describe it in detail.
Function introduction
Support for simple service management, unit and stress testing of API for different services at any time
Support classification to manage test cases, use cases support definition of operations such as GET,POST,DELETE and PUT
Provide efficient performance testing support to achieve 20W rps test performance on a 4-core PC
Support multi-API pressure test at the same time, and display relevant performance index data for reference and comparison
Deployment
The tool can be run under Linux and Windows with .net core 2.1or later installed, and the tool is launched as a http service and operated through browser access. Tool download address: https://github.com/IKende/WebApiBenchmark
Running
Linux
Dotnet BeetleX.WebApiBenchmarks.dll
Or
. / webapibenchmark.sh
Windows
Dotnet BeetleX.WebApiBenchmarks.dll
Or
Webapibenchmark.bat
Add service address
The tool can maintain multiple service addresses, and all tests must select the corresponding address to run the test.
The address must be an available http service Url
Add test cases
The tool supports GET,POST,DELETE and PUT request definitions, you can define QueryString and header values according to the actual situation, and set the corresponding Body content for POST and PUT.
There is a test button below the editing interface to test the invocation of API immediately; select the appropriate service address and click test to see the complete return result below.
Batch unit test
The tool supports batch execution of test cases and displays specific execution results on the test cases; just select the use case that needs to be tested and click the unit test.
Performance testing
Performance testing is the most important function provided by the component, in order to ensure the efficiency of performance testing; the component rewrites a lightweight HttpClient through which efficient stress testing can be carried out even on low-configuration computers. You need to select the appropriate service address and unit test before testing.
Test parameter settings
The tool provides two testing methods, which are based on the time and the total request data, and select the corresponding test method to set the corresponding test value; the number of users refers to the number of simultaneous requests, and the maximum tool limit setting is 2000. After the setting is completed, click the start button to test.
Test result
The tool will reflect the test situation in real time, including HTTP response status and response delay distribution. If multiple API are tested at the same time, the response status and response delay of each API will be displayed in real time in the details.
About how to use WebApi management and performance testing tool WebApiBenchmarks to share here, I hope that the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.