Repository navigation
Conversation
Signed-off-by: Guillaume de Rouville <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The workspace compiler discovery added in #64 lists every checkout filename on each module call. Each returned filename becomes a Dagger cache entry, so a large repository creates a lot of extra engine work.
In dagger/dagger#14664, the Java release check has 614,508 spans, compared with 4,057 on main. Most of the extra spans come from reading those filename lists. Several checks then report that the engine became unresponsive. This confirms the extra work; it does not establish exactly how the Cloud engine stopped.
This changes discovery to return the import and embed patterns from Go metadata and pass them directly to
ws.Directory(...). It selects assembly/header files alongside imported packages, excludes dependency tests, and keeps the module's own source. It applies during generation and runtime compilation.The caching contract stays the same: each affected call receives
ws, current compiler inputs are selected again, and compilation can reuse unchanged file contents. No engine change is needed.Validation: discovery and all template tests pass. On beta.17, the same engine module call drops from 130,168 spans to 1,725 and still returns the correct result. Changing only an external embedded file changes the fixture's result from
onetotwo, both directly and through a sibling client, with no changes to either generated entrypoint. Full Cloud CI is still required to verify that the engine disconnects stop.