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

checks: removing type => metric doesn't remove it from the config json #166

Closed
matthewbarr opened this issue Mar 5, 2014 · 4 comments
Closed

Comments

@matthewbarr
Copy link

I just had to change a bunch of services from type: metric to non metric.

  1. If you just remove the line in the DSL specifying the type => metric, I'd expect the type: metric to go away in the config file. It doesn't.
  2. Are there any other types? Is there any reason that the doc in the module doesn't specify that the option is either undef or metric?
  3. In general, i'm surprised that the json files generated for checks and handlers aren't purged before updated...
@jlambert121
Copy link
Contributor

1 - This is an issue with puppet not having an undefined. The provider itself doesn't know the value is missing so it can't remove the key. If you know a way around this I'd love a fix - my hacking hasn't gotten any solutions other than blowing away each file for each run, which isn't really a good solution IMO.

2 - I'm not aware of any other types.

3 - Not sure I follow. If they were blown away and re-created each run we'd end up with each node always reporting changes wouldn't we? I think this goes back to 1, right?

@matthewbarr
Copy link
Author

  1. Yep. As much as it's nice to have the names of fields match up 1:1, since there's only one kind of type, and it's an optional field , it might be possible to switch it to be a Metric : boolean option, or just use a different value. Or, look for undef, and delete it from the file. I guess i'll have to go look at the internals :(
  2. Well, templates are created & compared. Not sure how the file is being delivered to the box, so I don't know. Internals of the module, again, for me :(

@jlambert121
Copy link
Contributor

@matthewbarr did you have any thoughts on this? From my understanding, puppet 4 is going to be required to do this correctly, which also means a decision at some point about how old of puppet version do we want to support?

@jamtur01
Copy link
Contributor

Closing until Puppet 4 is released. @matthewbarr feel free to weigh in if further thoughts.

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

No branches or pull requests

3 participants