HTTP/1.1 405 Jmeter 中不允许的方法 Ajax 在 .net 中键入登录

HTTP/1.1 405 Method Not Allowed in Jmeter Ajax type Login in .net

无法执行负载测试,对于 Ajax 输入登录表单,它通过错误

Response headers: HTTP/1.1 405 Method Not Allowed Allow: GET, HEAD, OPTIONS, TRACE

for "Post" type form ,而在使用 "Get" type request 时会给出类似

的错误

Response headers: HTTP/1.1 301 Moved Permanently Content-Length: 298 Content-Type: text/html

My Platform login link 在模式类型 pop 上以 ajax 形式打开,但在正常平台(URL type Login)中执行相同的操作时它确实工作正常, 请提出任何建议, 提前致谢

查看 Exceeded maximum number of redirects: 5 错误,默认的最大重定向次数似乎不足以满足您的应用程序。

  1. 将下一行添加到 user.properties 文件(它位于 JMeter 安装的 /bin 文件夹下)

    httpsampler.max_redirects=10
    
  2. 重新启动 JMeter 以选择 属性
  3. 检查错误是否仍然存在。如果是 - 增加该值并重新启动 JMeter 一次。

不过这通常表示登录失败。您是否关联了动态参数,例如 VIEWSTATE? If not - check your recorded login request for dynamic parameters and handle them properly. See ASP.NET Login Testing with JMeter 指南以获得更详细的解释和端到端演练。