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

Restore: DependencyGraphSpec.Load(...) does not need JObject #9040

Closed
dtivel opened this issue Jan 9, 2020 · 0 comments · Fixed by NuGet/NuGet.Client#3239
Closed

Restore: DependencyGraphSpec.Load(...) does not need JObject #9040

dtivel opened this issue Jan 9, 2020 · 0 comments · Fixed by NuGet/NuGet.Client#3239
Assignees
Labels
Category:Quality Week Issues that should be considered for quality week Functionality:Restore Tenet:Performance Performance issues Type:Bug

Comments

@dtivel
Copy link
Contributor

dtivel commented Jan 9, 2020

DependencyGraphSpec.Json is unused except by tests. Holding both the Newtonsoft.Json.Linq.JObject and the NuGet representations of a dependency graph spec in memory is completely unnecessary.

Recommendations:

  1. Remove the DependencyGraphSpec.Json property.
  2. Update DependencyGraphSpec.Load(string) to deserialize a DependencyGraphSpec object incrementally using a Newtonsoft.Json.JsonTextReader and avoid deserializing completely into a JObject first.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Category:Quality Week Issues that should be considered for quality week Functionality:Restore Tenet:Performance Performance issues Type:Bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants