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

Avoid unnecessary checking for already checked links #2305

Merged
merged 5 commits into from
Sep 24, 2023

Conversation

biodranik
Copy link
Contributor

@biodranik biodranik commented Sep 12, 2023

Fixes #2298

For localized Organic Maps zola site the time for zola check link checking has reduced from 3 minutes to less than 1 minute.

I'm new to Rust, so any ideas on how to write better code are welcome!

@biodranik biodranik force-pushed the faster-links-checking branch 2 times, most recently from 908ee39 to 042de39 Compare September 13, 2023 17:47
components/site/src/link_checking.rs Outdated Show resolved Hide resolved
components/site/src/link_checking.rs Outdated Show resolved Hide resolved
@biodranik
Copy link
Contributor Author

@Keats done, PTAL

@Raymi306
Copy link
Contributor

To fix the CI issue, you can run cargo fmt

@biodranik
Copy link
Contributor Author

Thanks! Also brew install rustfmt is needed first :) PTAL.

@Keats
Copy link
Collaborator

Keats commented Sep 17, 2023

Some of the code can be cleaned up a bit, I'll post a link to the commit after doing it.

@biodranik
Copy link
Contributor Author

@Keats Thanks! You can also leave suggestions if it's easier )

@Keats Keats merged commit 1b423fb into getzola:next Sep 24, 2023
5 checks passed
@biodranik biodranik deleted the faster-links-checking branch September 24, 2023 20:17
technimad pushed a commit to technimad/zola that referenced this pull request Sep 30, 2023
* Fixed "unnecessary mut" warning

* Fixed minor typo

* Use more than 8 threads for links checking if hardware supports it

* Fixed failing azure Linux check

* Avoid unnecessary HTTP requests to the same, already checked links
Keats pushed a commit that referenced this pull request Dec 18, 2023
* Fixed "unnecessary mut" warning

* Fixed minor typo

* Use more than 8 threads for links checking if hardware supports it

* Fixed failing azure Linux check

* Avoid unnecessary HTTP requests to the same, already checked links
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.

3 participants