开发者

FunkLoad one report for multiple requests

开发者 https://www.devze.com 2023-02-14 21:50 出处:网络
I am using FunkLoad to make some load test on my Django project. One of the page (I will name it /customer/ ) that I am currently try to benchmark \"does\" an AJAX request on page load to (/customer/j

I am using FunkLoad to make some load test on my Django project. One of the page (I will name it /customer/ ) that I am currently try to benchmark "does" an AJAX request on page load to (/customer/json/)

What I am currently doing in my benchmark is the following

self.get("/customer/", description="Customer page")
self.get("/customer/json/", description="Customer list")

that it's then reported with two graphs

I would like to have a single graph where /customer/json/ is considered as a "page resource" (let's say style.css)

Is it somehow feasible / am I missing something ?

---EDIT---

Here's my dirty patch to force my tests to load a list of media (self.media) every time I do a get request, I know that there are at least 4 good reasons to not do this way but for the moment I can live with it :)

class MyLoadTest(FunkLoadTestCase):

    def get(self, url, params=None, description=None, ok_codes=None):
        response = FunkLoadTestCase.get(self, url, params, description, ok_codes)
        if not self._simple_fetch:
            for media in self.media:
               开发者_如何学编程 self._connect("%s%s" % (self.server_url, media), [], self.ok_codes, "GET", "")
        return response


This is not yet feasible but this feature is part of the FunkLoad todo list: "Add a param to join to next request action"

I have not yet any precise schedule for this task, but I will defninitly implemenet it.

Regards

ben

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号