Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to scale maxVUs down in externally-controlled executor #1511

Closed
imiric opened this issue Jun 23, 2020 · 1 comment
Closed

Unable to scale maxVUs down in externally-controlled executor #1511

imiric opened this issue Jun 23, 2020 · 1 comment
Assignees
Milestone

Comments

@imiric
Copy link
Contributor

imiric commented Jun 23, 2020

In v0.26.2 it was possible to scale maxVUs arbitrarily using the REST API or the helper scale -m command.

On the current new-schedulers branch (2f150f2), it's only possible to scale maxVUs up, but not back down, and no errors are returned when attempting to do so.

Environment

  • k6 version: new-schedulers (2f150f2)
  • OS and version: Linux
  • Docker version and image, if applicable:

Expected Behavior

  • It should be possible to scale maxVUs down to the initial maxVUs setting.
  • Trying to scale maxVUs below the initial maxVUs setting should return an error. This is a slight breaking change from 1007 in order to allow VU sharing between executors.

Actual Behavior

k6 scale -m N where N is below the currently set maxVUs value (whether that was the initial value or one scaled up to with k6 scale -m previously) is silently ignored, and the executor remains with the previous value.

Steps to Reproduce the Problem

  1. Given the following script.js:
import { sleep } from 'k6';

export let options = {
  scenarios: {
    adjustable_at_will: {
      executor: "externally-controlled",
      vus: 0,
      maxVUs: 20,
      duration: "10m",
    },
  }
};

export default function () {
  sleep(1);
}
  1. Run k6 run script.js.
  2. In another terminal, run k6 scale -m 50. Note the vus-max: "50" in the output.
  3. Run k6 scale -m 20. Note that vus-max remains at 50.
  4. Run k6 scale -m 10. Note that vus-max remains at 50 and no error is returned.

Also, make sure that the behavior of scale -u is also consistent, and returns errors in the same way as v0.26.2.

@imiric imiric added this to the v0.28.0 milestone Jun 23, 2020
@imiric imiric self-assigned this Jun 23, 2020
@imiric imiric modified the milestones: v0.28.0, v0.27.0 Jun 23, 2020
imiric pushed a commit that referenced this issue Jun 24, 2020
imiric pushed a commit that referenced this issue Jun 25, 2020
imiric pushed a commit that referenced this issue Jun 25, 2020
@imiric
Copy link
Contributor Author

imiric commented Jun 30, 2020

Closed by #1517.

@imiric imiric closed this as completed Jun 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant