LocustIO: User swarm
up vote
0
down vote
favorite
I am trying out Locust. Here you are able to swarm your system with simulated number of users within a specified hatch rate.
class UserBehavior(TaskSet):
def on_start(self):
self.login()
def login(self):
payload = {"grant_type": "password",
"username": self.my_user,
"password": self.my_pw,
...
}
}
headers = {'content-type': 'application/json'}
response = self.client.post("/rest/v10/oauth2/token", data=json.dumps(payload), headers=headers, catch_response=True)
self.token = response.json()['access_token']
@task(1)
def fetch_accounts(self):
headers = {'oauth-token': self.token}
response = self.client.get("/rest/v10/Accounts", headers=headers)
What is the implication of using:
A single
self.my_user
andself.my_pw
withNumber of users to simulate: 5
5 different
self.my_user
andself.my_pw
withNumber of users to simulate: 1
- 5 different
self.my_user
andself.my_pw
withNumber of users to simulate: 5
Which of the three provides a more reliable output for a load testing report?
python load-testing locust
add a comment |
up vote
0
down vote
favorite
I am trying out Locust. Here you are able to swarm your system with simulated number of users within a specified hatch rate.
class UserBehavior(TaskSet):
def on_start(self):
self.login()
def login(self):
payload = {"grant_type": "password",
"username": self.my_user,
"password": self.my_pw,
...
}
}
headers = {'content-type': 'application/json'}
response = self.client.post("/rest/v10/oauth2/token", data=json.dumps(payload), headers=headers, catch_response=True)
self.token = response.json()['access_token']
@task(1)
def fetch_accounts(self):
headers = {'oauth-token': self.token}
response = self.client.get("/rest/v10/Accounts", headers=headers)
What is the implication of using:
A single
self.my_user
andself.my_pw
withNumber of users to simulate: 5
5 different
self.my_user
andself.my_pw
withNumber of users to simulate: 1
- 5 different
self.my_user
andself.my_pw
withNumber of users to simulate: 5
Which of the three provides a more reliable output for a load testing report?
python load-testing locust
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I am trying out Locust. Here you are able to swarm your system with simulated number of users within a specified hatch rate.
class UserBehavior(TaskSet):
def on_start(self):
self.login()
def login(self):
payload = {"grant_type": "password",
"username": self.my_user,
"password": self.my_pw,
...
}
}
headers = {'content-type': 'application/json'}
response = self.client.post("/rest/v10/oauth2/token", data=json.dumps(payload), headers=headers, catch_response=True)
self.token = response.json()['access_token']
@task(1)
def fetch_accounts(self):
headers = {'oauth-token': self.token}
response = self.client.get("/rest/v10/Accounts", headers=headers)
What is the implication of using:
A single
self.my_user
andself.my_pw
withNumber of users to simulate: 5
5 different
self.my_user
andself.my_pw
withNumber of users to simulate: 1
- 5 different
self.my_user
andself.my_pw
withNumber of users to simulate: 5
Which of the three provides a more reliable output for a load testing report?
python load-testing locust
I am trying out Locust. Here you are able to swarm your system with simulated number of users within a specified hatch rate.
class UserBehavior(TaskSet):
def on_start(self):
self.login()
def login(self):
payload = {"grant_type": "password",
"username": self.my_user,
"password": self.my_pw,
...
}
}
headers = {'content-type': 'application/json'}
response = self.client.post("/rest/v10/oauth2/token", data=json.dumps(payload), headers=headers, catch_response=True)
self.token = response.json()['access_token']
@task(1)
def fetch_accounts(self):
headers = {'oauth-token': self.token}
response = self.client.get("/rest/v10/Accounts", headers=headers)
What is the implication of using:
A single
self.my_user
andself.my_pw
withNumber of users to simulate: 5
5 different
self.my_user
andself.my_pw
withNumber of users to simulate: 1
- 5 different
self.my_user
andself.my_pw
withNumber of users to simulate: 5
Which of the three provides a more reliable output for a load testing report?
python load-testing locust
python load-testing locust
edited Nov 19 at 0:09
asked Nov 16 at 2:58
Dee
118315
118315
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
up vote
1
down vote
accepted
Short answer
It depends on the behavior of your application under load.
Long answer
Generally, you want the simulated load to match the real load as closely as possible. In real load, it's not very likely that all the users would use the same username/password, nor that a single user would use many username/passwords. So I would say that your option 3 is probably the most realistic. But again, it depends on your application. If it turns out that your application behaves the same regardless of the number of distinct username/password combinations, then it might not matter at all.
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
accepted
Short answer
It depends on the behavior of your application under load.
Long answer
Generally, you want the simulated load to match the real load as closely as possible. In real load, it's not very likely that all the users would use the same username/password, nor that a single user would use many username/passwords. So I would say that your option 3 is probably the most realistic. But again, it depends on your application. If it turns out that your application behaves the same regardless of the number of distinct username/password combinations, then it might not matter at all.
add a comment |
up vote
1
down vote
accepted
Short answer
It depends on the behavior of your application under load.
Long answer
Generally, you want the simulated load to match the real load as closely as possible. In real load, it's not very likely that all the users would use the same username/password, nor that a single user would use many username/passwords. So I would say that your option 3 is probably the most realistic. But again, it depends on your application. If it turns out that your application behaves the same regardless of the number of distinct username/password combinations, then it might not matter at all.
add a comment |
up vote
1
down vote
accepted
up vote
1
down vote
accepted
Short answer
It depends on the behavior of your application under load.
Long answer
Generally, you want the simulated load to match the real load as closely as possible. In real load, it's not very likely that all the users would use the same username/password, nor that a single user would use many username/passwords. So I would say that your option 3 is probably the most realistic. But again, it depends on your application. If it turns out that your application behaves the same regardless of the number of distinct username/password combinations, then it might not matter at all.
Short answer
It depends on the behavior of your application under load.
Long answer
Generally, you want the simulated load to match the real load as closely as possible. In real load, it's not very likely that all the users would use the same username/password, nor that a single user would use many username/passwords. So I would say that your option 3 is probably the most realistic. But again, it depends on your application. If it turns out that your application behaves the same regardless of the number of distinct username/password combinations, then it might not matter at all.
answered Nov 19 at 0:35
Flight Odyssey
1,6731218
1,6731218
add a comment |
add a comment |
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53330791%2flocustio-user-swarm%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown