Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
I noticed that the 1Password providers were very slow, and the amount of time it took to evaluate a YAML file with 1Password references increased approximately linearly with the number of 1Password references, which suggested to me that work was being unnecessarily repeated. I found that the providers have a `client` field, and its assigned to, but we never check if its set, so we always create a new client. This PR updates the providers so that if the `client` is not set one will be created, and if one has been set then it'll be reused. For my YAML file with 26 1Password references, this change reduced the time it took to evaluate the file from 29 seconds to 11 seconds. There is still room for improvement (e.g. by parallelizing the evaluation of each ref, improved caching, etc.), but this seems like a simple and worthwhile change on its own. Signed-off-by: Will Da Silva <[email protected]>
- Loading branch information