X Tutup
Skip to content

feat(diffing-broccoli-plugin): use optional fast-path for initial builds#1963

Closed
caitp wants to merge 2 commits intoangular:masterfrom
caitp:diffing-plugin-fastbuild
Closed

feat(diffing-broccoli-plugin): use optional fast-path for initial builds#1963
caitp wants to merge 2 commits intoangular:masterfrom
caitp:diffing-plugin-fastbuild

Conversation

@caitp
Copy link
Copy Markdown
Contributor

@caitp caitp commented May 18, 2015

Enable plugins to use a fast path for the initial build, which does not
require calculating a diff. Useful for plugins like Funnel or MergeTrees.

Blocked on #1961

@caitp
Copy link
Copy Markdown
Contributor Author

caitp commented May 18, 2015

Adding tests for the diffing plugin wrapper is problematic without support for class expressions and non-global class declarations (microsoft/TypeScript#497)

Previously, tree-differ would not correctly handle symlinks to deleted files, resulting in
an ENOENT errno being tossed by libuv.

This change fixes this to ensure that symlinks are safely handled, performantly.
@caitp caitp force-pushed the diffing-plugin-fastbuild branch 2 times, most recently from 9d2cdd1 to 88ec418 Compare May 18, 2015 19:30
… builds

Enable plugins to use a fast path for the initial build, which does not
require calculating a diff. Useful for plugins like Funnel or MergeTrees.
@IgorMinar
Copy link
Copy Markdown
Contributor

I don't think that we can do it like this because of several reasons:

  • in your change you didn't prime the tree-differ's figerprint cache, so the next time we run partial build, we'll actually report that everything changed which means that the second build will be slow
  • since all plugins I can think of need to do the first traversal anyway (or shouldn't be diffing plugins at all), it's pretty useful to get the filtered list of paths even for the first build

Given this, it doesn't seem very useful to have plugins implement this special api. What might be useful, is to pass "firstBuild" info into the rebuild function.

Take a look at #1906. I'm trying to implement the same thing there, but rather than changing what diffing plugins look like, I'm keeping track of whether a rebuild is first or not within the typescript plugin.

@IgorMinar
Copy link
Copy Markdown
Contributor

it seems that the tree-diffing commit from the PR was already merged, but now that all input trees are stable (#2051) we don't actually need this because broken symlinks indicate a bug in a plugin or build system.

the second commit is not needed, so I'm going to close this PR.

@angular-automatic-lock-bot
Copy link
Copy Markdown

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 6, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

X Tutup