0

I am new to webapi calls. I have a bunch of webapi calls happening. I would like to check the performance of these calls using the locustio and swarm the users with the calls and record the time for each webapi call taken..

Below is the locustfile i have written.

from locust import HttpLocust, TaskSet, task

class MyTaskSet(TaskSet):
    @task

    def my_task(self):
        print "executing my_task"
        self.client.get('https://piprdweb.cds.com/piwebapi/streams/A0Ej3OLt_2RH0mvwiXA5DULmw-UVswK3W5hGvHhJaxRW7Owqi14iFv8x0KZLamRlaPPawUElQUkRBRlxQQ0dfUlNCT1BcUklHLjM0MlxCT1BTRU5UUllcU0lHTkFMU1xTVEFDSyBPTkVcWUVMTE9XIFBPRHxDQU4gMSBIVU1JRElUWSAtIFlFTExPVyBQT0Q/value?time=*-5s')

class MyLocust(HttpLocust):
    task_set = MyTaskSet
    min_wait = 5000
    max_wait = 15000

Next when i am running the locust --host https://piprdweb.cds.com/piwebapi/ i am getting the below error

AttributeError [2017-02-06 15:14:26,378] srvgdyplmvrc01.nov.com/ERROR/stderr: : [2017-02-06 15:14:26,378] srvgdyplmvrc01.nov.com/ERROR/stderr: 'module' object has no attribute 'NSIG'

Please correct me if i am making a mistake .

  • Interesting, there is an issue for it: https://github.com/locustio/locust/issues/518 – Piotr Dawidiuk Feb 07 '17 at 20:00
  • we've ran performance tests using locust.io for API services with no problems, can you specify what environment and python version you are running on? Any additional details would be helpful. ie. virtualenv, etc. – pratik Apr 22 '17 at 23:38

0 Answers0