Asp.net web api 使用hocust、.io检查webapi性能
我不熟悉webapi调用。我有一大堆webapi调用正在发生。我想使用locustio检查这些调用的性能,并用这些调用群集用户,并记录每个webapi调用的时间 下面是我写的文件Asp.net web api 使用hocust、.io检查webapi性能,asp.net-web-api,locust,Asp.net Web Api,Locust,我不熟悉webapi调用。我有一大堆webapi调用正在发生。我想使用locustio检查这些调用的性能,并用这些调用群集用户,并记录每个webapi调用的时间 下面是我写的文件 from locust import HttpLocust, TaskSet, task class MyTaskSet(TaskSet): @task def my_task(self): print "executing my_task" self.client.
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
接下来,当我运行蝗虫主机时,我得到以下错误
属性错误
[2017-02-06 15:14:26378]srvgdyplmvrc01.nov.com/ERROR/stderr::
[2017-02-06 15:14:26378]srvgdyplmvrc01.nov.com/ERROR/stderr:“模块”对象没有属性“NSIG”
如果我犯了错误,请纠正我 有趣的是,这里有一个问题:我们已经使用locust.io对API服务运行了性能测试,没有问题,您能指定您正在运行的环境和python版本吗?任何额外的细节都会有帮助。例如,virtualenv等。