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

Make the PluginMapper lazy #11639

Merged
merged 1 commit into from Dec 14, 2022
Merged

Make the PluginMapper lazy #11639

merged 1 commit into from Dec 14, 2022

Conversation

Frassle
Copy link
Member

@Frassle Frassle commented Dec 13, 2022

What it says on the tin. Makes the PluginMapper lazy so for yaml we don't have to load every plugin in ~/.pulumi/plugins.

We don't load any provider plugins until we need to load an conversion mapping that we don't yet have.
Once we find the first provider that supplies a conversion mapping we stop looking for any more.

The only other improvement to make here that I think is possible is to shut down the providers after asking for their conversion mapping data. But that needs a rejig of how plugin.Host works, which is hard to do right now as it's a public api.

@pulumi-bot
Copy link
Contributor

pulumi-bot commented Dec 13, 2022

Changelog

[uncommitted] (2022-12-14)

Bug Fixes

  • [cli] Improve performance of convert to not try and load so many provider plugins.
    #11639

@Frassle Frassle force-pushed the fraser/lazyPluginMapper branch 2 times, most recently from 4b1df37 to 5534ad3 Compare December 14, 2022 14:56
Copy link
Member

@AaronFriel AaronFriel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

bors merge

@bors
Copy link
Contributor

bors bot commented Dec 14, 2022

Build succeeded:

@bors bors bot merged commit 5ec798e into master Dec 14, 2022
@bors bors bot deleted the fraser/lazyPluginMapper branch December 14, 2022 21:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants