ember-cli / ember-cli/ember-cli-htmlbars

Parallel compilations appears to troll hash-for-dep cache

未關閉
#623 6 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視
主要語言
JavaScript
星號
77
分支
65
PR 合併指標
30 天內沒有已合併 PR

描述

I noticed that rebuild time for a particular addon (with a lot of handlebars AST transforms) recently ballooned from a few seconds to 80-90 seconds.

It appears that something (I'm guessing the parallel compile) is causing `hash-for-dep` to be invoked as multiple modules, instead of a single module. Since the `hash-for-dep` cache [is module scoped](https://github.com/stefanpenner/hash-for-dep/blob/master/index.js#L10), invoking as multiple modules means that the cache is effectively useless.

EDIT: The cache was only created once in `ember-cli-htmlbars-inline-precompile@1.0.2`. When I upgraded to `1.0.3` is when the multiple caches thing happened. There were other things also upgraded though at the same time.

cc @stefanpenner

貢獻指南

這個儲存庫沒有索引到貢獻指南

研究方向

從回報的 ember-cli-htmlbars-inline-precompile 1.0.2 到 1.0.3 的相依性變更開始,檢查 hash-for-dep 的 index.js 第 10 行。追蹤平行編譯如何呼叫 hash-for-dep,並比較重建過程中建立的快取執行個體。完成的標準是說明清楚快取行為和 80–90 秒重建回歸問題,並透過適當的回歸檢查加以涵蓋。

由索引模型根據 Issue 內容生成。

評估

技術堆疊
javascript
領域
build-system, performance
Issue 類型
缺陷
難度
4/5
預估耗時
3-5 天
活躍度
停滯
描述清晰度
需要釐清
新手友好度
30/100

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。