Skip to content

salt.renderers.gpg: Cache GPG data if gpg_cache=True #55772

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

Merged
merged 1 commit into from
May 18, 2020

Conversation

sathieu
Copy link
Contributor

@sathieu sathieu commented Dec 31, 2019

What does this PR do?

  • Cache gpg data if requested

NB : pillar_cache doesn't work reliably as it can return obsolete data.

What issues does this PR fix or reference?

Previous Behavior

Doing salt <matcher> pillar.items matching 60 minions with several pillars encrypted, we got timeout error after 45s.

New Behavior

The same command returns within 2 to 4 seconds.

Tests written?

Yes

Commits signed with GPG?

No

@sathieu sathieu requested a review from a team as a code owner December 31, 2019 14:18
@ghost ghost requested a review from Akm0d December 31, 2019 14:29
@sathieu sathieu force-pushed the gpg_perfs branch 2 times, most recently from 521bde1 to 08274c3 Compare December 31, 2019 15:30
Copy link
Contributor

@dwoz dwoz left a comment

Choose a reason for hiding this comment

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

@sathieu It looks like the test failures are related to this change, please take a look.

@sathieu
Copy link
Contributor Author

sathieu commented Jan 2, 2020

@dwoz Yes, this AttributeError: 'module' object has no attribute 'errors' error is strange because I don't have it, and this is per doc.

@sathieu sathieu changed the title GPG renderer security and performance improvements GPG renderer performance improvements (cache GPG data if gpg_cache=True) Jan 7, 2020
@sathieu sathieu changed the title GPG renderer performance improvements (cache GPG data if gpg_cache=True) salt.renderers.gpg: Cache GPG data if gpg_cache=True Jan 7, 2020
@sathieu
Copy link
Contributor Author

sathieu commented Jan 7, 2020

@dwoz I've removed the Use Python bindings when available, the most usefull feature being gpg_cache.

@sathieu
Copy link
Contributor Author

sathieu commented May 14, 2020

@dwoz Please review again, the failing tests are not related to this PR.

@sathieu
Copy link
Contributor Author

sathieu commented May 14, 2020

@dwoz @Akm0d Please review, now al checks have passed ✌️ .

@dwoz dwoz merged commit faee403 into saltstack:master May 18, 2020
@sathieu sathieu deleted the gpg_perfs branch May 30, 2020 20:17
@sathieu sathieu mentioned this pull request Jun 25, 2020
3 tasks
sathieu added a commit to sathieu/salt that referenced this pull request Jul 9, 2020
dwoz pushed a commit that referenced this pull request Jul 13, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ZRelease-Sodium retired label
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants