-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Lazily download packages #2406
Lazily download packages #2406
Commits on Feb 19, 2016
-
This commit moves the SourceMap structure into the PackageSet structure, and simultaneously massively cuts down on the API surface area of PackageSet. It's intended that eventually a PackageSet will be a lazily loaded set of packages so we don't have to download everything all at once, and this is the commit in preparation of that.
Configuration menu - View commit details
-
Copy full SHA for 2d25fca - Browse repository at this point
Copy the full SHA 2d25fcaView commit details -
Refactor links validation to not use PackageSet
Eventually we may not have the entire set of packages resident in memory, so refactor the implementation to validate the `links` attribute in a demand driven way rather than all at once up front.
Configuration menu - View commit details
-
Copy full SHA for 5ea7a97 - Browse repository at this point
Copy the full SHA 5ea7a97View commit details -
Refactor build script output state initialization
Like with the previous refactor, remove the need to list all packages in a package set as we only need to lazily do this for the actual packages being compiled. Whenever a build script is requested to be executed is when we actually go and try to see if an override was in play.
Configuration menu - View commit details
-
Copy full SHA for 919cdde - Browse repository at this point
Copy the full SHA 919cddeView commit details -
Move the
get_package
step later when calculating depsFuture calls to `get_package` may end up actually downloading a package, so we want to defer this as late as possible to ensure that we don't download anything.
Configuration menu - View commit details
-
Copy full SHA for dc5671d - Browse repository at this point
Copy the full SHA dc5671dView commit details -
Remove the ability to list packages in PackageSet
If we download lazily, that's excessively wasteful!
Configuration menu - View commit details
-
Copy full SHA for 04c6c74 - Browse repository at this point
Copy the full SHA 04c6c74View commit details -
Configuration menu - View commit details
-
Copy full SHA for c024743 - Browse repository at this point
Copy the full SHA c024743View commit details -
Merge the get/download methods on the Source trait
Nothing currently implements the ability to more efficiently download a set of packages at any one point in time, and the download/get distinction isn't really used at all. We can always refactor later, but currently there's no benefit, nor can it really be seen what the possible benefit is, so let's just merge these two methods into one and have them operate on one id at a time.
Configuration menu - View commit details
-
Copy full SHA for 9cf7051 - Browse repository at this point
Copy the full SHA 9cf7051View commit details -
Configuration menu - View commit details
-
Copy full SHA for 0b256d3 - Browse repository at this point
Copy the full SHA 0b256d3View commit details
Commits on Feb 22, 2016
-
Implement a fallible PackageSet::get
This function will lazily download the package specified and fill a cell with that package. Currently this is always infallible because the `PackageSet` is initialized with all packages, but eventually this will not be true.
Configuration menu - View commit details
-
Copy full SHA for b56b61c - Browse repository at this point
Copy the full SHA b56b61cView commit details -
Move Context::get_package to returning a Result
The propagate all the `try!`-s needed upwards
Configuration menu - View commit details
-
Copy full SHA for 078b670 - Browse repository at this point
Copy the full SHA 078b670View commit details
Commits on Feb 26, 2016
-
Stop downloading all packages immediately
Instead delay all downloads until just before they're needed. This should ensure that we don't download any more packages than we really need to.
Configuration menu - View commit details
-
Copy full SHA for f994592 - Browse repository at this point
Copy the full SHA f994592View commit details