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

(PUP-11899) Log which server we request a catalog from #9126

Conversation

cthorn42
Copy link
Collaborator

When a catalog is requested, log which server is attempted to be used and if an IP address is resolvable display that.

Copy link
Contributor

@b4ldr b4ldr left a comment

Choose a reason for hiding this comment

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

minor fly by comments

spec/unit/indirector/catalog/rest_spec.rb Outdated Show resolved Hide resolved
spec/unit/indirector/catalog/rest_spec.rb Outdated Show resolved Hide resolved
@cthorn42 cthorn42 force-pushed the maint/7.x/PUP-11899_log_server_when_requesting_config branch from 9ab5e87 to 44507e0 Compare October 13, 2023 16:34
@cthorn42 cthorn42 marked this pull request as ready for review October 17, 2023 15:50
@cthorn42 cthorn42 requested a review from a team as a code owner October 17, 2023 15:50
When a catalog is requested, log which server is attempted to be used and if an
IP address is resolvable display that.
@cthorn42 cthorn42 force-pushed the maint/7.x/PUP-11899_log_server_when_requesting_config branch from 44507e0 to 71c7cd2 Compare October 20, 2023 19:32
@joshcooper
Copy link
Contributor

Success case looks good:

Info: Retrieving pluginfacts
Info: Retrieving plugin
Notice: Requesting catalog from causal-diver.X.X.X:8140 (X.X.X.X)
Info: Caching catalog for localhost
Info: Applying configuration version '1698102188'
Notice: Applied catalog in 0.03 seconds

Since pluginsync happens before the catalog is requested, if there is going to be a failure connecting to the compiler service, then it's most often going to happen earlier on. There is a small chance pluginsync could succeed, but then we fail to resolve the IP before making the catalog request. In that case, we'll rescue the resolver exception and omit the IP. That seems fine, we made our best effort.

@mhashizume mhashizume merged commit 19c3f93 into puppetlabs:7.x Oct 24, 2023
13 checks passed
@joshcooper joshcooper added the enhancement New feature or request label Nov 15, 2023
robbat2 added a commit to robbat2/puppetlabs-tagmail that referenced this pull request Mar 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants