简体   繁体   中英

Gatling Report non-html Request Customization

In gatling, all the non-html resources being requested is reported in the result file (see attached image).How do I exclude these resource request from being reported in the result file to make the report look tidy.

Secondly, I have all the non-html resources blacklisted as below, but it still makes requests to get them. Is that the expected?

val httpProtocol = http
        .baseUrl("https://abc")     
        .inferHtmlResources(BlackList(""".*\.js""", """.*\.css""", """.*\.gif""", """.*\.jpeg""", """.*\.jpg""", """.*\.ico""", """.*\.woff""", """.*\.woff2""", """.*\.(t|o)tf""", """.*\.png""", """.*detectportal\.firefox\.com.*"""), WhiteList())  

在此处输入图片说明

  1. For exclude resources from report just add .silentResources to protocol. There you can read more about it https://gatling.io/docs/gatling/reference/current/http/protocol/#silencing

  2. Your resource contains characters after type. Example: ....css?v=d0edd... , so you need to rewrite regex: instead .*\\.js write .*\\.js.*

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM