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

chore(gatsby-plugin-sharp): move image processing to a worker #19591

Merged
merged 3 commits into from
Nov 18, 2019

Conversation

wardpeet
Copy link
Contributor

Description

Starting implementing new jobs api. Move logic to separate worker file so it can run in parallel.

Image processing didn't check the outputFile correctly so re-created all images all over again on each change.

Related Issues

Related to #18934
Fixes #19576

@wardpeet wardpeet requested a review from a team as a code owner November 18, 2019 14:26
@wardpeet wardpeet changed the title Feat/sharp worker fixed chore(gatsby-plugin-sharp): move image processing to a worker Nov 18, 2019
@m-allanson
Copy link
Contributor

Can you point out the differences between this PR and #18934?

@wardpeet
Copy link
Contributor Author

wardpeet commented Nov 18, 2019

@m-allanson

These 2 commits
e7aab0e
6ae6930

@wardpeet wardpeet closed this Nov 18, 2019
@wardpeet wardpeet reopened this Nov 18, 2019
@m-allanson
Copy link
Contributor

Thanks! (this answer also known as "Mike, read the commit messages" 😅)

Copy link
Contributor

@sidharthachatterjee sidharthachatterjee left a comment

Choose a reason for hiding this comment

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

Yay! Thanks! 🎉

@sidharthachatterjee sidharthachatterjee merged commit c516789 into gatsbyjs:master Nov 18, 2019
@wardpeet wardpeet deleted the feat/sharp-worker-fixed branch November 20, 2019 05:41
@fodkastir
Copy link

@wardpeet I have tried v2.3.2 and the total image gatsby tries to generate an increase from ~3000 to ~13000. This behavior starts to show up after I upgrade to the version above 2.3.

@wardpeet
Copy link
Contributor Author

@fodkastir, i'm not able to reproduce it. Might be just a visual bug.

This should fix it #19717

@wardpeet
Copy link
Contributor Author

I currently have a fix located at npm install --save-dev gatsby-plugin-sharp@sharp-cache

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.

Number of generated thumbnails seems huge and crashes build in Windows
4 participants