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

URL Directory, and Multi-File Support for Locustfile Distribution #2766

Merged

Conversation

andrewbaldwin44
Copy link
Collaborator

Proposal

  1. Move some functions to utility files to permit re-usability and to help simplify the argument parser file
  2. Update the logic for master sending locustfiles to the workers so that it can support URLs, directories, and multi-files
  3. Re-use parse_locustfile_paths for workers receiving file paths from master

Opening as a draft, if this looks good I'll create some tests for it

@cyberw
Copy link
Collaborator

cyberw commented Jun 25, 2024

What do you think @DennisKrone ?

@cyberw
Copy link
Collaborator

cyberw commented Jul 1, 2024

Looks pretty reasonable. Just a few things: parse_locustfile_paths_from_master isnt very descriptive of what it does (actually downloading files for instance). And needs type hints. Its a bit sad that it is a breaking protocol change.

@cyberw
Copy link
Collaborator

cyberw commented Jul 1, 2024

Are you losing the ability to detect changes in the file contents? (_old_file_contents) That would be bad.

@andrewbaldwin44 andrewbaldwin44 force-pushed the feature/url-file-distribution branch 3 times, most recently from b87f8a3 to 627470e Compare July 4, 2024 18:05
@andrewbaldwin44 andrewbaldwin44 marked this pull request as ready for review July 4, 2024 18:06
@andrewbaldwin44 andrewbaldwin44 force-pushed the feature/url-file-distribution branch from 627470e to 2b6037f Compare July 4, 2024 18:27
locust/argument_parser.py Outdated Show resolved Hide resolved
locust/env.py Outdated Show resolved Hide resolved
locust/runners.py Outdated Show resolved Hide resolved
@andrewbaldwin44 andrewbaldwin44 force-pushed the feature/url-file-distribution branch 10 times, most recently from 4ce5891 to 6d8aa3a Compare July 11, 2024 19:19
@andrewbaldwin44 andrewbaldwin44 force-pushed the feature/url-file-distribution branch from 6d8aa3a to 1a3a9dc Compare July 31, 2024 13:10
@andrewbaldwin44 andrewbaldwin44 merged commit 3a5c33b into locustio:master Aug 1, 2024
14 checks passed
@andrewbaldwin44 andrewbaldwin44 deleted the feature/url-file-distribution branch August 1, 2024 13:28
@cyberw cyberw changed the title URL Directory, and Multi-File Support for File Distribution URL Directory, and Multi-File Support for Locustfile Distribution Aug 5, 2024
apereocas-bot referenced this pull request in apereo/cas Aug 5, 2024
[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [locust](https://locust.io/) ([source](https://togithub.com/locustio/locust)) | `==2.30.0` -> `==2.31.1` | [![age](https://developer.mend.io/api/mc/badges/age/pypi/locust/2.31.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/pypi/locust/2.31.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/pypi/locust/2.30.0/2.31.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/locust/2.30.0/2.31.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

<details>
<summary>locustio/locust (locust)</summary>

### [`v2.31.1`](https://togithub.com/locustio/locust/blob/HEAD/CHANGELOG.md#2311-2024-08-05)

[Compare Source](https://togithub.com/locustio/locust/compare/2.31.0...2.31.1)

[Full Changelog](https://togithub.com/locustio/locust/compare/2.31.0...2.31.1)

**Merged pull requests:**

-   Fix issue with downloading HTML report, update package.json for webui build [#&#8203;2834](https://togithub.com/locustio/locust/pull/2834) ([andrewbaldwin44](https://togithub.com/andrewbaldwin44))

### [`v2.31.0`](https://togithub.com/locustio/locust/releases/tag/2.31.0)

#### What's Changed

-   Fix HTML Report Stats Table by [@&#8203;andrewbaldwin44](https://togithub.com/andrewbaldwin44) in [https://github.com/locustio/locust/pull/2817](https://togithub.com/locustio/locust/pull/2817)
-   URL Directory, and Multi-File Support for Locustfile Distribution by [@&#8203;andrewbaldwin44](https://togithub.com/andrewbaldwin44) in [https://github.com/locustio/locust/pull/2766](https://togithub.com/locustio/locust/pull/2766)
-   Locust UI Charts Should Change Color Based on Theme by [@&#8203;andrewbaldwin44](https://togithub.com/andrewbaldwin44) in [https://github.com/locustio/locust/pull/2815](https://togithub.com/locustio/locust/pull/2815)
-   Locust UI as a Module by [@&#8203;andrewbaldwin44](https://togithub.com/andrewbaldwin44) in [https://github.com/locustio/locust/pull/2804](https://togithub.com/locustio/locust/pull/2804)
-   Integrations for Locust Cloud by [@&#8203;andrewbaldwin44](https://togithub.com/andrewbaldwin44) in [https://github.com/locustio/locust/pull/2824](https://togithub.com/locustio/locust/pull/2824)
-   Simplify fixed_count Users generation in UsersDispatcher.\_user_gen by [@&#8203;tdadela](https://togithub.com/tdadela) in [https://github.com/locustio/locust/pull/2783](https://togithub.com/locustio/locust/pull/2783)
-   Log a message if total fixed_count is higher than number of users to spawn by [@&#8203;cyberw](https://togithub.com/cyberw) in [https://github.com/locustio/locust/pull/2793](https://togithub.com/locustio/locust/pull/2793)
-   Bump Node by [@&#8203;andrewbaldwin44](https://togithub.com/andrewbaldwin44) in [https://github.com/locustio/locust/pull/2825](https://togithub.com/locustio/locust/pull/2825)
-   Improve Echarts and Expose Line and Axis Configuration by [@&#8203;andrewbaldwin44](https://togithub.com/andrewbaldwin44) in [https://github.com/locustio/locust/pull/2826](https://togithub.com/locustio/locust/pull/2826)
-   Github Actions: Use node 20.x (fix PyPI Release and pre-Release Steps) by [@&#8203;andrewbaldwin44](https://togithub.com/andrewbaldwin44) in [https://github.com/locustio/locust/pull/2828](https://togithub.com/locustio/locust/pull/2828)
-   Fix docker build for release by [@&#8203;cyberw](https://togithub.com/cyberw) in [https://github.com/locustio/locust/pull/2830](https://togithub.com/locustio/locust/pull/2830)

**Full Changelog**: locustio/locust@2.30.0...2.31.0

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "after 10pm every weekday,before 6am every weekday" (UTC), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR was generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View the [repository job log](https://developer.mend.io/github/apereo/cas).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy40NDAuNyIsInVwZGF0ZWRJblZlciI6IjM3LjQ0MC43IiwidGFyZ2V0QnJhbmNoIjoibWFzdGVyIiwibGFiZWxzIjpbIkJvdCIsIlJlbm92YXRlIl19-->
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants