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

Cache URLFilter results of string inputs per site #7990

Merged
merged 5 commits into from Apr 13, 2020

Conversation

ashmaroli
Copy link
Member

Summary

Currently on master, the results for relative_url and absolute_url are cached per Liquid:Context instances. But this is insufficient for string inputs which are context-independent.

This PR proposes to cache such results per Jekyll::Site instance.

@ashmaroli

This comment has been minimized.

@ashmaroli ashmaroli added this to the undetermined milestone Feb 2, 2020
@DirtyF DirtyF requested a review from a team February 3, 2020 12:00
@ashmaroli
Copy link
Member Author

Comparisons

Verbose build with --profile summary

--- master https://travis-ci.org/jekyll/jekyll/jobs/649458789
+++ PR     https://travis-ci.org/jekyll/jekyll/jobs/649466901

$ bundle exec jekyll build -s docs --verbose --profile

- done in 6.351 seconds.
+ done in 5.358 seconds.

Memory Profile summary

--- master https://travis-ci.org/jekyll/jekyll/jobs/649458790
+++ PR     https://travis-ci.org/jekyll/jekyll/jobs/649466902

- Total allocated: 396.91 MB (3624650 objects)
+ Total allocated: 384.73 MB (3490922 objects)
- Total retained:  19.80 MB (107264 objects)
+ Total retained:  19.74 MB (106858 objects)

@ashmaroli ashmaroli modified the milestones: undetermined, 4.1 Feb 12, 2020
@ashmaroli ashmaroli marked this pull request as ready for review February 19, 2020 18:51
@ashmaroli
Copy link
Member Author

Memory Profile summary

--- master https://travis-ci.org/github/jekyll/jekyll/jobs/669670236
+++ PR     https://travis-ci.org/github/jekyll/jekyll/jobs/669699899

- Total allocated: 370.27 MB (3400304 objects)
+ Total allocated: 348.19 MB (3168258 objects)
- Total retained:  19.09 MB (108407 objects)
+ Total retained:  18.97 MB (107431 objects)

/cc @DirtyF 😃

Copy link
Member

@DirtyF DirtyF left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool, it's working great.

@DirtyF
Copy link
Member

DirtyF commented Apr 13, 2020

@jekyllbot: merge +fix

@jekyllbot jekyllbot merged commit 9c0c518 into jekyll:master Apr 13, 2020
jekyllbot added a commit that referenced this pull request Apr 13, 2020
@ashmaroli ashmaroli deleted the cache-url-filters-site branch April 13, 2020 10:11
@jekyll jekyll locked and limited conversation to collaborators Apr 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants