-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Filebeat modules: first step of Go implementation
This rewrites the following parts of the prototype in Go: * Reading of the filesets * Evaluation of variables, including the builtin variables * Creation of the prospectors configurations and starting them * Overriding of the variables from the config file and from the command line * The -module and -M CLI flags * The ability to override variables from multiple filesets using wildcards, for example: `-M "nginx.*.var.paths=[/var/log/syslog*]"` At this point, the system tests are still using the filebeat.py wrapper, but only for loading the ingest node pipeline. The prospector configuration part and the overriding of settings is done by Filebeat itself. Part of #3159.
- Loading branch information
Tudor Golubenco
committed
Jan 16, 2017
1 parent
5af5f3e
commit ea58bdb
Showing
27 changed files
with
1,261 additions
and
169 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,6 +12,7 @@ | |
/beats.iml | ||
*.dev.yml | ||
*.generated.yml | ||
coverage.out | ||
|
||
# Editor swap files | ||
*.swp | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package fileset | ||
|
||
// ModuleConfig contains the configuration file options for a module | ||
type ModuleConfig struct { | ||
Module string `config:"module" validate:"required"` | ||
Enabled *bool `config:"enabled"` | ||
|
||
// Filesets is inlined by code, see mcfgFromConfig | ||
Filesets map[string]*FilesetConfig | ||
} | ||
|
||
// FilesetConfig contains the configuration file options for a fileset | ||
type FilesetConfig struct { | ||
Enabled *bool `config:"enabled"` | ||
Var map[string]interface{} `config:"var"` | ||
Prospector map[string]interface{} `config:"prospector"` | ||
} | ||
|
||
var defaultFilesetConfig = FilesetConfig{} |
Oops, something went wrong.