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

(GH-1080) Fixes "missing custom" in sensu_enterprise_dashboard_config #1081

Closed
wants to merge 1 commit into from

Conversation

jwoytek
Copy link

@jwoytek jwoytek commented Feb 15, 2019

Pull Request Checklist

Description

Every other parameter defined in sensu_enterprise_dashboard_config has a getter that returns the config object. I'm not sure why custom had something different, but this appears to cause issues with applying the sensu config. I do not claim to understand the purpose of having a reject in the getter, but applying this fix does not seem to cause problems, and a bad custom config is still caught.

Related Issue

Fixes #1080

Motivation and Context

How Has This Been Tested?

This has been tested in our open source Puppet 6.2 master server environment across multiple RHEL7 client systems.

General

  • Update README.md with any necessary configuration snippets

  • New parameters are documented

  • New parameters have tests

  • Tests pass - bundle exec rake validate lint spec

@treydock
Copy link
Collaborator

I think this could have unintended consequences. The purpose of is_property? was to avoid having custom include values that are already properties for the type.

@ghoneycutt
Copy link
Collaborator

@jwoytek could you provide an acceptance test along with this? We want to see that this fails before your patch and succeeds after.

@treydock
Copy link
Collaborator

@jwoytek Based on conversation in #1080 I am not convinced this change would actually fix your problem. Also the custom key is supposed to be set to any keys that exist in the JSON that are not known properties. This change would only assign custom to items nested under custom key which is not the intended behavior of the custom property.

@treydock treydock closed this Feb 26, 2019
@jwoytek
Copy link
Author

jwoytek commented Feb 27, 2019

Yeah, I'm sorry, @ghoneycutt and @treydock. I should have closed this after we discussed things in the associated ticket. It appears to have been a type caching issue in the upstream puppet master. Asking the module to return the potentially-empty object instead of trying to do a validity check an undefined object DID fix the problem I was having, but the bug wasn't in the sensu module code. I had to get the upstream server manager to reset their server and ensure that the type cache was rebuilt, which they had not done after upgrading the module.

I'm going to shortly delete the branch associated with this PR, but I'm going to leave the original bug with some additional details so that it can be found by others who might be experiencing the same problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment