> For the complete documentation index, see [llms.txt](https://test-730.gitbook.io/openrasp-documents-old/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://test-730.gitbook.io/openrasp-documents-old/main-5.md).

# 性能测试

在线上部署之前，请先联系QA在测试环境进⾏压⼒测试，并关注下⾯这些问题:

* 平均请求响应时间下降多少？
* 如果CPU打满，QPS会下降多少？

我们测试了大量的业务系统，也测试了多个开源应⽤；很多金融客户帮助我们进行了全链路的压测。性能影响通常\
在 `2%~4%` 之间，接口响应延迟在 `2~8ms` 之间，完全可以接受。

如果你发现实际的性能损耗超过了 `5%`，请参考[性能调试](https://rasp.baidu.com/doc/hacking/debug.html#java-perf) 文档，采集调试数据，然后加⼊QQ群联系群主。我们会在第⼀时间进⾏分析，并尽快解决问题。

本报告只是抛砖引玉，如果你有任何疑问，欢迎加入QQ技术讨论群一起探讨。

### Java 版本 <a href="#java" id="java"></a>

#### 测试报告#1 - 某金融结算系统 <a href="#java-1" id="java-1"></a>

| 指标   | 未安装 OpenRASP | 安装 OpenRASP | 影响比例   |
| ---- | ------------ | ----------- | ------ |
| QPS  | 89.2         | 86.3        | -3.25% |
| 响应时间 | 1.33s        | 1.406s      |        |

#### 测试报告#2 - 某后台查询系统 <a href="#java-2" id="java-2"></a>

| 指标   | 未安装 OpenRASP | 安装 OpenRASP | 影响比例   |
| ---- | ------------ | ----------- | ------ |
| TPS  | 2062         | 2026        | -1.74% |
| 响应时间 | 0.0039s      | 0.004s      |        |

#### 测试报告#3 - JeeCMS <a href="#java-3" id="java-3"></a>

JeeCMS 本身存在性能瓶颈，在不安装OpenRASP的情况下，当并发达到15，2个CPU已经打满，所以我们无法模拟更多用户

| 指标   | 未安装 OpenRASP | 安装 OpenRASP | 影响比例  |
| ---- | ------------ | ----------- | ----- |
| QPS  | 280          | 269         | -3.9% |
| 响应时间 | 100ms        | 105ms       |       |

### PHP 版本 <a href="#php" id="php"></a>

#### 测试报告#1 - discuz x3.2 <a href="#php-1" id="php-1"></a>

php-fpm 配置为，

* pm=static
* max\_children=100
* max\_requests=1000

测试结果

| 指标   | 未安装 OpenRASP | 安装 OpenRASP | 影响比例   |
| ---- | ------------ | ----------- | ------ |
| QPS  | 20550        | 20200       | -1.7%  |
| 响应时间 | 233ms        | 237ms       | -1.72% |

#### 测试报告#2 - wordpress 4.9.4 <a href="#php-2" id="php-2"></a>

php-fpm 配置为，

* pm=static
* max\_children=100
* max\_requests=1000

测试结果

| 指标   | 未安装 OpenRASP | 安装 OpenRASP | 影响比例   |
| ---- | ------------ | ----------- | ------ |
| QPS  | 55.09        | 54.02       | -1.94% |
| 响应时间 | 1.43s        | 1.46s       | -2.1%  |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://test-730.gitbook.io/openrasp-documents-old/main-5.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
