example42/puppet-splunk — pull request #8 by mklauber (2013-09-16 16:07:18+00:00)
Title: How do people feel about changing inputs and outputs into resources?

To whom it may concern,
I wanted to bring up a suggestion of how to manage inputs and outputs better. Within our company we want to monitor multiple applications, and have created classes for each application. As part of these classes we wanted to specify which log files splunk should watch. The issue I ran into is that you can only specify "monitor_path" in one place.

So my suggestion is to turn monitors and the various inputs into defined resources, and then let people define "splunk::monitor" with the class that includes the application. I've proof of concept'd a resource for "monitor" below, which you can declare in multiple locations and is concatenated into inputs.conf. Is this something you would like moving forward in or should I fork and publish my own module with this concept?

(Note: I'm not looking to merge at this time, it was just the simplest way to show the code comparison.)