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

(PIE-296) Use pe_ini_subsetting to automatically add report processor #51

Merged
merged 1 commit into from
Aug 12, 2020

Conversation

ekinanp
Copy link
Contributor

@ekinanp ekinanp commented Jul 14, 2020

This still works, and also fixes a (strange) bug where the 'store'
report processor was being included in the list of report processors
when used with a live PE environment.

Signed-off-by: Enis Inan enis.inan@puppet.com

@ekinanp ekinanp requested a review from a team as a code owner July 14, 2020 22:01
@puppet-community-rangefinder
Copy link

splunk_hec is a class

that may have no external impact to Forge modules.

This module is declared in 2 of 575 indexed public Puppetfiles.


These results were generated with Rangefinder, a tool that helps predict the downstream impact of breaking changes to elements used in Puppet modules. You can run this on the command line to get a full report.

Exact matches are those that we can positively identify via namespace and the declaring modules' metadata. Non-namespaced items, such as Puppet 3.x functions, will always be reported as near matches only.

}
# The subsetting resource automatically adds the 'splunk_hec' report
# processor to the reports setting if it hasn't yet been added there.
pe_ini_subsetting { 'enable splunk_hec':
Copy link
Contributor Author

@ekinanp ekinanp Jul 14, 2020

Choose a reason for hiding this comment

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

We should probably have an acceptance test for this to make sure it works in practice.

Copy link
Contributor

Choose a reason for hiding this comment

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

I was asked some of Principal Engineers to please not use the pe_init_settings module in modules published to the forge. They basically want that module as a private dependency for PE internal stuff only. That's one of the reasons why if you try to use this module against Pupperware, this resource will fail. It's not included in that image build because they are confident no one like us should be using it and have no intention of adding it into the container. I know we aren't using that container, but it's an indication of their attitude regarding this resource.

Copy link
Contributor Author

@ekinanp ekinanp Jul 14, 2020

Choose a reason for hiding this comment

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

@RandomNoun7 Yes, agreed. However, the module already used PE module resources (e.g. before this, it was pe_ini_setting). I left it as-is b/c I didn't want to risk breaking existing Splunk-hec users by introducing a sudden dependency to the inifile module.

We should definitely remove the PE-specific resources in the future though. Am also happy to do that now if we want to talk to Bryan about this (specifically whether the removal warrants a major release or if we can still do a minor one).

Copy link
Contributor

Choose a reason for hiding this comment

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

I forgot this was splunc_hec that was already using pe_init_setting. Yeah I can agree suddenly removing it in a change like this isn't necessary.

Copy link
Contributor

@gsparks gsparks Jul 14, 2020

Choose a reason for hiding this comment

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

@ekinanp working on adapting Bills acceptance framework to use a container published by splunk. Will look into adding acceptance tests once that's up and working, so don't worry about that for now. We'll definitely get acceptance tests up before releasing.

Copy link
Contributor

Choose a reason for hiding this comment

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

Kevin R. may be the best person to ask regarding the potential disruption by requiring the inifile module.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Cool, thanks both.

Copy link
Contributor

@gsparks gsparks left a comment

Choose a reason for hiding this comment

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

Let's merge this once rebased.

}
# The subsetting resource automatically adds the 'splunk_hec' report
# processor to the reports setting if it hasn't yet been added there.
pe_ini_subsetting { 'enable splunk_hec':
Copy link
Contributor

Choose a reason for hiding this comment

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

Kevin R. may be the best person to ask regarding the potential disruption by requiring the inifile module.

This still works, and also fixes a (strange) bug where the 'store'
report processor was being included in the list of report processors
when used with a live PE environment.

Signed-off-by: Enis Inan <enis.inan@puppet.com>
@ekinanp
Copy link
Contributor Author

ekinanp commented Aug 12, 2020

Rebased.

@gsparks
Copy link
Contributor

gsparks commented Aug 12, 2020

will merge once tests pass.

@gsparks gsparks merged commit 51f5c27 into puppetlabs:master Aug 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants