• <tfoot id='8Qceu'></tfoot>
    <legend id='8Qceu'><style id='8Qceu'><dir id='8Qceu'><q id='8Qceu'></q></dir></style></legend>
      <bdo id='8Qceu'></bdo><ul id='8Qceu'></ul>

      <small id='8Qceu'></small><noframes id='8Qceu'>

    1. <i id='8Qceu'><tr id='8Qceu'><dt id='8Qceu'><q id='8Qceu'><span id='8Qceu'><b id='8Qceu'><form id='8Qceu'><ins id='8Qceu'></ins><ul id='8Qceu'></ul><sub id='8Qceu'></sub></form><legend id='8Qceu'></legend><bdo id='8Qceu'><pre id='8Qceu'><center id='8Qceu'></center></pre></bdo></b><th id='8Qceu'></th></span></q></dt></tr></i><div id='8Qceu'><tfoot id='8Qceu'></tfoot><dl id='8Qceu'><fieldset id='8Qceu'></fieldset></dl></div>

      1. 如何使用自动化脚本在一天中的不同时间测试我的 Web 应用程序的性能?

        时间:2023-09-17
              <tbody id='3tKiD'></tbody>
          1. <small id='3tKiD'></small><noframes id='3tKiD'>

            <tfoot id='3tKiD'></tfoot>

              <legend id='3tKiD'><style id='3tKiD'><dir id='3tKiD'><q id='3tKiD'></q></dir></style></legend>
              <i id='3tKiD'><tr id='3tKiD'><dt id='3tKiD'><q id='3tKiD'><span id='3tKiD'><b id='3tKiD'><form id='3tKiD'><ins id='3tKiD'></ins><ul id='3tKiD'></ul><sub id='3tKiD'></sub></form><legend id='3tKiD'></legend><bdo id='3tKiD'><pre id='3tKiD'><center id='3tKiD'></center></pre></bdo></b><th id='3tKiD'></th></span></q></dt></tr></i><div id='3tKiD'><tfoot id='3tKiD'></tfoot><dl id='3tKiD'><fieldset id='3tKiD'></fieldset></dl></div>
                  <bdo id='3tKiD'></bdo><ul id='3tKiD'></ul>
                  本文介绍了如何使用自动化脚本在一天中的不同时间测试我的 Web 应用程序的性能?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  基本上,我有一个使用 asp.net mvc 4 框架的 Web 应用程序.我使用 C# 作为我的后端.在一天中的不同时间,我注意到 Web 应用程序滞后或运行缓慢,但我想弄清楚一天中的哪些时间以及其他一些有助于确定如何优化应用程序的信息.我希望能够编写一个自动化脚本,在一天中的不同时间测试 Web 应用程序,并将其与应用程序的运行速度相关联.

                  Basically, I have a web application that uses asp.net mvc 4 framework. I use C# as my backend. At different times of the days, I noticed that the web application lags or is slow but I would like to figure out which times of day and some other information that would be useful in figuring out how to optimize the app. I want to be able to write an automated script that tests the web application at different times of the day and correlate it to the slowness of the application.

                  我对测试自动化还很陌生,所以我想知道从哪里开始编写这样的脚本.特别是对于 asp.net 网络应用程序?

                  I'm pretty new to test automation, so I was wondering where could I start with scripting such things. In particular for asp.net web apps?

                  推荐答案

                  你可以从几个角度来解决这个问题:

                  You can approach this from a few angles:

                  日志资料

                  日志页面呈现时间、数据库访问时间以及可能导致缓慢的任何其他时间.使用诸如 NLog 之类的日志框架,它允许您在日志中调整所需的详细信息量.

                  Log page rendering times, database access times, and times of anything else that might cause slowness. Use a logging framework such as NLog that allows you to dial up and down the amount of detail you need in the log.

                  在手动查看时获得更多细节

                  在您的网站中集成 MiniProfiler,并在您登录时打开它.

                  Integrate MiniProfiler in your website, and have it turn on when you log in.

                  衡量所选页面的实时性能

                  快速启动解决方案是使用现有的众多外部测试解决方案之一.Google 免费衡量网站性能以供选择广泛.

                  The fast-start solution is to use one of the many external testing solutions out there. Google measure website performance free for a broad selection.

                  如果您想自己构建它,特别是如果您想测试复杂的工作流程,我在 JMeter 方面取得了巨大成功.JMeter 的设计目标是对基准测试环境进行压力测试,而不是实时环境.但是,您可以使用它定期对您的生产系统运行测试,只要这些测试不会对系统造成太大压力而不会成为问题的原因.

                  If you want to build this yourself, and especially if you want to test complex workflows, I have had great success with JMeter. JMeter is designed with the goal of stress testing a benchmarking, not live, environment. However, you could use it to periodically run tests against your production system as long as the tests do not place so much stress on the system so as to be the cause of the problem.

                  使用托管解决方案来衡量页面性能的一个优势是,他们可以从世界不同地区进行衡量.在某些情况下,网络延迟可能是整个页面性能的重要组成部分.

                  One advantage of using a hosted solution to measure page performance is that they can measure it from different parts of the world. In some cases, the network latency can be an important component of overall page performance.

                  这篇关于如何使用自动化脚本在一天中的不同时间测试我的 Web 应用程序的性能?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:如何在 NUnit 中初始化 ConnectionStrings 集合 下一篇:命令行自动化——期望等效

                  相关文章

                  <tfoot id='m5ZSL'></tfoot>
                • <small id='m5ZSL'></small><noframes id='m5ZSL'>

                  <i id='m5ZSL'><tr id='m5ZSL'><dt id='m5ZSL'><q id='m5ZSL'><span id='m5ZSL'><b id='m5ZSL'><form id='m5ZSL'><ins id='m5ZSL'></ins><ul id='m5ZSL'></ul><sub id='m5ZSL'></sub></form><legend id='m5ZSL'></legend><bdo id='m5ZSL'><pre id='m5ZSL'><center id='m5ZSL'></center></pre></bdo></b><th id='m5ZSL'></th></span></q></dt></tr></i><div id='m5ZSL'><tfoot id='m5ZSL'></tfoot><dl id='m5ZSL'><fieldset id='m5ZSL'></fieldset></dl></div>

                      • <bdo id='m5ZSL'></bdo><ul id='m5ZSL'></ul>
                      <legend id='m5ZSL'><style id='m5ZSL'><dir id='m5ZSL'><q id='m5ZSL'></q></dir></style></legend>